@mulmoclaude/accounting-plugin 0.3.3 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/dist/server/accountNormalize.d.ts +1 -1
  2. package/dist/server/accountNormalize.d.ts.map +1 -1
  3. package/dist/server/context.d.ts +3 -10
  4. package/dist/server/context.d.ts.map +1 -1
  5. package/dist/server/defaultAccounts.d.ts +1 -1
  6. package/dist/server/defaultAccounts.d.ts.map +1 -1
  7. package/dist/server/http.d.ts.map +1 -1
  8. package/dist/server/index.d.ts +1 -1
  9. package/dist/server/index.d.ts.map +1 -1
  10. package/dist/server/io.d.ts +2 -1
  11. package/dist/server/io.d.ts.map +1 -1
  12. package/dist/server/journal.d.ts +1 -1
  13. package/dist/server/journal.d.ts.map +1 -1
  14. package/dist/server/openingBalances.d.ts +1 -1
  15. package/dist/server/openingBalances.d.ts.map +1 -1
  16. package/dist/server/report.d.ts +6 -64
  17. package/dist/server/report.d.ts.map +1 -1
  18. package/dist/server/service.d.ts +1 -1
  19. package/dist/server/service.d.ts.map +1 -1
  20. package/dist/server/snapshotCache.d.ts +2 -1
  21. package/dist/server/snapshotCache.d.ts.map +1 -1
  22. package/dist/server/timeSeries.d.ts +1 -1
  23. package/dist/server/timeSeries.d.ts.map +1 -1
  24. package/dist/server/types.d.ts +1 -123
  25. package/dist/server/types.d.ts.map +1 -1
  26. package/dist/server.cjs +22 -73
  27. package/dist/server.cjs.map +1 -1
  28. package/dist/server.js +14 -65
  29. package/dist/server.js.map +1 -1
  30. package/dist/shared/errors.d.ts +1 -1
  31. package/dist/shared/errors.d.ts.map +1 -1
  32. package/dist/shared/index.d.ts +1 -0
  33. package/dist/shared/index.d.ts.map +1 -1
  34. package/dist/shared/types.d.ts +188 -0
  35. package/dist/shared/types.d.ts.map +1 -0
  36. package/dist/shared-CcU3_qAa.cjs +749 -0
  37. package/dist/shared-CcU3_qAa.cjs.map +1 -0
  38. package/dist/shared-MOpJ1kUa.js +516 -0
  39. package/dist/shared-MOpJ1kUa.js.map +1 -0
  40. package/dist/shared.cjs +40 -519
  41. package/dist/shared.js +2 -483
  42. package/dist/vue/api.d.ts +2 -121
  43. package/dist/vue/api.d.ts.map +1 -1
  44. package/dist/vue/lang/index.d.ts +204 -215
  45. package/dist/vue/lang/index.d.ts.map +1 -1
  46. package/dist/vue.cjs +1651 -1678
  47. package/dist/vue.cjs.map +1 -1
  48. package/dist/vue.js +1652 -1679
  49. package/dist/vue.js.map +1 -1
  50. package/package.json +11 -6
  51. package/dist/server/atomic.d.ts +0 -15
  52. package/dist/server/atomic.d.ts.map +0 -1
  53. package/dist/shared.cjs.map +0 -1
  54. package/dist/shared.js.map +0 -1
package/dist/shared.js CHANGED
@@ -1,483 +1,2 @@
1
- //#region src/shared/actions.ts
2
- var ACCOUNTING_ACTIONS = {
3
- openBook: "openBook",
4
- getBooks: "getBooks",
5
- createBook: "createBook",
6
- updateBook: "updateBook",
7
- deleteBook: "deleteBook",
8
- getAccounts: "getAccounts",
9
- upsertAccount: "upsertAccount",
10
- addEntries: "addEntries",
11
- voidEntry: "voidEntry",
12
- getJournalEntries: "getJournalEntries",
13
- getOpeningBalances: "getOpeningBalances",
14
- setOpeningBalances: "setOpeningBalances",
15
- getReport: "getReport",
16
- getTimeSeries: "getTimeSeries",
17
- rebuildSnapshots: "rebuildSnapshots"
18
- };
19
- //#endregion
20
- //#region src/shared/api.ts
21
- var ACCOUNTING_API = { dispatch: {
22
- path: "/api/accounting",
23
- method: "POST"
24
- } };
25
- //#endregion
26
- //#region src/shared/channels.ts
27
- /** Channel factory for per-book event streams. Subscribers:
28
- * `useAccountingChannel(bookId)`. Publisher: the package's server
29
- * surface `eventPublisher`. */
30
- function bookChannel(bookId) {
31
- return `accounting:${bookId}`;
32
- }
33
- /** Book-list-level channel — a book was created / deleted. Subscribers
34
- * refetch the BookSwitcher dropdown. Mirrors the host META's
35
- * `staticChannels.accountingBooks` literal (kept in sync by value;
36
- * the host META stays the codegen-discoverable source for the
37
- * aggregator merge). */
38
- var ACCOUNTING_BOOKS_CHANNEL = "accounting:books";
39
- /** Event kinds that ride `bookChannel(bookId)`. Single source of
40
- * truth for both publishers (server/accounting) and subscribers
41
- * (the View) — anyone branching on event kind imports from here
42
- * and the type system catches drift on either side.
43
- *
44
- * - `journal` — addEntry / voidEntry hit the books at `period`.
45
- * Refetch the journal list and (if the View is
46
- * showing balances at or after `period`) the
47
- * relevant report.
48
- * - `opening` — setOpeningBalances. Affects every period from
49
- * the opening date forward; refetch everything.
50
- * - `accounts` — chart-of-accounts mutation that may affect
51
- * aggregation (account type changed). Refetch
52
- * accounts and the active report.
53
- * - `snapshotsRebuilding` / `snapshotsReady` — purely informational;
54
- * the View can show a "calculating" spinner
55
- * during rebuild, but the lazy-rebuild safety
56
- * net means a refetch always returns the right
57
- * answer regardless. */
58
- var BOOK_EVENT_KINDS = {
59
- journal: "journal",
60
- opening: "opening",
61
- accounts: "accounts",
62
- snapshotsRebuilding: "snapshots-rebuilding",
63
- snapshotsReady: "snapshots-ready"
64
- };
65
- //#endregion
66
- //#region src/shared/errors.ts
67
- function errorMessage(err, fallback) {
68
- if (err instanceof Error) return err.message;
69
- if (err !== null && typeof err === "object") {
70
- const obj = err;
71
- if (typeof obj.details === "string" && obj.details) return obj.details;
72
- if (typeof obj.message === "string" && obj.message) return obj.message;
73
- }
74
- if (fallback !== void 0) return fallback;
75
- return String(err);
76
- }
77
- //#endregion
78
- //#region src/shared/paths.ts
79
- var ACCOUNTING_DIRS = {
80
- /** `data/accounting/config.json` + the books tree below. */
81
- accounting: "data/accounting",
82
- /** `data/accounting/books/<bookId>/{accounts.json, journal/, snapshots/}`. */
83
- accountingBooks: "data/accounting/books"
84
- };
85
- //#endregion
86
- //#region src/shared/fiscalYear.ts
87
- var FISCAL_YEAR_END_MONTHS = [
88
- 1,
89
- 2,
90
- 3,
91
- 4,
92
- 5,
93
- 6,
94
- 7,
95
- 8,
96
- 9,
97
- 10,
98
- 11,
99
- 12
100
- ];
101
- var DEFAULT_FISCAL_YEAR_END = 12;
102
- /** Legacy calendar-quarter tokens → closing month, for books written
103
- * before the field became a month number. */
104
- var LEGACY_QUARTER_MONTHS = {
105
- Q1: 3,
106
- Q2: 6,
107
- Q3: 9,
108
- Q4: 12
109
- };
110
- function isFiscalYearEnd(value) {
111
- return typeof value === "number" && Number.isInteger(value) && value >= 1 && value <= 12;
112
- }
113
- /** Normalise any stored / inbound value to a concrete closing month.
114
- * Absent or unrecognised → the default (December); a legacy "Q1".."Q4"
115
- * token → its closing month; a valid 1-12 number → itself. Kept
116
- * tolerant (unknown input) so a legacy book read from disk — or shared
117
- * with an older MulmoTerminal — never breaks the UI or a report. */
118
- function resolveFiscalYearEnd(value) {
119
- if (isFiscalYearEnd(value)) return value;
120
- if (typeof value === "string" && Object.hasOwn(LEGACY_QUARTER_MONTHS, value)) return LEGACY_QUARTER_MONTHS[value];
121
- return 12;
122
- }
123
- /** Last calendar month (1-12) of the fiscal year. The stored token IS
124
- * the closing month now, so this reads as `resolveFiscalYearEnd` under
125
- * a name that states intent at the call sites (and still absorbs a
126
- * stray legacy token defensively). */
127
- function fiscalYearEndMonth(end) {
128
- return resolveFiscalYearEnd(end);
129
- }
130
- /** Localised label for a fiscal-year-end month, showing that month's
131
- * last day — e.g. 8 → "August 31" / "8月31日" / "31 de agosto". Uses a
132
- * fixed non-leap reference year, so February reads as the 28th; this
133
- * is display only — the engine still computes the real last day
134
- * (Feb 29 in a leap year) at runtime. */
135
- function fiscalYearEndMonthLabel(month, locale) {
136
- const lastDay = new Date(Date.UTC(2001, month, 0));
137
- try {
138
- return new Intl.DateTimeFormat(locale, {
139
- month: "long",
140
- day: "numeric",
141
- timeZone: "UTC"
142
- }).format(lastDay);
143
- } catch {
144
- return String(month);
145
- }
146
- }
147
- function pad2$1(num) {
148
- return String(num).padStart(2, "0");
149
- }
150
- function lastDayOfMonth(year, monthZeroBased) {
151
- return new Date(year, monthZeroBased + 1, 0).getDate();
152
- }
153
- function ymd(year, monthOneBased, day) {
154
- return `${year}-${pad2$1(monthOneBased)}-${pad2$1(day)}`;
155
- }
156
- /** Fiscal quarter index (0..3) of the given local date under `end`,
157
- * where 0 is the first quarter of the fiscal year (right after the
158
- * prior year's close) and 3 is the closing quarter. */
159
- function fiscalQuarterIndex(end, today) {
160
- const closingMonth = fiscalYearEndMonth(end);
161
- const offset = (today.getMonth() + 1 - closingMonth - 1 + 12) % 12;
162
- return Math.floor(offset / 3);
163
- }
164
- /** Calendar (year, monthOneBased) of the *first* month of the fiscal
165
- * quarter at index `index` in the fiscal year that *contains*
166
- * `today`. Returned both as the first day of that month and as the
167
- * count of months covered (always 3 — exposed as a constant). */
168
- function fiscalQuarterStart(end, today, index) {
169
- const closingMonth = fiscalYearEndMonth(end);
170
- const todayMonth = today.getMonth() + 1;
171
- const todayYear = today.getFullYear();
172
- const startMonth = closingMonth % 12 + 1;
173
- const fyStartYear = todayMonth >= startMonth ? todayYear : todayYear - 1;
174
- const flatMonth = startMonth + index * 3;
175
- return {
176
- year: fyStartYear + Math.floor((flatMonth - 1) / 12),
177
- month: (flatMonth - 1) % 12 + 1
178
- };
179
- }
180
- function quarterRangeAt(end, today, index) {
181
- const start = fiscalQuarterStart(end, today, index);
182
- const lastMonthFlat = start.month - 1 + 2;
183
- const lastMonthYear = start.year + Math.floor(lastMonthFlat / 12);
184
- const lastMonth = lastMonthFlat % 12 + 1;
185
- const lastDay = lastDayOfMonth(lastMonthYear, lastMonth - 1);
186
- return {
187
- from: ymd(start.year, start.month, 1),
188
- to: ymd(lastMonthYear, lastMonth, lastDay)
189
- };
190
- }
191
- function currentQuarterRange(end, today = /* @__PURE__ */ new Date()) {
192
- return quarterRangeAt(end, today, fiscalQuarterIndex(end, today));
193
- }
194
- function previousQuarterRange(end, today = /* @__PURE__ */ new Date()) {
195
- const idx = fiscalQuarterIndex(end, today);
196
- if (idx > 0) return quarterRangeAt(end, today, idx - 1);
197
- return quarterRangeAt(end, new Date(today.getFullYear(), today.getMonth() - 3, 1), 3);
198
- }
199
- /** Current fiscal year — Q0 start through Q3 close. */
200
- function currentFiscalYearRange(end, today = /* @__PURE__ */ new Date()) {
201
- const first = quarterRangeAt(end, today, 0);
202
- const last = quarterRangeAt(end, today, 3);
203
- return {
204
- from: first.from,
205
- to: last.to
206
- };
207
- }
208
- function previousFiscalYearRange(end, today = /* @__PURE__ */ new Date()) {
209
- return currentFiscalYearRange(end, new Date(today.getFullYear() - 1, today.getMonth(), today.getDate()));
210
- }
211
- //#endregion
212
- //#region src/shared/countries.ts
213
- /** ISO 3166-1 alpha-2 country codes shown in the book country
214
- * dropdown. Curated to cover every jurisdiction the Accounting role
215
- * has explicit tax-registration advice for, plus the major economies
216
- * represented in `SUPPORTED_CURRENCY_CODES`. */
217
- var SUPPORTED_COUNTRY_CODES = [
218
- "US",
219
- "JP",
220
- "GB",
221
- "CA",
222
- "AU",
223
- "NZ",
224
- "DE",
225
- "FR",
226
- "IT",
227
- "ES",
228
- "NL",
229
- "BE",
230
- "AT",
231
- "IE",
232
- "PT",
233
- "FI",
234
- "SE",
235
- "DK",
236
- "PL",
237
- "CH",
238
- "NO",
239
- "CN",
240
- "KR",
241
- "TW",
242
- "HK",
243
- "SG",
244
- "IN",
245
- "BR",
246
- "MX"
247
- ];
248
- /** EU member states as of 2026. Used by the role-prompt advice path
249
- * to recommend a VAT identification number when the book country is
250
- * in the EU. */
251
- var EU_COUNTRY_CODES = /* @__PURE__ */ new Set([
252
- "AT",
253
- "BE",
254
- "BG",
255
- "CY",
256
- "CZ",
257
- "DE",
258
- "DK",
259
- "EE",
260
- "ES",
261
- "FI",
262
- "FR",
263
- "GR",
264
- "HR",
265
- "HU",
266
- "IE",
267
- "IT",
268
- "LT",
269
- "LU",
270
- "LV",
271
- "MT",
272
- "NL",
273
- "PL",
274
- "PT",
275
- "RO",
276
- "SE",
277
- "SI",
278
- "SK"
279
- ]);
280
- /** Localized human name for a country code. Falls back to the code
281
- * itself if the runtime can't resolve the name. */
282
- function localizedCountryName(code, locale) {
283
- try {
284
- return new Intl.DisplayNames([locale], { type: "region" }).of(code) ?? code;
285
- } catch {
286
- return code;
287
- }
288
- }
289
- /** Runtime guard for `BookSummary.country`. The type is the union
290
- * `SupportedCountryCode`, but every entry point that takes user /
291
- * LLM input arrives as raw `string` (form submit, JSON-RPC body),
292
- * so the service layer narrows here before persisting. */
293
- function isSupportedCountryCode(value) {
294
- return typeof value === "string" && SUPPORTED_COUNTRY_CODES.includes(value);
295
- }
296
- /** Country-gated UI features. Each key is a feature name; the value
297
- * is the set of country codes for which the feature is enabled.
298
- * Components ask `countryHasFeature("...", country)` instead of
299
- * hard-coding country lists at the call site.
300
- *
301
- * Add a new country-specific feature by adding a new key here and
302
- * reading it via `countryHasFeature`. An unknown / undefined
303
- * country never has any feature — components fall back to neutral
304
- * default UI rather than guessing.
305
- *
306
- * Mirrors the "Country-aware tax behaviour" prose in the
307
- * Accounting role prompt (`src/config/roles.ts`). The two MUST
308
- * stay in sync — drift means the LLM and the form give the user
309
- * contradictory advice. The prompt is the source of truth for
310
- * agent behaviour; this table is structured-data sibling for the
311
- * form. */
312
- var COUNTRY_FEATURES = {
313
- /** Show an amber "missing tax ID" warning + helper text on a
314
- * postable 14xx (input-tax) line whose taxRegistrationId is
315
- * blank. Limited to jurisdictions where the role prompt
316
- * explicitly requires the counterparty registration number
317
- * (JP T-number, EU VAT ID, GB VAT, GSTIN, ABN, NZ GST, CA BN).
318
- * The "other countries" bucket and US (no federal sales-tax
319
- * registration) intentionally stay quiet. 24xx output-tax
320
- * lines don't trigger the warning — see `isTaxAccountCode`. */
321
- warnMissingTaxRegistrationId: /* @__PURE__ */ new Set([
322
- "JP",
323
- "GB",
324
- "DE",
325
- "FR",
326
- "IT",
327
- "ES",
328
- "NL",
329
- "BE",
330
- "AT",
331
- "IE",
332
- "PT",
333
- "FI",
334
- "SE",
335
- "DK",
336
- "PL",
337
- "IN",
338
- "AU",
339
- "NZ",
340
- "CA"
341
- ]) };
342
- /** Resolve a country-gated feature flag. Returns `false` when the
343
- * country is undefined / unsupported — components default to the
344
- * neutral path (no warning, no extra UI) rather than guessing. */
345
- function countryHasFeature(feature, country) {
346
- if (!country) return false;
347
- return COUNTRY_FEATURES[feature].has(country);
348
- }
349
- //#endregion
350
- //#region src/shared/currencies.ts
351
- /** ISO 4217 codes shown in the New Book dropdown. Curated for
352
- * recognisability — Intl.DisplayNames provides the localised
353
- * human name at render time, so this stays a flat list of codes. */
354
- var SUPPORTED_CURRENCY_CODES = [
355
- "USD",
356
- "EUR",
357
- "JPY",
358
- "GBP",
359
- "CNY",
360
- "KRW",
361
- "TWD",
362
- "HKD",
363
- "SGD",
364
- "AUD",
365
- "CAD",
366
- "CHF",
367
- "INR",
368
- "BRL",
369
- "MXN"
370
- ];
371
- var DEFAULT_FALLBACK_DIGITS = 2;
372
- /** Localised human name for a currency code. Falls back to the
373
- * code itself if the runtime can't resolve the name. */
374
- function localizedCurrencyName(code, locale) {
375
- try {
376
- return new Intl.DisplayNames([locale], { type: "currency" }).of(code) ?? code;
377
- } catch {
378
- return code;
379
- }
380
- }
381
- /** Number of fraction digits ISO 4217 specifies for a currency.
382
- * JPY = 0, USD = 2, KWD = 3. Used both for amount formatting and
383
- * for the HTML input step on debit/credit fields. */
384
- function fractionDigitsFor(currency) {
385
- try {
386
- return new Intl.NumberFormat("en", {
387
- style: "currency",
388
- currency
389
- }).resolvedOptions().maximumFractionDigits ?? DEFAULT_FALLBACK_DIGITS;
390
- } catch {
391
- return DEFAULT_FALLBACK_DIGITS;
392
- }
393
- }
394
- /** "1" for JPY, "0.01" for USD, "0.001" for KWD. Used as the HTML
395
- * input step on debit/credit fields so a JPY book doesn't let the
396
- * user type cents that would just round-trip back through the
397
- * decimal validator. */
398
- function inputStepFor(currency) {
399
- const digits = fractionDigitsFor(currency);
400
- if (digits === 0) return "1";
401
- return (1 / 10 ** digits).toFixed(digits);
402
- }
403
- /** Locale-aware currency formatter — returns "¥1,130" / "$1,130.00"
404
- * etc. Falls back to fixed-point formatting if the runtime can't
405
- * resolve the currency code; the fallback still respects the
406
- * currency's natural fraction-digit count so JPY shows whole
407
- * numbers even on the slow path. */
408
- function formatAmount(value, currency, locale) {
409
- try {
410
- return new Intl.NumberFormat(locale, {
411
- style: "currency",
412
- currency
413
- }).format(value);
414
- } catch {
415
- return value.toFixed(fractionDigitsFor(currency));
416
- }
417
- }
418
- /** Currency-agnostic amount formatter — "1,130.00" — for places that
419
- * don't carry the currency code on the data path (compact preview
420
- * envelopes etc.). Use `formatAmount(value, currency)` whenever the
421
- * currency IS available — the currency-aware path picks the right
422
- * fraction-digit count automatically (JPY = 0, USD = 2).
423
- *
424
- * `locale` mirrors `formatAmount`'s signature: pass an explicit BCP-47
425
- * locale (`"en-US"`, `"ja-JP"`, …) when the caller knows the desired
426
- * grouping / digit-shape; omit to fall back to the runtime default. */
427
- function formatAmountNumeric(value, decimals = 2, locale) {
428
- return value.toLocaleString(locale, {
429
- minimumFractionDigits: decimals,
430
- maximumFractionDigits: decimals
431
- });
432
- }
433
- //#endregion
434
- //#region src/shared/dates.ts
435
- function pad2(num) {
436
- return String(num).padStart(2, "0");
437
- }
438
- /** Today as `YYYY-MM-DD` in the user's local timezone. */
439
- function localDateString(now = /* @__PURE__ */ new Date()) {
440
- return `${now.getFullYear()}-${pad2(now.getMonth() + 1)}-${pad2(now.getDate())}`;
441
- }
442
- /** Current month as `YYYY-MM` in the user's local timezone. */
443
- function localMonthString(now = /* @__PURE__ */ new Date()) {
444
- return `${now.getFullYear()}-${pad2(now.getMonth() + 1)}`;
445
- }
446
- /** First day of the current calendar year as `YYYY-MM-DD`. */
447
- function localStartOfYearString(now = /* @__PURE__ */ new Date()) {
448
- return `${now.getFullYear()}-01-01`;
449
- }
450
- /** Previous calendar month as `YYYY-MM` in the user's local timezone. */
451
- function previousMonthString(now = /* @__PURE__ */ new Date()) {
452
- const target = new Date(now.getFullYear(), now.getMonth() - 1, 1);
453
- return `${target.getFullYear()}-${pad2(target.getMonth() + 1)}`;
454
- }
455
- /** Last month of the previous calendar quarter as `YYYY-MM`. Calendar
456
- * quarters: Q1=Jan–Mar, Q2=Apr–Jun, Q3=Jul–Sep, Q4=Oct–Dec. When the
457
- * current month is in Q1, this rolls back to December of last year. */
458
- function lastMonthOfPreviousQuarterString(now = /* @__PURE__ */ new Date()) {
459
- const firstMonthOfCurrentQuarter = Math.floor(now.getMonth() / 3) * 3;
460
- const target = new Date(now.getFullYear(), firstMonthOfCurrentQuarter - 1, 1);
461
- return `${target.getFullYear()}-${pad2(target.getMonth() + 1)}`;
462
- }
463
- /** December of the previous calendar year as `YYYY-MM`. */
464
- function decemberOfPreviousYearString(now = /* @__PURE__ */ new Date()) {
465
- return `${now.getFullYear() - 1}-12`;
466
- }
467
- //#endregion
468
- //#region src/shared/timeSeriesEnums.ts
469
- var TIME_SERIES_METRICS = [
470
- "revenue",
471
- "expense",
472
- "netIncome",
473
- "accountBalance"
474
- ];
475
- var TIME_SERIES_GRANULARITIES = [
476
- "month",
477
- "quarter",
478
- "year"
479
- ];
480
- //#endregion
481
- export { ACCOUNTING_ACTIONS, ACCOUNTING_API, ACCOUNTING_BOOKS_CHANNEL, ACCOUNTING_DIRS, BOOK_EVENT_KINDS, COUNTRY_FEATURES, DEFAULT_FISCAL_YEAR_END, EU_COUNTRY_CODES, FISCAL_YEAR_END_MONTHS, SUPPORTED_COUNTRY_CODES, SUPPORTED_CURRENCY_CODES, TIME_SERIES_GRANULARITIES, TIME_SERIES_METRICS, bookChannel, countryHasFeature, currentFiscalYearRange, currentQuarterRange, decemberOfPreviousYearString, errorMessage, fiscalYearEndMonth, fiscalYearEndMonthLabel, formatAmount, formatAmountNumeric, fractionDigitsFor, inputStepFor, isFiscalYearEnd, isSupportedCountryCode, lastMonthOfPreviousQuarterString, localDateString, localMonthString, localStartOfYearString, localizedCountryName, localizedCurrencyName, previousFiscalYearRange, previousMonthString, previousQuarterRange, resolveFiscalYearEnd };
482
-
483
- //# sourceMappingURL=shared.js.map
1
+ import { A as resolveFiscalYearEnd, C as currentFiscalYearRange, D as isFiscalYearEnd, E as fiscalYearEndMonthLabel, F as bookChannel, I as ACCOUNT_TYPES, L as BALANCE_SHEET_ACCOUNT_TYPES, M as errorMessage, N as ACCOUNTING_BOOKS_CHANNEL, O as previousFiscalYearRange, P as BOOK_EVENT_KINDS, R as ACCOUNTING_API, S as FISCAL_YEAR_END_MONTHS, T as fiscalYearEndMonth, _ as SUPPORTED_COUNTRY_CODES, a as localDateString, b as localizedCountryName, c as previousMonthString, d as formatAmountNumeric, f as fractionDigitsFor, g as EU_COUNTRY_CODES, h as COUNTRY_FEATURES, i as lastMonthOfPreviousQuarterString, j as ACCOUNTING_DIRS, k as previousQuarterRange, l as SUPPORTED_CURRENCY_CODES, m as localizedCurrencyName, n as TIME_SERIES_METRICS, o as localMonthString, p as inputStepFor, r as decemberOfPreviousYearString, s as localStartOfYearString, t as TIME_SERIES_GRANULARITIES, u as formatAmount, v as countryHasFeature, w as currentQuarterRange, x as DEFAULT_FISCAL_YEAR_END, y as isSupportedCountryCode, z as ACCOUNTING_ACTIONS } from "./shared-MOpJ1kUa.js";
2
+ export { ACCOUNTING_ACTIONS, ACCOUNTING_API, ACCOUNTING_BOOKS_CHANNEL, ACCOUNTING_DIRS, ACCOUNT_TYPES, BALANCE_SHEET_ACCOUNT_TYPES, BOOK_EVENT_KINDS, COUNTRY_FEATURES, DEFAULT_FISCAL_YEAR_END, EU_COUNTRY_CODES, FISCAL_YEAR_END_MONTHS, SUPPORTED_COUNTRY_CODES, SUPPORTED_CURRENCY_CODES, TIME_SERIES_GRANULARITIES, TIME_SERIES_METRICS, bookChannel, countryHasFeature, currentFiscalYearRange, currentQuarterRange, decemberOfPreviousYearString, errorMessage, fiscalYearEndMonth, fiscalYearEndMonthLabel, formatAmount, formatAmountNumeric, fractionDigitsFor, inputStepFor, isFiscalYearEnd, isSupportedCountryCode, lastMonthOfPreviousQuarterString, localDateString, localMonthString, localStartOfYearString, localizedCountryName, localizedCurrencyName, previousFiscalYearRange, previousMonthString, previousQuarterRange, resolveFiscalYearEnd };
package/dist/vue/api.d.ts CHANGED
@@ -1,59 +1,6 @@
1
1
  import { type ApiResult } from "./hostContext";
2
- import { type SupportedCountryCode, type FiscalYearEnd, type TimeSeriesGranularity, type TimeSeriesMetric } from "../shared";
3
- export type AccountType = "asset" | "liability" | "equity" | "income" | "expense";
4
- export type JournalEntryKind = "normal" | "opening" | "void" | "void-marker";
5
- export interface Account {
6
- code: string;
7
- name: string;
8
- type: AccountType;
9
- note?: string;
10
- /** Soft-delete flag. When `false`, the account is hidden from
11
- * entry/ledger dropdowns but stays visible in Manage Accounts
12
- * and historical entries. */
13
- active?: boolean;
14
- }
15
- export interface JournalLine {
16
- accountCode: string;
17
- debit?: number;
18
- credit?: number;
19
- memo?: string;
20
- /** Counterparty's tax-authority-issued registration ID — JP
21
- * T-number, EU VAT ID, UK VAT registration number, GSTIN, ABN,
22
- * etc. See server/accounting/types.ts for the full doc. */
23
- taxRegistrationId?: string;
24
- }
25
- export interface JournalEntry {
26
- id: string;
27
- date: string;
28
- kind: JournalEntryKind;
29
- lines: JournalLine[];
30
- memo?: string;
31
- voidedEntryId?: string;
32
- voidReason?: string;
33
- /** Set on the new entry posted via the "edit" flow — id of the
34
- * original entry that was voided in the same operation. The
35
- * void + new-entry pair is two sequential calls on the client,
36
- * not an atomic transaction. */
37
- replacesEntryId?: string;
38
- createdAt: string;
39
- }
40
- export interface BookSummary {
41
- id: string;
42
- name: string;
43
- currency: string;
44
- /** ISO 3166-1 alpha-2 country code identifying the tax jurisdiction
45
- * the book is kept under. Constrained to `SupportedCountryCode` —
46
- * see `countries.ts`. Optional for backward compatibility with
47
- * books created before the field was introduced. */
48
- country?: SupportedCountryCode;
49
- /** Calendar month (1-12) on whose last day the book's fiscal year
50
- * closes — e.g. 8 = August 31, 12 = December 31. Optional in the
51
- * persisted shape for backward compatibility — read-side code
52
- * normalises absence (and the legacy "Q1".."Q4" tokens) to a
53
- * closing month via `resolveFiscalYearEnd`. See `fiscalYear.ts`. */
54
- fiscalYearEnd?: FiscalYearEnd;
55
- createdAt: string;
56
- }
2
+ import { type SupportedCountryCode, type FiscalYearEnd, type TimeSeriesGranularity, type TimeSeriesMetric, type Account, type AccountBalance, type AccountType, type BalanceSheet, type BalanceSheetSection, type BookSummary, type JournalEntry, type JournalEntryKind, type JournalLine, type Ledger, type LedgerRow, type ProfitLoss, type ReportPeriod } from "../shared";
3
+ export type { Account, AccountBalance, AccountType, BalanceSheet, BalanceSheetSection, BookSummary, JournalEntry, JournalEntryKind, JournalLine, Ledger, LedgerRow, ProfitLoss, ReportPeriod, };
57
4
  export interface OpenAppPayload {
58
5
  kind: "accounting-app";
59
6
  /** `null` when the workspace has zero books — the View renders the
@@ -61,72 +8,6 @@ export interface OpenAppPayload {
61
8
  bookId: string | null;
62
9
  initialTab?: string;
63
10
  }
64
- export interface AccountBalance {
65
- accountCode: string;
66
- netDebit: number;
67
- }
68
- export interface BalanceSheetSection {
69
- type: AccountType;
70
- rows: {
71
- accountCode: string;
72
- accountName: string;
73
- balance: number;
74
- }[];
75
- total: number;
76
- }
77
- export interface BalanceSheet {
78
- asOf: string;
79
- sections: BalanceSheetSection[];
80
- imbalance: number;
81
- }
82
- export interface ProfitLoss {
83
- from: string;
84
- to: string;
85
- income: {
86
- rows: {
87
- accountCode: string;
88
- accountName: string;
89
- amount: number;
90
- }[];
91
- total: number;
92
- };
93
- expense: {
94
- rows: {
95
- accountCode: string;
96
- accountName: string;
97
- amount: number;
98
- }[];
99
- total: number;
100
- };
101
- netIncome: number;
102
- }
103
- export interface LedgerRow {
104
- entryId: string;
105
- date: string;
106
- kind: JournalEntryKind;
107
- memo?: string;
108
- debit: number;
109
- credit: number;
110
- runningBalance: number;
111
- /** Counterparty tax-registration ID per source line. The Ledger
112
- * view shows it as its own column when the selected account is
113
- * in the input-tax band (14xx — see `isTaxAccountCode`). */
114
- taxRegistrationId?: string;
115
- }
116
- export interface Ledger {
117
- accountCode: string;
118
- accountName: string;
119
- rows: LedgerRow[];
120
- closingBalance: number;
121
- }
122
- export type ReportPeriod = {
123
- kind: "month";
124
- period: string;
125
- } | {
126
- kind: "range";
127
- from: string;
128
- to: string;
129
- };
130
11
  export declare function getBooks(): Promise<ApiResult<{
131
12
  books: BookSummary[];
132
13
  }>>;
@@ -1 +1 @@
1
- {"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/vue/api.ts"],"names":[],"mappings":"AAUA,OAAO,EAA0B,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AACvE,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,aAAa,EAClB,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,EACtB,MAAM,WAAW,CAAC;AAEnB,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,WAAW,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAC;AAClF,MAAM,MAAM,gBAAgB,GAAG,QAAQ,GAAG,SAAS,GAAG,MAAM,GAAG,aAAa,CAAC;AAE7E,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,WAAW,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;kCAE8B;IAC9B,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAED,MAAM,WAAW,WAAW;IAC1B,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;gEAE4D;IAC5D,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B;AAED,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,gBAAgB,CAAC;IACvB,KAAK,EAAE,WAAW,EA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