@wirecat/tg-cli 0.118.0 → 0.119.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/contracts/wirecat.json +7621 -0
- package/dist/bin/tg.js +2 -2
- package/dist/bot/transport.d.ts.map +1 -1
- package/dist/bot/transport.js +15 -8
- package/dist/bot/transport.js.map +1 -1
- package/dist/bundle/{adapter-4YNP6VCO.js → adapter-NEQQOANM.js} +47 -48
- package/dist/bundle/{all-profiles-MIQDYAGO.js → all-profiles-QFT46FTF.js} +10 -10
- package/dist/bundle/{anthropic-NTASPJYE.js → anthropic-UJ4RYCWU.js} +10 -8
- package/dist/bundle/{app-server-UJZBJ2SK.js → app-server-NE3EL5IK.js} +43 -43
- package/dist/bundle/{bot-api-JZAD4L3N.js → bot-api-D4H5SCP5.js} +49 -49
- package/dist/bundle/{bot-history-OUDHH3NU.js → bot-history-KF2PUMWA.js} +18 -18
- package/dist/bundle/{bun-EC4HDIRD.js → bun-F7MH5YKA.js} +2 -2
- package/dist/bundle/{bun-sqlite-A4HJR6KO.js → bun-sqlite-FYDJXUHF.js} +5 -5
- package/dist/bundle/{chunk-I4TI5HDJ.js → chunk-23JGV5FQ.js} +11 -11
- package/dist/bundle/{chunk-MBH7IKLT.js → chunk-2BAJ6ORN.js} +1 -1
- package/dist/bundle/{chunk-EPXVRJAX.js → chunk-3EQ7USKJ.js} +2 -2
- package/dist/bundle/{chunk-MZNOASAW.js → chunk-3K65KTXD.js} +16 -3
- package/dist/bundle/{chunk-EQJ6NLF5.js → chunk-4AACB23H.js} +13 -13
- package/dist/bundle/{chunk-NUCDEOFC.js → chunk-5EHJWIW4.js} +2 -2
- package/dist/bundle/{chunk-VW6BF6M7.js → chunk-5FEEFXJA.js} +1 -1
- package/dist/bundle/{chunk-6RI4TEIC.js → chunk-65BWMPCI.js} +2 -2
- package/dist/bundle/{chunk-PB252TT3.js → chunk-6ERQJRL2.js} +2 -2
- package/dist/bundle/{chunk-G3RT2EQI.js → chunk-6K5R3YPN.js} +2 -2
- package/dist/bundle/{chunk-OTQDJUES.js → chunk-6OE5I3PR.js} +6 -6
- package/dist/bundle/{chunk-FHMK6OK4.js → chunk-72QLHHSO.js} +93 -29
- package/dist/bundle/{chunk-YEOSV6JC.js → chunk-7C6POLLO.js} +1 -1
- package/dist/bundle/{chunk-JPVFYMSQ.js → chunk-7VUNJDYU.js} +4 -4
- package/dist/bundle/{chunk-57LKX6N2.js → chunk-BXIPT2BO.js} +1 -1
- package/dist/bundle/{chunk-NKFTZVQU.js → chunk-CIDFV3IT.js} +1 -1
- package/dist/bundle/{chunk-4BV4UMBB.js → chunk-CX2WCEQU.js} +264 -195
- package/dist/bundle/{chunk-H6S3C3MH.js → chunk-D4Y2KL5V.js} +4 -4
- package/dist/bundle/{chunk-YPRUWRKE.js → chunk-D6YTBJY6.js} +1 -1
- package/dist/bundle/{chunk-PW3HFIJA.js → chunk-DQELQ7BL.js} +365 -192
- package/dist/bundle/{chunk-5IIU7X4S.js → chunk-F223KYWG.js} +1 -1
- package/dist/bundle/{chunk-TMTEWOQS.js → chunk-FJKP6MMP.js} +5 -3
- package/dist/bundle/{chunk-NMT2VGEI.js → chunk-FQ3C6DFV.js} +3 -3
- package/dist/bundle/{chunk-6ZMTEUVU.js → chunk-FQZSS3AB.js} +6 -6
- package/dist/bundle/{chunk-CEY43D3A.js → chunk-FRW3CWC7.js} +29 -29
- package/dist/bundle/{chunk-65XV5PPI.js → chunk-G3MQOH6Z.js} +3 -3
- package/dist/bundle/{chunk-6AXUEJGL.js → chunk-HGMMRT4G.js} +2 -2
- package/dist/bundle/{chunk-GLRRCKP6.js → chunk-HPQQ76WF.js} +23 -5
- package/dist/bundle/{chunk-RG2E7ZQZ.js → chunk-HV5YYAJX.js} +50 -15
- package/dist/bundle/{chunk-3MQOLYAN.js → chunk-IAGX5VFL.js} +4 -4
- package/dist/bundle/{chunk-BNEP5EOV.js → chunk-JKKEMVW3.js} +4 -4
- package/dist/bundle/{chunk-P3ASN72F.js → chunk-KBHK5UGL.js} +1 -1
- package/dist/bundle/{chunk-EPCFXKTX.js → chunk-KC4MQRAB.js} +34 -8
- package/dist/bundle/{chunk-GXCJ47SJ.js → chunk-L33G5ARH.js} +2664 -670
- package/dist/bundle/{chunk-PO74BDER.js → chunk-MDLSI3EN.js} +23 -23
- package/dist/bundle/chunk-NDSRND3E.js +138 -0
- package/dist/bundle/{chunk-2KQHUBTV.js → chunk-OG2CG2GS.js} +12 -12
- package/dist/bundle/{chunk-JZETEZHC.js → chunk-QD27C3BG.js} +7 -7
- package/dist/bundle/{chunk-QOGYHU3Q.js → chunk-QG5U6HCI.js} +61 -21
- package/dist/bundle/{chunk-GI4MTNA2.js → chunk-QQ3QZFFD.js} +8 -8
- package/dist/bundle/{chunk-76EKXFX2.js → chunk-QTFXYR5W.js} +24 -2
- package/dist/bundle/{chunk-ZXXTJF4Z.js → chunk-RGU2G3KL.js} +4 -4
- package/dist/bundle/{chunk-JWPSVS6C.js → chunk-ROOUBFUW.js} +2304 -1442
- package/dist/bundle/{chunk-5QYU7B27.js → chunk-RUNFFBJU.js} +656 -461
- package/dist/bundle/{chunk-DKFC5ZZ3.js → chunk-S3HAFJVC.js} +4 -4
- package/dist/bundle/{chunk-BXTDAGM4.js → chunk-SMHLQEE2.js} +2 -2
- package/dist/bundle/{chunk-JWIUK3SK.js → chunk-TEZKCH5B.js} +2 -2
- package/dist/bundle/{chunk-HJNRIK5X.js → chunk-TKHEVAEG.js} +9 -8
- package/dist/bundle/{chunk-JLJKGKU2.js → chunk-TT4CIXVH.js} +6 -6
- package/dist/bundle/{chunk-ZMUC3UQO.js → chunk-UBCLVM7C.js} +3 -3
- package/dist/bundle/{chunk-YHZFGUAP.js → chunk-V5Z2JO6X.js} +19 -19
- package/dist/bundle/{chunk-2NA5KVP6.js → chunk-W2BIBPRU.js} +234 -38
- package/dist/bundle/{chunk-PWCQC56A.js → chunk-X5PDWCG7.js} +1 -1
- package/dist/bundle/{chunk-GIM37COQ.js → chunk-XDMJVWWR.js} +3 -3
- package/dist/bundle/{chunk-KEDHX6XG.js → chunk-XM3P7LLT.js} +2 -2
- package/dist/bundle/{chunk-DSZJREEO.js → chunk-YMWPRHXG.js} +1285 -750
- package/dist/bundle/{chunk-5LDWBEWU.js → chunk-Z4CGZAFQ.js} +45 -27
- package/dist/bundle/{chunk-Y64SI2RO.js → chunk-ZEQ7ONPZ.js} +3 -3
- package/dist/bundle/command-contract-7TGMZRBE.js +33 -0
- package/dist/bundle/{decode-NMNPLKNR.js → decode-5N4ERCHC.js} +5 -5
- package/dist/bundle/{dispatch-OP27MWX5.js → dispatch-TBGXBDHE.js} +10 -10
- package/dist/bundle/{echarts-S46LEIPS.js → echarts-YDEBAMXT.js} +2 -2
- package/dist/bundle/{embed-I5ZYHGYC.js → embed-T7H62XFR.js} +6 -6
- package/dist/bundle/{embedder-LTJI67N2.js → embedder-AW3O2TR3.js} +9 -9
- package/dist/bundle/{entry-O6BUPXF7.js → entry-L2LJ2VPY.js} +7 -7
- package/dist/bundle/{failure-4JUQFXJT.js → failure-AWHPW2HE.js} +2 -2
- package/dist/bundle/{first-run-PMZNCDGD.js → first-run-6PBZSRZU.js} +11 -11
- package/dist/bundle/first-screen-UKCD7D2R.js +31 -0
- package/dist/bundle/{instructions-AUEGY3VO.js → instructions-C3NJERO7.js} +1 -1
- package/dist/bundle/{mcp-M4QN2E7R.js → mcp-CWLASTLV.js} +2 -2
- package/dist/bundle/{node-XRA7RBCQ.js → node-P3CIIYWU.js} +2 -2
- package/dist/bundle/{node-sqlite-DEZO6LRS.js → node-sqlite-YVHMNRVA.js} +6 -6
- package/dist/bundle/{oauth-DAVC7WCD.js → oauth-5OQYA2SV.js} +7 -7
- package/dist/bundle/{open-DE2YO4T7.js → open-YGWUVSU7.js} +5 -5
- package/dist/bundle/{openai-5BKGAULH.js → openai-U45JBQ6F.js} +16 -37
- package/dist/bundle/{process-4ZHPNUIQ.js → process-DCYX5EDG.js} +1 -1
- package/dist/bundle/{program-EGTKSNB4.js → program-UZBFH2EZ.js} +55 -52
- package/dist/bundle/{prompt-HWCWHHPE.js → prompt-HPVTPTFI.js} +7 -5
- package/dist/bundle/{proxy-transport-4DPZB2W2.js → proxy-transport-D7MCHGSV.js} +5 -5
- package/dist/bundle/{recognize-NG6RXNGF.js → recognize-IJCPFJ76.js} +4 -4
- package/dist/bundle/{remote-ZKXIIGYH.js → remote-MWDYQWFW.js} +7 -7
- package/dist/bundle/{rerank-TX5QFURV.js → rerank-SXG64475.js} +7 -7
- package/dist/bundle/{serve-XAS6DECW.js → serve-KJQENHEH.js} +9 -9
- package/dist/bundle/{server-CNPIWBYU.js → server-MXVXZWN6.js} +35 -35
- package/dist/bundle/server-RTMCRKQF.js +60 -0
- package/dist/bundle/{state-3HTUETTS.js → state-CKKJWH27.js} +6 -6
- package/dist/bundle/{store-B5VZWJHN.js → store-R3BE4V56.js} +36 -13
- package/dist/bundle/store-maintenance-command-KDGBSBNU.js +49 -0
- package/dist/bundle/tg.js +38 -14
- package/dist/commands/account-removal.d.ts +3 -0
- package/dist/commands/account-removal.d.ts.map +1 -0
- package/dist/commands/account-removal.js +57 -0
- package/dist/commands/account-removal.js.map +1 -0
- package/dist/commands/context.d.ts.map +1 -1
- package/dist/commands/context.js +2 -0
- package/dist/commands/context.js.map +1 -1
- package/dist/http.d.ts +6 -0
- package/dist/http.d.ts.map +1 -0
- package/dist/http.js +8 -0
- package/dist/http.js.map +1 -0
- package/dist/identity.d.ts +4 -0
- package/dist/identity.d.ts.map +1 -1
- package/dist/identity.js +14 -0
- package/dist/identity.js.map +1 -1
- package/dist/telegram/map.d.ts.map +1 -1
- package/dist/telegram/map.js +3 -0
- package/dist/telegram/map.js.map +1 -1
- package/dist/telegram/registration.d.ts +1 -1
- package/dist/telegram/registration.d.ts.map +1 -1
- package/dist/telegram/registration.js +4 -1
- package/dist/telegram/registration.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/wcat.d.ts +3 -0
- package/dist/wcat.d.ts.map +1 -0
- package/dist/wcat.js +4 -0
- package/dist/wcat.js.map +1 -0
- package/package.json +7 -6
- package/dist/bundle/chunk-TSTEZNSX.js +0 -33
- package/dist/bundle/command-contract-7GZ6HAA6.js +0 -33
- package/dist/bundle/first-screen-BGML5DSO.js +0 -31
- package/dist/bundle/server-FRTKLHZF.js +0 -60
- package/dist/bundle/store-maintenance-command-VG3CLELA.js +0 -50
- /package/dist/bundle/{chunk-VOXIGICJ.js → chunk-DWX4DE2I.js} +0 -0
|
@@ -3,10 +3,10 @@ const require = __bundleRequire(import.meta.url);
|
|
|
3
3
|
import {
|
|
4
4
|
isCliFailure,
|
|
5
5
|
isStoreDamage
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-ZEQ7ONPZ.js";
|
|
7
7
|
import {
|
|
8
8
|
refuseOwnerStoreInTests
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-6K5R3YPN.js";
|
|
10
10
|
import {
|
|
11
11
|
RegistryError,
|
|
12
12
|
SNAKE_CASE,
|
|
@@ -40,18 +40,169 @@ import {
|
|
|
40
40
|
union,
|
|
41
41
|
unknown,
|
|
42
42
|
variant
|
|
43
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-KC4MQRAB.js";
|
|
44
44
|
import {
|
|
45
45
|
CliError,
|
|
46
46
|
isCliError,
|
|
47
47
|
singleLine,
|
|
48
48
|
visibleControls
|
|
49
|
-
} from "./chunk-
|
|
49
|
+
} from "./chunk-SMHLQEE2.js";
|
|
50
50
|
import {
|
|
51
51
|
__name
|
|
52
52
|
} from "./chunk-ZVVMGPBJ.js";
|
|
53
53
|
|
|
54
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
54
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/money.js
|
|
55
|
+
var CURRENCY_SCALES = {
|
|
56
|
+
AED: 2,
|
|
57
|
+
AMD: 2,
|
|
58
|
+
AUD: 2,
|
|
59
|
+
BHD: 3,
|
|
60
|
+
BYN: 2,
|
|
61
|
+
CAD: 2,
|
|
62
|
+
CHF: 2,
|
|
63
|
+
CLP: 0,
|
|
64
|
+
CNY: 2,
|
|
65
|
+
CZK: 2,
|
|
66
|
+
DKK: 2,
|
|
67
|
+
EUR: 2,
|
|
68
|
+
GBP: 2,
|
|
69
|
+
GEL: 2,
|
|
70
|
+
HUF: 2,
|
|
71
|
+
ILS: 2,
|
|
72
|
+
INR: 2,
|
|
73
|
+
ISK: 0,
|
|
74
|
+
JPY: 0,
|
|
75
|
+
KGS: 2,
|
|
76
|
+
KRW: 0,
|
|
77
|
+
KWD: 3,
|
|
78
|
+
KZT: 2,
|
|
79
|
+
NOK: 2,
|
|
80
|
+
PLN: 2,
|
|
81
|
+
RSD: 2,
|
|
82
|
+
RUB: 2,
|
|
83
|
+
SEK: 2,
|
|
84
|
+
THB: 2,
|
|
85
|
+
TRY: 2,
|
|
86
|
+
UAH: 2,
|
|
87
|
+
USD: 2,
|
|
88
|
+
UZS: 2,
|
|
89
|
+
VND: 0
|
|
90
|
+
};
|
|
91
|
+
var refuse = /* @__PURE__ */ __name((message, reason) => {
|
|
92
|
+
throw new CliError("validation_error", message, { reason });
|
|
93
|
+
}, "refuse");
|
|
94
|
+
var DECIMAL = /^(\d{1,15})(?:\.(\d+))?$/;
|
|
95
|
+
var parseDecimal = /* @__PURE__ */ __name((text6, scale) => {
|
|
96
|
+
const match = DECIMAL.exec(text6.trim());
|
|
97
|
+
if (!match || (match[2] ?? "").length > scale)
|
|
98
|
+
return void 0;
|
|
99
|
+
return BigInt(`${match[1]}${(match[2] ?? "").padEnd(scale, "0")}`);
|
|
100
|
+
}, "parseDecimal");
|
|
101
|
+
var formatDecimal = /* @__PURE__ */ __name((units, scale) => {
|
|
102
|
+
const value = BigInt(units);
|
|
103
|
+
if (value < 0n)
|
|
104
|
+
return `-${formatDecimal(-value, scale)}`;
|
|
105
|
+
const digits = value.toString().padStart(scale + 1, "0");
|
|
106
|
+
return scale === 0 ? digits : `${digits.slice(0, -scale)}.${digits.slice(-scale)}`;
|
|
107
|
+
}, "formatDecimal");
|
|
108
|
+
var groupDigits = /* @__PURE__ */ __name((decimal) => {
|
|
109
|
+
const [whole = "0", fraction] = decimal.split(".");
|
|
110
|
+
const grouped2 = whole.replace(/\B(?=(\d{3})+(?!\d))/g, " ");
|
|
111
|
+
return fraction === void 0 ? grouped2 : `${grouped2}.${fraction}`;
|
|
112
|
+
}, "groupDigits");
|
|
113
|
+
var currencyOf = /* @__PURE__ */ __name((text6) => {
|
|
114
|
+
const code = typeof text6 === "string" ? text6.trim().toUpperCase() : "";
|
|
115
|
+
if (CURRENCY_SCALES[code] === void 0)
|
|
116
|
+
return refuse(`${typeof text6 === "string" && text6.trim() ? text6.trim() : "an empty currency"} is not a currency the store keeps; use one of ${Object.keys(CURRENCY_SCALES).join(", ")}`, "money.currency");
|
|
117
|
+
return code;
|
|
118
|
+
}, "currencyOf");
|
|
119
|
+
var scaleOf = /* @__PURE__ */ __name((currency) => CURRENCY_SCALES[currencyOf(currency)], "scaleOf");
|
|
120
|
+
var minorUnits = /* @__PURE__ */ __name((amount, currency, what = "an amount") => {
|
|
121
|
+
const scale = scaleOf(currency);
|
|
122
|
+
const units = typeof amount === "string" ? parseDecimal(amount, scale) : void 0;
|
|
123
|
+
if (units === void 0 || units > BigInt(Number.MAX_SAFE_INTEGER))
|
|
124
|
+
return refuse(`${what} is a decimal string with at most ${scale} decimal${scale === 1 ? "" : "s"} for ${currency}, such as "${formatDecimal(5e3 * 10 ** scale, scale)}"`, "money.amount");
|
|
125
|
+
return Number(units);
|
|
126
|
+
}, "minorUnits");
|
|
127
|
+
var signedMinorUnits = /* @__PURE__ */ __name((amount, currency, what = "an amount") => {
|
|
128
|
+
if (typeof amount !== "string" || !amount.trim().startsWith("-"))
|
|
129
|
+
return minorUnits(amount, currency, what);
|
|
130
|
+
const units = minorUnits(amount.trim().slice(1), currency, what);
|
|
131
|
+
return units === 0 ? 0 : -units;
|
|
132
|
+
}, "signedMinorUnits");
|
|
133
|
+
var moneyOf = /* @__PURE__ */ __name((units, currency) => ({
|
|
134
|
+
amount: formatDecimal(units, scaleOf(currency)),
|
|
135
|
+
currency
|
|
136
|
+
}), "moneyOf");
|
|
137
|
+
var moneyLabel = /* @__PURE__ */ __name((units, currency) => `${groupDigits(formatDecimal(units, scaleOf(currency)))} ${currency}`, "moneyLabel");
|
|
138
|
+
var QUANTITY_SCALE = 3;
|
|
139
|
+
var quantityOf = /* @__PURE__ */ __name((text6) => {
|
|
140
|
+
const thousandths = typeof text6 === "string" ? parseDecimal(text6, QUANTITY_SCALE) : void 0;
|
|
141
|
+
if (thousandths === void 0 || thousandths === 0n)
|
|
142
|
+
return refuse('a quantity is a decimal string above 0 with at most 3 decimals, such as "1.5"', "money.quantity");
|
|
143
|
+
const plain = formatDecimal(thousandths, QUANTITY_SCALE).replace(/\.?0+$/, "");
|
|
144
|
+
return { text: plain, thousandths };
|
|
145
|
+
}, "quantityOf");
|
|
146
|
+
var lineUnits = /* @__PURE__ */ __name((thousandths, unitPrice) => Number((thousandths * BigInt(unitPrice) + 500n) / 1000n), "lineUnits");
|
|
147
|
+
|
|
148
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/finance.js
|
|
149
|
+
var INVOICE_DIRECTIONS = ["receivable", "payable"];
|
|
150
|
+
var INVOICE_STATUSES = ["draft", "issued", "partly_paid", "paid", "void"];
|
|
151
|
+
var MONEY_DIRECTIONS = ["in", "out"];
|
|
152
|
+
var FINANCE_REVIEWS = ["proposed", "confirmed", "rejected"];
|
|
153
|
+
var settledStatus = /* @__PURE__ */ __name((current, total, paid) => {
|
|
154
|
+
if (current === "draft" || current === "void")
|
|
155
|
+
return current;
|
|
156
|
+
if (paid <= 0)
|
|
157
|
+
return "issued";
|
|
158
|
+
return paid < total ? "partly_paid" : "paid";
|
|
159
|
+
}, "settledStatus");
|
|
160
|
+
var dayMonth = /* @__PURE__ */ __name((date) => date === null ? null : `${date.slice(8, 10)}.${date.slice(5, 7)}`, "dayMonth");
|
|
161
|
+
var notes = /* @__PURE__ */ __name((...words2) => {
|
|
162
|
+
const kept = words2.filter((word) => word !== null);
|
|
163
|
+
return kept.length === 0 ? "" : ` (${kept.join(", ")})`;
|
|
164
|
+
}, "notes");
|
|
165
|
+
var invoiceLine = /* @__PURE__ */ __name((invoice) => {
|
|
166
|
+
const party = invoice.counterpartyName === null ? "" : `${invoice.direction === "receivable" ? " to" : " from"} ${invoice.counterpartyName}`;
|
|
167
|
+
const due = invoice.dueDate === null ? "" : `, due ${dayMonth(invoice.dueDate)}`;
|
|
168
|
+
return `${invoice.number ?? `#${invoice.id}`} \xB7 ${moneyLabel(invoice.total, invoice.currency)}${party}${due}` + notes(invoice.status.replace("_", " "), invoice.review === "confirmed" ? null : invoice.review);
|
|
169
|
+
}, "invoiceLine");
|
|
170
|
+
var paymentLine = /* @__PURE__ */ __name((payment) => {
|
|
171
|
+
const party = payment.partyName === null ? "" : `${payment.direction === "in" ? " from" : " to"} ${payment.partyName}`;
|
|
172
|
+
return `${moneyLabel(payment.amount, payment.currency)}${party}, ${dayMonth(payment.date)}` + notes(payment.review === "confirmed" ? null : payment.review);
|
|
173
|
+
}, "paymentLine");
|
|
174
|
+
var invoiceTitle = /* @__PURE__ */ __name((invoice) => `Invoice ${invoiceLine(invoice)}`, "invoiceTitle");
|
|
175
|
+
var paymentEntryTitle = /* @__PURE__ */ __name((payment) => `Payment \xB7 ${paymentLine(payment)}`, "paymentEntryTitle");
|
|
176
|
+
|
|
177
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/business.js
|
|
178
|
+
var CATALOG_KINDS = ["product", "service"];
|
|
179
|
+
var BUSINESS_KINDS = ["invoice", "payment", "order", "contract", "subscription", "product", "wallet"];
|
|
180
|
+
var CONTRACT_KINDS = ["sale", "purchase", "service", "lease", "employment", "nda", "license", "other"];
|
|
181
|
+
var CONTRACT_STATUSES = ["draft", "active", "ended", "terminated"];
|
|
182
|
+
var SUBSCRIPTION_STATUSES = ["trial", "active", "paused", "cancelled", "ended"];
|
|
183
|
+
var WALLET_KINDS = ["bank", "card", "cash", "wallet", "other"];
|
|
184
|
+
var TRANSACTION_STATUSES = ["pending", "booked"];
|
|
185
|
+
var ORDER_DIRECTIONS = ["purchase", "sale"];
|
|
186
|
+
var intervalOf = /* @__PURE__ */ __name((text6, reason = "subscription.interval") => {
|
|
187
|
+
const match = typeof text6 === "string" ? /^(?:([1-9]\d{0,2})-)?(day|week|month|year)$/.exec(text6.trim()) : null;
|
|
188
|
+
if (!match)
|
|
189
|
+
throw new CliError("validation_error", "an interval is a count and a unit, such as 1-month or 2-week", { reason });
|
|
190
|
+
return { count: match[1] === void 0 ? 1 : Number(match[1]), unit: match[2] };
|
|
191
|
+
}, "intervalOf");
|
|
192
|
+
var intervalText = /* @__PURE__ */ __name(({ count: count7, unit }) => `${count7}-${unit}`, "intervalText");
|
|
193
|
+
var priced = /* @__PURE__ */ __name((units, currency) => units === null || currency === null ? "" : `, ${moneyLabel(units, currency)}`, "priced");
|
|
194
|
+
var pending = /* @__PURE__ */ __name((review) => review === "confirmed" ? null : review, "pending");
|
|
195
|
+
var productLine = /* @__PURE__ */ __name((product) => {
|
|
196
|
+
const price = product.unitPrice === null || product.currency === null ? "" : moneyLabel(product.unitPrice, product.currency);
|
|
197
|
+
const per = price && product.unit !== null ? ` per ${product.unit}` : "";
|
|
198
|
+
return `${product.name}${price ? ` \xB7 ${price}${per}` : ""}${notes(product.kind, product.archived ? "archived" : null)}`;
|
|
199
|
+
}, "productLine");
|
|
200
|
+
var contractLine = /* @__PURE__ */ __name((contract) => `${contract.number ?? `#${contract.id}`} \xB7 ${contract.name}${priced(contract.value, contract.currency)}` + notes(contract.status, pending(contract.review)), "contractLine");
|
|
201
|
+
var subscriptionLine = /* @__PURE__ */ __name((subscription) => `${subscription.name}${priced(subscription.price, subscription.currency)} every ${intervalText(subscription.interval)}` + notes(subscription.status, pending(subscription.review)), "subscriptionLine");
|
|
202
|
+
var walletLine = /* @__PURE__ */ __name((wallet) => `${wallet.name} \xB7 ${wallet.kind}, ${wallet.currency}${wallet.numberHint === null ? "" : `, \u2026${wallet.numberHint}`}` + notes(wallet.closed ? "closed" : null), "walletLine");
|
|
203
|
+
var transactionLine = /* @__PURE__ */ __name((transaction) => `${moneyLabel(transaction.amount, transaction.currency)} ${transaction.direction}${transaction.label === null ? "" : ` \xB7 ${transaction.label}`}, ${dayMonth(transaction.date)}` + notes(transaction.status === "pending" ? "pending" : null, pending(transaction.review)), "transactionLine");
|
|
204
|
+
|
|
205
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/store/marks.js
|
|
55
206
|
import { readFileSync, rmSync, statSync, writeFileSync } from "node:fs";
|
|
56
207
|
var damageMarkPath = /* @__PURE__ */ __name((store) => `${store}.damaged.json`, "damageMarkPath");
|
|
57
208
|
var healthMarkPath = /* @__PURE__ */ __name((store) => `${store}.health.json`, "healthMarkPath");
|
|
@@ -152,7 +303,7 @@ var recordDeepCheck = /* @__PURE__ */ __name((store, health, { cli, version, sch
|
|
|
152
303
|
return { previous, cleared };
|
|
153
304
|
}, "recordDeepCheck");
|
|
154
305
|
|
|
155
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
306
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/types.js
|
|
156
307
|
var QUERY_LIMITS = {
|
|
157
308
|
bytes: 8192,
|
|
158
309
|
depth: 32,
|
|
@@ -196,7 +347,7 @@ function queryError(reason, span, alternative, context3 = {}, details = {}) {
|
|
|
196
347
|
__name(queryError, "queryError");
|
|
197
348
|
var walkQuery = /* @__PURE__ */ __name((node) => node.kind === "predicate" ? [node] : node.clauses.flatMap(({ node: node2 }) => walkQuery(node2)), "walkQuery");
|
|
198
349
|
|
|
199
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
350
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/dates.js
|
|
200
351
|
var timezoneOf = /* @__PURE__ */ __name((given) => {
|
|
201
352
|
const zone = given ?? Intl.DateTimeFormat().resolvedOptions().timeZone ?? "UTC";
|
|
202
353
|
try {
|
|
@@ -341,7 +492,7 @@ var dateRange = /* @__PURE__ */ __name((lower, upper, lowerInclusive, upperInclu
|
|
|
341
492
|
};
|
|
342
493
|
}, "dateRange");
|
|
343
494
|
|
|
344
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
495
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/fields.js
|
|
345
496
|
var FIELD_TYPES = ["kw", "txt", "enum", "num", "time", "bool", "ref"];
|
|
346
497
|
var OPERATORS_BY_TYPE = {
|
|
347
498
|
kw: ["term", "phrase", "wildcard"],
|
|
@@ -420,7 +571,7 @@ var queryFieldsOf = /* @__PURE__ */ __name((schema, annotations = {}) => {
|
|
|
420
571
|
return [...own, ...relations, ...states];
|
|
421
572
|
}, "queryFieldsOf");
|
|
422
573
|
|
|
423
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
574
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/help.js
|
|
424
575
|
var shownOf = /* @__PURE__ */ __name((registry) => registry.backend === "native" ? registry.fields.filter((field) => field.native) : registry.fields, "shownOf");
|
|
425
576
|
var leftOut = /* @__PURE__ */ __name((fields) => fields.filter((field) => field.negatable).map((field) => field.name), "leftOut");
|
|
426
577
|
var has = /* @__PURE__ */ __name((fields, operator) => fields.some((field) => field.operators.includes(operator)), "has");
|
|
@@ -457,7 +608,7 @@ var queryDescription = /* @__PURE__ */ __name((registry) => {
|
|
|
457
608
|
return `${terms}; fields: ${fields.join(", ")}; e.g. ${shown[0]?.example ?? ""}${defaults}`;
|
|
458
609
|
}, "queryDescription");
|
|
459
610
|
|
|
460
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
611
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/validate.js
|
|
461
612
|
var inContext = /* @__PURE__ */ __name((context3, run2) => {
|
|
462
613
|
try {
|
|
463
614
|
run2();
|
|
@@ -532,7 +683,7 @@ var validateQuery = /* @__PURE__ */ __name((ast, registry, options = {}) => {
|
|
|
532
683
|
}, "validateQuery");
|
|
533
684
|
var fieldsNamed = /* @__PURE__ */ __name((ast) => new Set(walkQuery(ast.root).map((node) => node.field)), "fieldsNamed");
|
|
534
685
|
|
|
535
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
686
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/parser.js
|
|
536
687
|
var whitespace = /* @__PURE__ */ __name((c) => /[ \t\n\r\u3000]/u.test(c), "whitespace");
|
|
537
688
|
var reserved = /* @__PURE__ */ new Set([
|
|
538
689
|
"+",
|
|
@@ -841,7 +992,7 @@ var implicitTextTerms = /* @__PURE__ */ __name((text6) => {
|
|
|
841
992
|
return new Set(tokens.flatMap((token, index) => (token.kind === "term" || token.kind === "number") && ![":", "=", "<", ">", "<=", ">="].includes(tokens[index - 1]?.kind ?? "") && ![":", "=", "<", ">", "<=", ">="].includes(tokens[index + 1]?.kind ?? "") ? [token.span.start] : []));
|
|
842
993
|
}, "implicitTextTerms");
|
|
843
994
|
|
|
844
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
995
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/registry.js
|
|
845
996
|
var describeQuery = /* @__PURE__ */ __name((registry) => ({
|
|
846
997
|
entity: registry.entity,
|
|
847
998
|
backend: registry.backend,
|
|
@@ -912,7 +1063,7 @@ var QUERY_REASONS = defineReasons([
|
|
|
912
1063
|
details: [...SPAN, ...details]
|
|
913
1064
|
})));
|
|
914
1065
|
|
|
915
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1066
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.87.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/query/evaluate.js
|
|
916
1067
|
var wordsOf = /* @__PURE__ */ __name((text6) => text6.toLowerCase().match(/[\p{L}\p{N}]+/gu) ?? [], "wordsOf");
|
|
917
1068
|
var pattern = /* @__PURE__ */ __name((value) => new RegExp(`^${[...value].map((char) => char === "*" ? ".*" : char === "?" ? "." : char.replace(/[.+^${}()|[\]\\]/, "\\$&")).join("")}$`, "iu"), "pattern");
|
|
918
1069
|
var present = /* @__PURE__ */ __name((value) => value !== void 0 && value !== null && value !== "", "present");
|
|
@@ -967,7 +1118,7 @@ var matches = /* @__PURE__ */ __name((node, item, byName, options) => {
|
|
|
967
1118
|
}, "matches");
|
|
968
1119
|
var evaluate = /* @__PURE__ */ __name((ast, fields, item, options = {}) => matches(ast.root, item, new Map(fields.map((field) => [field.name, field])), options), "evaluate");
|
|
969
1120
|
|
|
970
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1121
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/reference.js
|
|
971
1122
|
var invalid = /* @__PURE__ */ __name(() => new CliError("validation_error", "expected meeting:<accountId>/<meetingId>[/<transcriptId>[/<cuePosition>]] with safe integer IDs"), "invalid");
|
|
972
1123
|
var integer2 = /* @__PURE__ */ __name((value, minimum = 1) => {
|
|
973
1124
|
if (!Number.isSafeInteger(value) || value < minimum)
|
|
@@ -1004,7 +1155,7 @@ var parseMeetingReference = /* @__PURE__ */ __name((text6) => {
|
|
|
1004
1155
|
}, "parseMeetingReference");
|
|
1005
1156
|
var canonicalMeetingReference = /* @__PURE__ */ __name((text6) => formatMeetingReference(parseMeetingReference(text6)), "canonicalMeetingReference");
|
|
1006
1157
|
|
|
1007
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1158
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/item.js
|
|
1008
1159
|
var text = string();
|
|
1009
1160
|
var count = pipe(number(), integer(), minValue(0));
|
|
1010
1161
|
var MEETING_ISSUES = ["time_without_zone"];
|
|
@@ -1069,7 +1220,7 @@ var MEETING_QUERY = {
|
|
|
1069
1220
|
})
|
|
1070
1221
|
};
|
|
1071
1222
|
|
|
1072
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1223
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/join-key.js
|
|
1073
1224
|
var joinKeyOf = /* @__PURE__ */ __name((url) => {
|
|
1074
1225
|
const parsed = urlOf(url);
|
|
1075
1226
|
if (!parsed)
|
|
@@ -1103,7 +1254,7 @@ var urlOf = /* @__PURE__ */ __name((url) => {
|
|
|
1103
1254
|
}
|
|
1104
1255
|
}, "urlOf");
|
|
1105
1256
|
|
|
1106
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1257
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/calendar-text.js
|
|
1107
1258
|
var ENTITIES = { amp: "&", lt: "<", gt: ">", quot: '"', "#39": "'", apos: "'", nbsp: " " };
|
|
1108
1259
|
var SECRET_LINE = /(?<![\p{L}\p{N}])(pass ?codes?|passwords?|pwd|pins?|access ?codes?|meeting ?codes?|kennwort|пароль|пин-?код|код доступа)(?![\p{L}\p{N}])|pwd=/iu;
|
|
1109
1260
|
var htmlToText = /* @__PURE__ */ __name((html) => html.replace(/<\s*br\s*\/?>/giu, "\n").replace(/<\/\s*(p|div|li|tr|h[1-6])\s*>/giu, "\n").replace(/<a\s[^>]*href\s*=\s*"([^"]*)"[^>]*>/giu, " $1 ").replace(/<[^>]+>/gu, "").replace(/&(amp|lt|gt|quot|#39|apos|nbsp);/gu, (_, name) => ENTITIES[name] ?? ""), "htmlToText");
|
|
@@ -1140,7 +1291,7 @@ var entryMetadata = /* @__PURE__ */ __name((metadata) => {
|
|
|
1140
1291
|
return kept;
|
|
1141
1292
|
}, "entryMetadata");
|
|
1142
1293
|
|
|
1143
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1294
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/cue-fingerprint.js
|
|
1144
1295
|
import { createHash } from "node:crypto";
|
|
1145
1296
|
var meetingCueFingerprint = /* @__PURE__ */ __name((cue2) => createHash("sha256").update(JSON.stringify({
|
|
1146
1297
|
reference: cue2.reference,
|
|
@@ -1154,7 +1305,7 @@ var meetingCueFingerprint = /* @__PURE__ */ __name((cue2) => createHash("sha256"
|
|
|
1154
1305
|
text: cue2.text
|
|
1155
1306
|
})).digest("hex"), "meetingCueFingerprint");
|
|
1156
1307
|
|
|
1157
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1308
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/event-store.js
|
|
1158
1309
|
var UNTIL = /(?:^|;)UNTIL=(\d{4})(\d{2})(\d{2})(?:T(\d{2})(\d{2})(\d{2})Z?)?(?:;|$)/iu;
|
|
1159
1310
|
var seriesEnd = /* @__PURE__ */ __name((entry) => {
|
|
1160
1311
|
if (entry.recurrenceEndsAt !== null)
|
|
@@ -1177,7 +1328,7 @@ var entryInWindow = /* @__PURE__ */ __name((entry, window) => {
|
|
|
1177
1328
|
return Math.max(entry.endsAt ?? start, start + 1) > window.from;
|
|
1178
1329
|
}, "entryInWindow");
|
|
1179
1330
|
|
|
1180
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1331
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/answers.js
|
|
1181
1332
|
var text2 = string();
|
|
1182
1333
|
var count2 = pipe(number(), integer(), minValue(0));
|
|
1183
1334
|
var iso2 = /* @__PURE__ */ __name((ms) => ms === null ? null : new Date(ms).toISOString(), "iso");
|
|
@@ -1380,10 +1531,10 @@ var meetingHitItem = /* @__PURE__ */ __name((hit) => ({
|
|
|
1380
1531
|
var meetingHitsList = /* @__PURE__ */ __name((found, limit, command = "search meetings", args = {}, meta = {}) => {
|
|
1381
1532
|
const items = found.items.map(meetingHitItem);
|
|
1382
1533
|
const cursor = found.hasMore && found.nextCursor !== null ? found.nextCursor : void 0;
|
|
1383
|
-
const
|
|
1534
|
+
const pending2 = found.coverage.indexing === "pending";
|
|
1384
1535
|
const next = [
|
|
1385
1536
|
...cursor === void 0 ? [] : [stepOf(PAGE_NEXT, { command, args: { ...args, cursor, limit }, values: { shown: items.length } })],
|
|
1386
|
-
...
|
|
1537
|
+
...pending2 ? [
|
|
1387
1538
|
stepOf(SEARCH_AGAIN, {
|
|
1388
1539
|
command,
|
|
1389
1540
|
args: Object.fromEntries(Object.entries(args).filter(([key]) => key !== "cursor"))
|
|
@@ -1399,7 +1550,7 @@ var meetingHitsList = /* @__PURE__ */ __name((found, limit, command = "search me
|
|
|
1399
1550
|
...cursor === void 0 ? {} : { next_cursor: cursor }
|
|
1400
1551
|
},
|
|
1401
1552
|
...next.length > 0 ? { next } : {},
|
|
1402
|
-
...
|
|
1553
|
+
...pending2 ? {
|
|
1403
1554
|
missing: [
|
|
1404
1555
|
{
|
|
1405
1556
|
field: "excerpt",
|
|
@@ -1412,7 +1563,7 @@ var meetingHitsList = /* @__PURE__ */ __name((found, limit, command = "search me
|
|
|
1412
1563
|
};
|
|
1413
1564
|
}, "meetingHitsList");
|
|
1414
1565
|
|
|
1415
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1566
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/participant-search.js
|
|
1416
1567
|
var normalizeMeetingParticipantQuery = /* @__PURE__ */ __name((text6) => text6.normalize("NFKC").toLowerCase(), "normalizeMeetingParticipantQuery");
|
|
1417
1568
|
var validateMeetingParticipantQuery = /* @__PURE__ */ __name((query) => {
|
|
1418
1569
|
if (typeof query !== "string" || !query.trim() || query.length > 500 || query.includes("\0"))
|
|
@@ -1436,7 +1587,7 @@ var validateMeetingParticipantSearch = /* @__PURE__ */ __name((query, input) =>
|
|
|
1436
1587
|
};
|
|
1437
1588
|
}, "validateMeetingParticipantSearch");
|
|
1438
1589
|
|
|
1439
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1590
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/reads.js
|
|
1440
1591
|
var MeetingError = class extends CliError {
|
|
1441
1592
|
static {
|
|
1442
1593
|
__name(this, "MeetingError");
|
|
@@ -1568,7 +1719,7 @@ var meetingSummaryAnswer = /* @__PURE__ */ __name(async (store, id4, accountId)
|
|
|
1568
1719
|
return wholeList(details.summaries.map((one) => meetingSummaryItem(details.meeting.accountId, one)));
|
|
1569
1720
|
}, "meetingSummaryAnswer");
|
|
1570
1721
|
|
|
1571
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1722
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/export.js
|
|
1572
1723
|
var timestamp = /* @__PURE__ */ __name((milliseconds) => {
|
|
1573
1724
|
if (!Number.isSafeInteger(milliseconds) || milliseconds < 0)
|
|
1574
1725
|
throw new MeetingError("validation_error", "transcript times must be nonnegative integer milliseconds");
|
|
@@ -1664,7 +1815,7 @@ var exportMeeting = /* @__PURE__ */ __name(async (store, id4, options) => {
|
|
|
1664
1815
|
};
|
|
1665
1816
|
}, "exportMeeting");
|
|
1666
1817
|
|
|
1667
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1818
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/payment.js
|
|
1668
1819
|
var FACT_TYPES = ["fact", "statement", "question", "decision", "promise"];
|
|
1669
1820
|
var PAYMENT_DIRECTIONS = ["to_us", "from_us"];
|
|
1670
1821
|
var PAYMENT_STATES = ["expected", "paid", "cancelled"];
|
|
@@ -1758,10 +1909,10 @@ var paymentTitle = /* @__PURE__ */ __name((fact) => {
|
|
|
1758
1909
|
return `${grouped(payment.amount)} ${payment.currency} ${way}${party}${item}${due} (${payment.state})`;
|
|
1759
1910
|
}, "paymentTitle");
|
|
1760
1911
|
|
|
1761
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1912
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/findings-rules.js
|
|
1762
1913
|
import { createHash as createHash2 } from "node:crypto";
|
|
1763
1914
|
|
|
1764
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1915
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/timestamp.js
|
|
1765
1916
|
var meetingTimestamp = /* @__PURE__ */ __name((value, name) => {
|
|
1766
1917
|
if (typeof value !== "string" || !/^\d{4}-\d{2}-\d{2}T.+(?:Z|[+-]\d{2}:\d{2})$/i.test(value) || !Number.isFinite(Date.parse(value)))
|
|
1767
1918
|
throw new CliError("validation_error", `${name} must be an ISO timestamp with a timezone, such as 2026-11-09T09:00:00Z`);
|
|
@@ -1772,7 +1923,7 @@ var meetingTimestamp = /* @__PURE__ */ __name((value, name) => {
|
|
|
1772
1923
|
return new Date(value).toISOString();
|
|
1773
1924
|
}, "meetingTimestamp");
|
|
1774
1925
|
|
|
1775
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
1926
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/findings-rules.js
|
|
1776
1927
|
var TASK_TYPES = ["bug", "feature", "chore"];
|
|
1777
1928
|
var invalid3 = /* @__PURE__ */ __name((message) => {
|
|
1778
1929
|
throw new CliError("validation_error", message);
|
|
@@ -1945,7 +2096,7 @@ var validateBatch = /* @__PURE__ */ __name((input, rules, most, one) => {
|
|
|
1945
2096
|
var validateFindings = /* @__PURE__ */ __name((input, rules) => validateBatch(input, rules, 16, (finding, ids2) => validateFinding(finding, rules, ids2)), "validateFindings");
|
|
1946
2097
|
var findingFingerprint = /* @__PURE__ */ __name(({ id: _id, ...finding }) => findingHash(finding), "findingFingerprint");
|
|
1947
2098
|
|
|
1948
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2099
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/findings.js
|
|
1949
2100
|
var MEETING_FINDINGS_KIND = "meeting_findings";
|
|
1950
2101
|
var cue = /* @__PURE__ */ __name((raw) => {
|
|
1951
2102
|
const reference2 = canonicalMeetingReference(raw);
|
|
@@ -1956,7 +2107,7 @@ var cue = /* @__PURE__ */ __name((raw) => {
|
|
|
1956
2107
|
var validateMeetingFindings = /* @__PURE__ */ __name((input) => validateFindings(input, { plural: "meeting findings", singular: "meeting finding", cited: "cue", reference: cue }), "validateMeetingFindings");
|
|
1957
2108
|
var meetingFindingFingerprint = findingFingerprint;
|
|
1958
2109
|
|
|
1959
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2110
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/result-items.js
|
|
1960
2111
|
var text3 = string();
|
|
1961
2112
|
var identifier = pipe(text3, minLength(1));
|
|
1962
2113
|
var nullableText = nullable(text3);
|
|
@@ -2089,7 +2240,7 @@ var MEETING_RESULT_ENTITIES = {
|
|
|
2089
2240
|
meeting_repair: repair
|
|
2090
2241
|
};
|
|
2091
2242
|
|
|
2092
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2243
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/event-query.js
|
|
2093
2244
|
var EVENT_QUERY = defineQuery({
|
|
2094
2245
|
entity: "event",
|
|
2095
2246
|
backend: "sql",
|
|
@@ -2105,7 +2256,7 @@ var EVENT_QUERY = defineQuery({
|
|
|
2105
2256
|
]
|
|
2106
2257
|
});
|
|
2107
2258
|
|
|
2108
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2259
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/events.js
|
|
2109
2260
|
var linkEvent = /* @__PURE__ */ __name(async (store, details, now = Date.now()) => {
|
|
2110
2261
|
const current = await store.meeting(details.meeting.id);
|
|
2111
2262
|
if (!current)
|
|
@@ -2148,7 +2299,7 @@ var linkEvent = /* @__PURE__ */ __name(async (store, details, now = Date.now())
|
|
|
2148
2299
|
return (await store.events()).find((e) => e.id === linked?.meeting.eventId) ?? null;
|
|
2149
2300
|
}, "linkEvent");
|
|
2150
2301
|
|
|
2151
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2302
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/hit-query.js
|
|
2152
2303
|
var context = {
|
|
2153
2304
|
command: "search meetings",
|
|
2154
2305
|
guide: "https://github.com/WireCatLabs/cli-core/blob/main/docs/search/query-language.md#\u0432\u0441\u0442\u0440\u0435\u0447\u0438"
|
|
@@ -2212,7 +2363,7 @@ var MEETING_FIELDS = defineQuery({
|
|
|
2212
2363
|
var MEETING_FIELD_NAMES = new Set(MEETING_FIELDS.fields.map(({ name }) => name));
|
|
2213
2364
|
var parseMeetingQuery = /* @__PURE__ */ __name((query) => validateQuery(parseLucene(query, { defaultField: "text", proximity: true, ...context }), MEETING_HIT_QUERY, context), "parseMeetingQuery");
|
|
2214
2365
|
|
|
2215
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2366
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/language.js
|
|
2216
2367
|
var LATIN_WORDS = {
|
|
2217
2368
|
en: ["the", "and", "is", "that", "you", "this", "what", "have", "with", "are"],
|
|
2218
2369
|
es: ["el", "los", "las", "por", "pero", "para", "est\xE1", "muy", "tambi\xE9n", "hay"],
|
|
@@ -2261,7 +2412,7 @@ var transcriptLanguage = /* @__PURE__ */ __name((texts) => {
|
|
|
2261
2412
|
return null;
|
|
2262
2413
|
}, "transcriptLanguage");
|
|
2263
2414
|
|
|
2264
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2415
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/ingest.js
|
|
2265
2416
|
var contentHash = /* @__PURE__ */ __name(async (text6) => {
|
|
2266
2417
|
const bytes = await crypto.subtle.digest("SHA-256", new TextEncoder().encode(text6));
|
|
2267
2418
|
return Array.from(new Uint8Array(bytes), (byte) => byte.toString(16).padStart(2, "0")).join("");
|
|
@@ -2298,7 +2449,7 @@ var timestamp2 = /* @__PURE__ */ __name((value) => {
|
|
|
2298
2449
|
return time2;
|
|
2299
2450
|
}, "timestamp");
|
|
2300
2451
|
|
|
2301
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2452
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/transcript-text.js
|
|
2302
2453
|
var TranscriptTextError = class extends Error {
|
|
2303
2454
|
static {
|
|
2304
2455
|
__name(this, "TranscriptTextError");
|
|
@@ -2353,7 +2504,7 @@ var parseTranscriptText = /* @__PURE__ */ __name((input) => {
|
|
|
2353
2504
|
return { header, lines };
|
|
2354
2505
|
}, "parseTranscriptText");
|
|
2355
2506
|
|
|
2356
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2507
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/vtt.js
|
|
2357
2508
|
var VttError = class extends Error {
|
|
2358
2509
|
static {
|
|
2359
2510
|
__name(this, "VttError");
|
|
@@ -2405,7 +2556,7 @@ var parseVtt = /* @__PURE__ */ __name((input) => {
|
|
|
2405
2556
|
return cues;
|
|
2406
2557
|
}, "parseVtt");
|
|
2407
2558
|
|
|
2408
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2559
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/import.js
|
|
2409
2560
|
var importFiles = /* @__PURE__ */ __name(async (files, store, now = Date.now()) => {
|
|
2410
2561
|
const report = { meetings: 0, participants: 0, transcriptRows: 0, summaries: 0, warnings: [] };
|
|
2411
2562
|
for (const file of files) {
|
|
@@ -2438,10 +2589,10 @@ var importFiles = /* @__PURE__ */ __name(async (files, store, now = Date.now())
|
|
|
2438
2589
|
return report;
|
|
2439
2590
|
}, "importFiles");
|
|
2440
2591
|
|
|
2441
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2592
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/links.js
|
|
2442
2593
|
var CHAT_MESSAGES_READ = 1e5;
|
|
2443
2594
|
|
|
2444
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2595
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/meeting-management.js
|
|
2445
2596
|
var nonempty = /* @__PURE__ */ __name((value, name) => {
|
|
2446
2597
|
if (typeof value !== "string" || !value.trim())
|
|
2447
2598
|
throw new CliError("validation_error", `${name} must be nonempty`);
|
|
@@ -2492,7 +2643,7 @@ var validateMeetingChange = /* @__PURE__ */ __name((change, create) => {
|
|
|
2492
2643
|
return Object.freeze(result);
|
|
2493
2644
|
}, "validateMeetingChange");
|
|
2494
2645
|
|
|
2495
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2646
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/passage.js
|
|
2496
2647
|
var meetingHitContextLimits = /* @__PURE__ */ __name((options = {}) => {
|
|
2497
2648
|
const { before = 3, after = 3, bytes = 65536, max_read_bytes = 4194304, expected_fingerprint } = options;
|
|
2498
2649
|
if (![before, after].every((value) => Number.isSafeInteger(value) && value >= 0) || before + after > 999 || !Number.isSafeInteger(bytes) || bytes < 2 || bytes > 4194304 || !Number.isSafeInteger(max_read_bytes) || max_read_bytes < 1 || max_read_bytes > 67108864 || expected_fingerprint !== void 0 && (typeof expected_fingerprint !== "string" || !/^[a-f0-9]{64}$/.test(expected_fingerprint)))
|
|
@@ -2505,7 +2656,7 @@ var validateMeetingPassage = /* @__PURE__ */ __name((reference2, options) => {
|
|
|
2505
2656
|
throw new CliError("validation_error", "choose a cue reference and json, text or markdown output");
|
|
2506
2657
|
}, "validateMeetingPassage");
|
|
2507
2658
|
|
|
2508
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2659
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/preparation-context.js
|
|
2509
2660
|
var validateMeetingPreparationContext = /* @__PURE__ */ __name((original) => {
|
|
2510
2661
|
if (!original || typeof original !== "object" || Array.isArray(original))
|
|
2511
2662
|
throw new CliError("validation_error", "meeting preparation context is required");
|
|
@@ -2530,7 +2681,7 @@ var validateMeetingPreparationContext = /* @__PURE__ */ __name((original) => {
|
|
|
2530
2681
|
return { ...input, limit, maxReadBytes };
|
|
2531
2682
|
}, "validateMeetingPreparationContext");
|
|
2532
2683
|
|
|
2533
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2684
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/project-evidence-answer.js
|
|
2534
2685
|
var count4 = pipe(number(), integer(), minValue(0));
|
|
2535
2686
|
var id = pipe(string(), minLength(1));
|
|
2536
2687
|
var meetingProjectEvidence = strictObject({
|
|
@@ -2651,7 +2802,7 @@ var meetingProjectEvidenceAnswer = /* @__PURE__ */ __name((page, prepared, comma
|
|
|
2651
2802
|
};
|
|
2652
2803
|
}, "meetingProjectEvidenceAnswer");
|
|
2653
2804
|
|
|
2654
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2805
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/search-validation.js
|
|
2655
2806
|
var validateMeetingHitSearch = /* @__PURE__ */ __name((query, options = {}) => {
|
|
2656
2807
|
const integer3 = /* @__PURE__ */ __name((value, low, high) => Number.isSafeInteger(value) && value >= low && value <= high, "integer");
|
|
2657
2808
|
if (typeof query !== "string" || !query.trim() || query.includes("\0") || new TextEncoder().encode(query).byteLength > 65536 || !integer3(options.limit ?? 100, 1, 1e3) || !integer3(options.maxReadBytes ?? 4194304, 1, 67108864) || [
|
|
@@ -2671,7 +2822,7 @@ var validateMeetingHitSearch = /* @__PURE__ */ __name((query, options = {}) => {
|
|
|
2671
2822
|
throw new CliError("validation_error", "choose one project selector and one tag or topic selector");
|
|
2672
2823
|
}, "validateMeetingHitSearch");
|
|
2673
2824
|
|
|
2674
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2825
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/project-evidence-query.js
|
|
2675
2826
|
var ids = {
|
|
2676
2827
|
meeting_id: "meetingId",
|
|
2677
2828
|
identity_id: "participantIdentityId",
|
|
@@ -2762,7 +2913,7 @@ var prepareMeetingProjectEvidence = /* @__PURE__ */ __name((project2, request =
|
|
|
2762
2913
|
return { project: project2.trim(), options, query: frozen.join(" AND ") };
|
|
2763
2914
|
}, "prepareMeetingProjectEvidence");
|
|
2764
2915
|
|
|
2765
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2916
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/project-evidence.js
|
|
2766
2917
|
var readMeetingProjectEvidence = /* @__PURE__ */ __name(async (read, project2, request = {}, now = Date.now()) => {
|
|
2767
2918
|
const prepared = prepareMeetingProjectEvidence(project2, request, now);
|
|
2768
2919
|
const page = await read(prepared.project, prepared.options);
|
|
@@ -2770,7 +2921,7 @@ var readMeetingProjectEvidence = /* @__PURE__ */ __name(async (read, project2, r
|
|
|
2770
2921
|
return meetingProjectEvidenceAnswer(page, prepared);
|
|
2771
2922
|
}, "readMeetingProjectEvidence");
|
|
2772
2923
|
|
|
2773
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
2924
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/pull.js
|
|
2774
2925
|
var participantInput = /* @__PURE__ */ __name((p, provider, occurrenceId2, position, accountId) => {
|
|
2775
2926
|
const { identityExternalId, ...fields } = p;
|
|
2776
2927
|
const externalId = identityExternalId ?? (p.email ? `email:${p.email.toLowerCase()}` : p.externalId) ?? `name:${p.displayName ?? "unknown"}@${accountId}/${occurrenceId2}:${position}`;
|
|
@@ -2932,7 +3083,7 @@ unlinked`, format)],
|
|
|
2932
3083
|
return report;
|
|
2933
3084
|
}, "pull");
|
|
2934
3085
|
|
|
2935
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3086
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/read-answers.js
|
|
2936
3087
|
var text4 = string();
|
|
2937
3088
|
var count5 = pipe(number(), integer(), minValue(0));
|
|
2938
3089
|
var id2 = pipe(number(), integer(), minValue(1));
|
|
@@ -3126,10 +3277,10 @@ var eventItem = /* @__PURE__ */ __name((one) => ({
|
|
|
3126
3277
|
updated_at: new Date(one.updatedAt).toISOString()
|
|
3127
3278
|
}), "eventItem");
|
|
3128
3279
|
|
|
3129
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3280
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/recording-transfer.js
|
|
3130
3281
|
var strongRecordingValidator = /* @__PURE__ */ __name((value) => typeof value === "string" && value.length <= 1024 && /^"[\x21\x23-\x7e\x80-\xff]*"$/.test(value), "strongRecordingValidator");
|
|
3131
3282
|
|
|
3132
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3283
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/related-history.js
|
|
3133
3284
|
var validateMeetingRelatedHistory = /* @__PURE__ */ __name((original) => {
|
|
3134
3285
|
if (!original || typeof original !== "object" || Array.isArray(original))
|
|
3135
3286
|
throw new CliError("validation_error", "related history request is required");
|
|
@@ -3159,14 +3310,14 @@ var validateMeetingRelatedHistory = /* @__PURE__ */ __name((original) => {
|
|
|
3159
3310
|
return { ...input, anchorIds: [...new Set(input.anchorIds)], limit, maxReadBytes };
|
|
3160
3311
|
}, "validateMeetingRelatedHistory");
|
|
3161
3312
|
|
|
3162
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3313
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/review.js
|
|
3163
3314
|
var REVIEW_LIMIT = { default: 50, most: 200 };
|
|
3164
3315
|
|
|
3165
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3316
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/save-hints.js
|
|
3166
3317
|
var SAVE_HELP = `Worth keeping \u2014 a decision, a promise, a preference? Record it with \`memo facts add\` or
|
|
3167
3318
|
\`memo memories add\`, citing the msg: locator or meeting: reference as --evidence.`;
|
|
3168
3319
|
|
|
3169
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3320
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/series-history.js
|
|
3170
3321
|
var validateMeetingSeriesHistory = /* @__PURE__ */ __name((input) => {
|
|
3171
3322
|
input.signal?.throwIfAborted();
|
|
3172
3323
|
if (!Number.isSafeInteger(input.accountId) || input.accountId <= 0)
|
|
@@ -3187,10 +3338,10 @@ var validateMeetingSeriesHistory = /* @__PURE__ */ __name((input) => {
|
|
|
3187
3338
|
return { ...input, limit, maxReadBytes };
|
|
3188
3339
|
}, "validateMeetingSeriesHistory");
|
|
3189
3340
|
|
|
3190
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3341
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/upcoming-validation.js
|
|
3191
3342
|
var occurrenceId = /* @__PURE__ */ __name((value) => typeof value === "string" && value.trim().length > 0 && value.length <= 1e3 && !/[\0\r\n]/.test(value), "occurrenceId");
|
|
3192
3343
|
|
|
3193
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3344
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/series-inventory-validation.js
|
|
3194
3345
|
function invalid4(field, response = false) {
|
|
3195
3346
|
throw new CliError(response ? "invalid_response" : "validation_error", `invalid meeting inventory ${field}`);
|
|
3196
3347
|
}
|
|
@@ -3219,7 +3370,7 @@ var validateMeetingSeriesInventoryCursor = /* @__PURE__ */ __name((value) => {
|
|
|
3219
3370
|
cursorDetails(value);
|
|
3220
3371
|
}, "validateMeetingSeriesInventoryCursor");
|
|
3221
3372
|
|
|
3222
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3373
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/meetings/stats.js
|
|
3223
3374
|
var MEETING_COUNTS_GROUPINGS = ["day", "week", "series"];
|
|
3224
3375
|
var zoneOf = /* @__PURE__ */ __name((timeZone) => {
|
|
3225
3376
|
const zone = timeZone ?? "UTC";
|
|
@@ -3354,130 +3505,7 @@ var aggregateMeetingStats = /* @__PURE__ */ __name((rows, timeZone) => {
|
|
|
3354
3505
|
};
|
|
3355
3506
|
}, "aggregateMeetingStats");
|
|
3356
3507
|
|
|
3357
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3358
|
-
var CURRENCY_SCALES = {
|
|
3359
|
-
AED: 2,
|
|
3360
|
-
AMD: 2,
|
|
3361
|
-
AUD: 2,
|
|
3362
|
-
BHD: 3,
|
|
3363
|
-
BYN: 2,
|
|
3364
|
-
CAD: 2,
|
|
3365
|
-
CHF: 2,
|
|
3366
|
-
CLP: 0,
|
|
3367
|
-
CNY: 2,
|
|
3368
|
-
CZK: 2,
|
|
3369
|
-
DKK: 2,
|
|
3370
|
-
EUR: 2,
|
|
3371
|
-
GBP: 2,
|
|
3372
|
-
GEL: 2,
|
|
3373
|
-
HUF: 2,
|
|
3374
|
-
ILS: 2,
|
|
3375
|
-
INR: 2,
|
|
3376
|
-
ISK: 0,
|
|
3377
|
-
JPY: 0,
|
|
3378
|
-
KGS: 2,
|
|
3379
|
-
KRW: 0,
|
|
3380
|
-
KWD: 3,
|
|
3381
|
-
KZT: 2,
|
|
3382
|
-
NOK: 2,
|
|
3383
|
-
PLN: 2,
|
|
3384
|
-
RSD: 2,
|
|
3385
|
-
RUB: 2,
|
|
3386
|
-
SEK: 2,
|
|
3387
|
-
THB: 2,
|
|
3388
|
-
TRY: 2,
|
|
3389
|
-
UAH: 2,
|
|
3390
|
-
USD: 2,
|
|
3391
|
-
UZS: 2,
|
|
3392
|
-
VND: 0
|
|
3393
|
-
};
|
|
3394
|
-
var refuse = /* @__PURE__ */ __name((message, reason) => {
|
|
3395
|
-
throw new CliError("validation_error", message, { reason });
|
|
3396
|
-
}, "refuse");
|
|
3397
|
-
var DECIMAL = /^(\d{1,15})(?:\.(\d+))?$/;
|
|
3398
|
-
var parseDecimal = /* @__PURE__ */ __name((text6, scale) => {
|
|
3399
|
-
const match = DECIMAL.exec(text6.trim());
|
|
3400
|
-
if (!match || (match[2] ?? "").length > scale)
|
|
3401
|
-
return void 0;
|
|
3402
|
-
return BigInt(`${match[1]}${(match[2] ?? "").padEnd(scale, "0")}`);
|
|
3403
|
-
}, "parseDecimal");
|
|
3404
|
-
var formatDecimal = /* @__PURE__ */ __name((units, scale) => {
|
|
3405
|
-
const value = BigInt(units);
|
|
3406
|
-
if (value < 0n)
|
|
3407
|
-
return `-${formatDecimal(-value, scale)}`;
|
|
3408
|
-
const digits = value.toString().padStart(scale + 1, "0");
|
|
3409
|
-
return scale === 0 ? digits : `${digits.slice(0, -scale)}.${digits.slice(-scale)}`;
|
|
3410
|
-
}, "formatDecimal");
|
|
3411
|
-
var groupDigits = /* @__PURE__ */ __name((decimal) => {
|
|
3412
|
-
const [whole = "0", fraction] = decimal.split(".");
|
|
3413
|
-
const grouped2 = whole.replace(/\B(?=(\d{3})+(?!\d))/g, " ");
|
|
3414
|
-
return fraction === void 0 ? grouped2 : `${grouped2}.${fraction}`;
|
|
3415
|
-
}, "groupDigits");
|
|
3416
|
-
var currencyOf = /* @__PURE__ */ __name((text6) => {
|
|
3417
|
-
const code = typeof text6 === "string" ? text6.trim().toUpperCase() : "";
|
|
3418
|
-
if (CURRENCY_SCALES[code] === void 0)
|
|
3419
|
-
return refuse(`${typeof text6 === "string" && text6.trim() ? text6.trim() : "an empty currency"} is not a currency the store keeps; use one of ${Object.keys(CURRENCY_SCALES).join(", ")}`, "money.currency");
|
|
3420
|
-
return code;
|
|
3421
|
-
}, "currencyOf");
|
|
3422
|
-
var scaleOf = /* @__PURE__ */ __name((currency) => CURRENCY_SCALES[currencyOf(currency)], "scaleOf");
|
|
3423
|
-
var minorUnits = /* @__PURE__ */ __name((amount, currency, what = "an amount") => {
|
|
3424
|
-
const scale = scaleOf(currency);
|
|
3425
|
-
const units = typeof amount === "string" ? parseDecimal(amount, scale) : void 0;
|
|
3426
|
-
if (units === void 0 || units > BigInt(Number.MAX_SAFE_INTEGER))
|
|
3427
|
-
return refuse(`${what} is a decimal string with at most ${scale} decimal${scale === 1 ? "" : "s"} for ${currency}, such as "${formatDecimal(5e3 * 10 ** scale, scale)}"`, "money.amount");
|
|
3428
|
-
return Number(units);
|
|
3429
|
-
}, "minorUnits");
|
|
3430
|
-
var signedMinorUnits = /* @__PURE__ */ __name((amount, currency, what = "an amount") => {
|
|
3431
|
-
if (typeof amount !== "string" || !amount.trim().startsWith("-"))
|
|
3432
|
-
return minorUnits(amount, currency, what);
|
|
3433
|
-
const units = minorUnits(amount.trim().slice(1), currency, what);
|
|
3434
|
-
return units === 0 ? 0 : -units;
|
|
3435
|
-
}, "signedMinorUnits");
|
|
3436
|
-
var moneyOf = /* @__PURE__ */ __name((units, currency) => ({
|
|
3437
|
-
amount: formatDecimal(units, scaleOf(currency)),
|
|
3438
|
-
currency
|
|
3439
|
-
}), "moneyOf");
|
|
3440
|
-
var moneyLabel = /* @__PURE__ */ __name((units, currency) => `${groupDigits(formatDecimal(units, scaleOf(currency)))} ${currency}`, "moneyLabel");
|
|
3441
|
-
var QUANTITY_SCALE = 3;
|
|
3442
|
-
var quantityOf = /* @__PURE__ */ __name((text6) => {
|
|
3443
|
-
const thousandths = typeof text6 === "string" ? parseDecimal(text6, QUANTITY_SCALE) : void 0;
|
|
3444
|
-
if (thousandths === void 0 || thousandths === 0n)
|
|
3445
|
-
return refuse('a quantity is a decimal string above 0 with at most 3 decimals, such as "1.5"', "money.quantity");
|
|
3446
|
-
const plain = formatDecimal(thousandths, QUANTITY_SCALE).replace(/\.?0+$/, "");
|
|
3447
|
-
return { text: plain, thousandths };
|
|
3448
|
-
}, "quantityOf");
|
|
3449
|
-
var lineUnits = /* @__PURE__ */ __name((thousandths, unitPrice) => Number((thousandths * BigInt(unitPrice) + 500n) / 1000n), "lineUnits");
|
|
3450
|
-
|
|
3451
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.608.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.80.8_commander@15._981e87e6afb3f510e9b2b59ded3c7286/node_modules/@wirecat/cli-core/dist/domain/finance.js
|
|
3452
|
-
var INVOICE_DIRECTIONS = ["receivable", "payable"];
|
|
3453
|
-
var INVOICE_STATUSES = ["draft", "issued", "partly_paid", "paid", "void"];
|
|
3454
|
-
var MONEY_DIRECTIONS = ["in", "out"];
|
|
3455
|
-
var FINANCE_REVIEWS = ["proposed", "confirmed", "rejected"];
|
|
3456
|
-
var settledStatus = /* @__PURE__ */ __name((current, total, paid) => {
|
|
3457
|
-
if (current === "draft" || current === "void")
|
|
3458
|
-
return current;
|
|
3459
|
-
if (paid <= 0)
|
|
3460
|
-
return "issued";
|
|
3461
|
-
return paid < total ? "partly_paid" : "paid";
|
|
3462
|
-
}, "settledStatus");
|
|
3463
|
-
var dayMonth = /* @__PURE__ */ __name((date) => date === null ? null : `${date.slice(8, 10)}.${date.slice(5, 7)}`, "dayMonth");
|
|
3464
|
-
var notes = /* @__PURE__ */ __name((...words2) => {
|
|
3465
|
-
const kept = words2.filter((word) => word !== null);
|
|
3466
|
-
return kept.length === 0 ? "" : ` (${kept.join(", ")})`;
|
|
3467
|
-
}, "notes");
|
|
3468
|
-
var invoiceLine = /* @__PURE__ */ __name((invoice) => {
|
|
3469
|
-
const party = invoice.counterpartyName === null ? "" : `${invoice.direction === "receivable" ? " to" : " from"} ${invoice.counterpartyName}`;
|
|
3470
|
-
const due = invoice.dueDate === null ? "" : `, due ${dayMonth(invoice.dueDate)}`;
|
|
3471
|
-
return `${invoice.number ?? `#${invoice.id}`} \xB7 ${moneyLabel(invoice.total, invoice.currency)}${party}${due}` + notes(invoice.status.replace("_", " "), invoice.review === "confirmed" ? null : invoice.review);
|
|
3472
|
-
}, "invoiceLine");
|
|
3473
|
-
var paymentLine = /* @__PURE__ */ __name((payment) => {
|
|
3474
|
-
const party = payment.partyName === null ? "" : `${payment.direction === "in" ? " from" : " to"} ${payment.partyName}`;
|
|
3475
|
-
return `${moneyLabel(payment.amount, payment.currency)}${party}, ${dayMonth(payment.date)}` + notes(payment.review === "confirmed" ? null : payment.review);
|
|
3476
|
-
}, "paymentLine");
|
|
3477
|
-
var invoiceTitle = /* @__PURE__ */ __name((invoice) => `Invoice ${invoiceLine(invoice)}`, "invoiceTitle");
|
|
3478
|
-
var paymentEntryTitle = /* @__PURE__ */ __name((payment) => `Payment \xB7 ${paymentLine(payment)}`, "paymentEntryTitle");
|
|
3479
|
-
|
|
3480
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.608.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.80.8_commander@15._981e87e6afb3f510e9b2b59ded3c7286/node_modules/@wirecat/cli-core/dist/domain/deals.js
|
|
3508
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/deals.js
|
|
3481
3509
|
var DEAL_KINDS = ["deal", "lead"];
|
|
3482
3510
|
var DEAL_STATUSES = ["open", "won", "lost"];
|
|
3483
3511
|
var STAGE_OUTCOMES = DEAL_STATUSES;
|
|
@@ -3487,7 +3515,7 @@ var dealLine = /* @__PURE__ */ __name((deal) => {
|
|
|
3487
3515
|
return `${deal.title} \xB7 ${deal.stage}${money}${deal.status === "open" ? "" : ` (${deal.status})`}`;
|
|
3488
3516
|
}, "dealLine");
|
|
3489
3517
|
|
|
3490
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3518
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/orders.js
|
|
3491
3519
|
var ORDER_STATUSES = ["placed", "shipped", "delivered", "cancelled", "returned"];
|
|
3492
3520
|
var ORDER_PURPOSES = ["personal", "business", "client", "other"];
|
|
3493
3521
|
var orderLine = /* @__PURE__ */ __name((order) => {
|
|
@@ -3497,7 +3525,14 @@ var orderLine = /* @__PURE__ */ __name((order) => {
|
|
|
3497
3525
|
}, "orderLine");
|
|
3498
3526
|
var orderTitle = /* @__PURE__ */ __name((order) => `Order ${orderLine(order)}`, "orderTitle");
|
|
3499
3527
|
|
|
3500
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3528
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/store/source-review.js
|
|
3529
|
+
var SOURCE_REVIEW_KIND = "memory_source_review";
|
|
3530
|
+
var SOURCE_REVIEW_CAUSES = ["changed", "outdated", "deleted", "contradicted"];
|
|
3531
|
+
var ERASED_TEXT = "[source erased]";
|
|
3532
|
+
var severity = /* @__PURE__ */ __name((cause) => SOURCE_REVIEW_CAUSES.indexOf(cause), "severity");
|
|
3533
|
+
var graver = /* @__PURE__ */ __name((a, b) => severity(b) > severity(a) ? b : a, "graver");
|
|
3534
|
+
|
|
3535
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/relations.js
|
|
3501
3536
|
var ORGANIZATION_ROLES = [
|
|
3502
3537
|
"employee",
|
|
3503
3538
|
"contractor",
|
|
@@ -3508,6 +3543,19 @@ var ORGANIZATION_ROLES = [
|
|
|
3508
3543
|
"contact"
|
|
3509
3544
|
];
|
|
3510
3545
|
var PROJECT_ROLES = ["owner", "manager", "contributor", "client-contact", "approver"];
|
|
3546
|
+
var ENGAGEMENT_LEVELS = ["none", "low", "medium", "high"];
|
|
3547
|
+
var isEngagement = /* @__PURE__ */ __name((value) => typeof value === "string" && ENGAGEMENT_LEVELS.includes(value), "isEngagement");
|
|
3548
|
+
var checkEngagement = /* @__PURE__ */ __name((kind, from, to, level) => {
|
|
3549
|
+
if (kind !== "member-of" || from !== "person" || to !== "project")
|
|
3550
|
+
throw new CliError("validation_error", "an engagement level is set only on a person's member-of a project", {
|
|
3551
|
+
reason: "relationship.engagement-ends"
|
|
3552
|
+
});
|
|
3553
|
+
if (!isEngagement(level))
|
|
3554
|
+
throw new CliError("validation_error", `an engagement level is one of ${ENGAGEMENT_LEVELS.join(", ")}`, {
|
|
3555
|
+
reason: "relationship.engagement-unknown"
|
|
3556
|
+
});
|
|
3557
|
+
return level;
|
|
3558
|
+
}, "checkEngagement");
|
|
3511
3559
|
var RELATIONS = {
|
|
3512
3560
|
"member-of": {
|
|
3513
3561
|
from: ["person", "organization", "project", "chat", "email_thread"],
|
|
@@ -3572,7 +3620,7 @@ var isUsable = /* @__PURE__ */ __name((standing) => standing === "confirmed" ||
|
|
|
3572
3620
|
var notOverriddenSql = /* @__PURE__ */ __name((alias) => `NOT EXISTS (SELECT 1 FROM links override WHERE override.kind = ${alias}.kind AND override.from_type = ${alias}.from_type AND override.from_id = ${alias}.from_id AND override.to_type = ${alias}.to_type AND override.to_id = ${alias}.to_id AND json_extract(override.metadata, '$.overrides') = ${alias}.id)`, "notOverriddenSql");
|
|
3573
3621
|
var usableLinkSql = /* @__PURE__ */ __name((alias, now) => `(${alias}.confirmed = 1 OR (${alias}.account_id IS NOT NULL AND ${alias}.deleted_at IS NULL))` + (now === void 0 ? "" : ` AND (${alias}.ends_at IS NULL OR ${alias}.ends_at > ${Math.trunc(now)})`), "usableLinkSql");
|
|
3574
3622
|
|
|
3575
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3623
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/tags.js
|
|
3576
3624
|
var TAG_TYPES = ["chat", "contact", "message", "task"];
|
|
3577
3625
|
var TAG = /^[a-z0-9-]{1,32}$/;
|
|
3578
3626
|
var tagOf = /* @__PURE__ */ __name((value) => {
|
|
@@ -3586,7 +3634,7 @@ var normalizeTag = /* @__PURE__ */ __name((value) => {
|
|
|
3586
3634
|
return tag;
|
|
3587
3635
|
}, "normalizeTag");
|
|
3588
3636
|
|
|
3589
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3637
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/store/sqlite/link-kinds.js
|
|
3590
3638
|
var LINK_KINDS = [
|
|
3591
3639
|
"links-to",
|
|
3592
3640
|
"blocked-by",
|
|
@@ -3610,7 +3658,7 @@ var LINK_SOURCES = [...LINK_ORIGINS, "calendar"];
|
|
|
3610
3658
|
var linkKind = /* @__PURE__ */ __name((kind) => `'${kind}'`, "linkKind");
|
|
3611
3659
|
var COUNTERPART_ROLE = "counterpart";
|
|
3612
3660
|
|
|
3613
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3661
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/tasks/model.js
|
|
3614
3662
|
var TASK_KINDS = ["question", "request", "mention", "promise"];
|
|
3615
3663
|
var TASK_STATES = ["open", "todo", "in_progress", "done", "dismissed"];
|
|
3616
3664
|
var CLOSED_STATES = ["done", "dismissed"];
|
|
@@ -3625,13 +3673,13 @@ function closeTask(task, state, by, at, reason) {
|
|
|
3625
3673
|
}
|
|
3626
3674
|
__name(closeTask, "closeTask");
|
|
3627
3675
|
|
|
3628
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3676
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/tasks/store.js
|
|
3629
3677
|
function matches2(task, filter) {
|
|
3630
3678
|
return (filter.account === void 0 || task.account === filter.account) && (filter.state === void 0 || task.state === filter.state) && (filter.group === void 0 || task.group === filter.group) && (filter.kind === void 0 || task.kind === filter.kind) && (filter.createdBefore === void 0 || task.createdAt < filter.createdBefore);
|
|
3631
3679
|
}
|
|
3632
3680
|
__name(matches2, "matches");
|
|
3633
3681
|
|
|
3634
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3682
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/tasks/priority.js
|
|
3635
3683
|
var PRIORITY_LABELS = ["low", "medium", "high", "critical"];
|
|
3636
3684
|
var MIDDLE = { low: 0.125, medium: 0.375, high: 0.625, critical: 0.875 };
|
|
3637
3685
|
var LEGACY_PRIORITY_SCORES = [0.875, 0.625, 0.375, 0.1875, 0.0625];
|
|
@@ -3660,7 +3708,7 @@ var priorityOf = /* @__PURE__ */ __name((value) => {
|
|
|
3660
3708
|
}, "priorityOf");
|
|
3661
3709
|
var priorityOption = /* @__PURE__ */ __name((value) => priorityOf(value) ?? "none", "priorityOption");
|
|
3662
3710
|
|
|
3663
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3711
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/tasks/service.js
|
|
3664
3712
|
function createTaskService({ store, now = /* @__PURE__ */ __name(() => /* @__PURE__ */ new Date(), "now"), newId = /* @__PURE__ */ __name(() => crypto.randomUUID(), "newId") }) {
|
|
3665
3713
|
async function find(id4) {
|
|
3666
3714
|
const task = await store.get(id4);
|
|
@@ -3720,7 +3768,7 @@ function median(values) {
|
|
|
3720
3768
|
}
|
|
3721
3769
|
__name(median, "median");
|
|
3722
3770
|
|
|
3723
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3771
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/domain/knowledge.js
|
|
3724
3772
|
var FACT_STATUSES = ["proposed", "accepted", "superseded", "reversed", "rejected"];
|
|
3725
3773
|
var MEMORY_KINDS = ["summary", "digest", "preference"];
|
|
3726
3774
|
var MEMORY_STATUSES = ["proposed", "confirmed", "stale", "superseded"];
|
|
@@ -3728,7 +3776,7 @@ var MEMORY_SCOPES = ["personal", "work"];
|
|
|
3728
3776
|
var WORK_TASK_TYPES = ["bug", "feature", "chore"];
|
|
3729
3777
|
var TASK_TYPES2 = [...WORK_TASK_TYPES, ...TASK_KINDS];
|
|
3730
3778
|
|
|
3731
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3779
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/entities/fields.js
|
|
3732
3780
|
var text5 = string();
|
|
3733
3781
|
var id3 = pipe(string(), minLength(1));
|
|
3734
3782
|
var time = isoTime;
|
|
@@ -3746,13 +3794,14 @@ var evidenceSource = strictObject({
|
|
|
3746
3794
|
tool: nullable(text5),
|
|
3747
3795
|
missing: boolean()
|
|
3748
3796
|
});
|
|
3797
|
+
var sourceReview = nullable(strictObject({ id: id3, cause: picklist(SOURCE_REVIEW_CAUSES) }));
|
|
3749
3798
|
var author = strictObject({
|
|
3750
3799
|
type: picklist(["person", "bot"]),
|
|
3751
3800
|
id: id3,
|
|
3752
3801
|
name: nullable(text5)
|
|
3753
3802
|
});
|
|
3754
3803
|
|
|
3755
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
3804
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.618.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.87.0_commander@15._c25084c4731872baba927966435ce31d/node_modules/@wirecat/cli-core/dist/entities/knowledge-lists.js
|
|
3756
3805
|
var organization = strictObject({
|
|
3757
3806
|
id: id3,
|
|
3758
3807
|
ref: reference,
|
|
@@ -3899,12 +3948,24 @@ export {
|
|
|
3899
3948
|
MONEY_DIRECTIONS,
|
|
3900
3949
|
FINANCE_REVIEWS,
|
|
3901
3950
|
settledStatus,
|
|
3902
|
-
dayMonth,
|
|
3903
|
-
notes,
|
|
3904
3951
|
invoiceLine,
|
|
3905
3952
|
paymentLine,
|
|
3906
3953
|
invoiceTitle,
|
|
3907
3954
|
paymentEntryTitle,
|
|
3955
|
+
CATALOG_KINDS,
|
|
3956
|
+
BUSINESS_KINDS,
|
|
3957
|
+
CONTRACT_KINDS,
|
|
3958
|
+
CONTRACT_STATUSES,
|
|
3959
|
+
SUBSCRIPTION_STATUSES,
|
|
3960
|
+
WALLET_KINDS,
|
|
3961
|
+
TRANSACTION_STATUSES,
|
|
3962
|
+
ORDER_DIRECTIONS,
|
|
3963
|
+
intervalOf,
|
|
3964
|
+
productLine,
|
|
3965
|
+
contractLine,
|
|
3966
|
+
subscriptionLine,
|
|
3967
|
+
walletLine,
|
|
3968
|
+
transactionLine,
|
|
3908
3969
|
DEAL_KINDS,
|
|
3909
3970
|
DEAL_STATUSES,
|
|
3910
3971
|
STAGE_OUTCOMES,
|
|
@@ -3914,6 +3975,13 @@ export {
|
|
|
3914
3975
|
ORDER_PURPOSES,
|
|
3915
3976
|
orderLine,
|
|
3916
3977
|
orderTitle,
|
|
3978
|
+
SOURCE_REVIEW_KIND,
|
|
3979
|
+
SOURCE_REVIEW_CAUSES,
|
|
3980
|
+
ERASED_TEXT,
|
|
3981
|
+
severity,
|
|
3982
|
+
graver,
|
|
3983
|
+
isEngagement,
|
|
3984
|
+
checkEngagement,
|
|
3917
3985
|
RELATION_KINDS,
|
|
3918
3986
|
isRelationKind,
|
|
3919
3987
|
checkEnds,
|
|
@@ -3963,6 +4031,7 @@ export {
|
|
|
3963
4031
|
untrusted,
|
|
3964
4032
|
providerMetadata,
|
|
3965
4033
|
evidenceSource,
|
|
4034
|
+
sourceReview,
|
|
3966
4035
|
author,
|
|
3967
4036
|
organization,
|
|
3968
4037
|
project,
|