@mulmoclaude/accounting-plugin 2.1.0 → 2.2.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/README.md +37 -0
- package/dist/server/context.d.ts +45 -3
- package/dist/server/context.d.ts.map +1 -1
- package/dist/server/eventPublisher.d.ts +9 -4
- package/dist/server/eventPublisher.d.ts.map +1 -1
- package/dist/server/index.d.ts +1 -0
- package/dist/server/index.d.ts.map +1 -1
- package/dist/server/router.d.ts +27 -3
- package/dist/server/router.d.ts.map +1 -1
- package/dist/server/snapshotCache.d.ts +3 -3
- package/dist/server/snapshotCache.d.ts.map +1 -1
- package/dist/server.cjs +149 -80
- package/dist/server.cjs.map +1 -1
- package/dist/server.js +149 -80
- package/dist/server.js.map +1 -1
- package/dist/shared/api.d.ts +12 -0
- package/dist/shared/api.d.ts.map +1 -1
- package/dist/shared/channels.d.ts +22 -2
- package/dist/shared/channels.d.ts.map +1 -1
- package/dist/{shared-BZAAF-I4.js → shared-BccLo0Ux.js} +39 -5
- package/dist/shared-BccLo0Ux.js.map +1 -0
- package/dist/{shared-BpFVwa6Y.cjs → shared-Dgt-i23T.cjs} +50 -4
- package/dist/shared-Dgt-i23T.cjs.map +1 -0
- package/dist/shared.cjs +3 -1
- package/dist/shared.js +2 -2
- package/dist/style.css +19 -10
- package/dist/vue/View.vue.d.ts +5 -0
- package/dist/vue/View.vue.d.ts.map +1 -1
- package/dist/vue/api.d.ts +132 -100
- package/dist/vue/api.d.ts.map +1 -1
- package/dist/vue/components/AccountsModal.vue.d.ts.map +1 -1
- package/dist/vue/components/BalanceSheet.vue.d.ts.map +1 -1
- package/dist/vue/components/BookSettings.vue.d.ts.map +1 -1
- package/dist/vue/components/JournalEntryForm.vue.d.ts.map +1 -1
- package/dist/vue/components/JournalList.vue.d.ts.map +1 -1
- package/dist/vue/components/Ledger.vue.d.ts.map +1 -1
- package/dist/vue/components/NewBookForm.vue.d.ts.map +1 -1
- package/dist/vue/components/OpeningBalancesForm.vue.d.ts.map +1 -1
- package/dist/vue/components/ProfitLoss.vue.d.ts.map +1 -1
- package/dist/vue/hostContext.d.ts +15 -0
- package/dist/vue/hostContext.d.ts.map +1 -1
- package/dist/vue/useAccountingChannel.d.ts +13 -3
- package/dist/vue/useAccountingChannel.d.ts.map +1 -1
- package/dist/vue.cjs +227 -98
- package/dist/vue.cjs.map +1 -1
- package/dist/vue.js +228 -99
- package/dist/vue.js.map +1 -1
- package/package.json +2 -2
- package/dist/shared-BZAAF-I4.js.map +0 -1
- package/dist/shared-BpFVwa6Y.cjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"View.vue.d.ts","sourceRoot":"","sources":["../../src/vue/View.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"View.vue.d.ts","sourceRoot":"","sources":["../../src/vue/View.vue"],"names":[],"mappings":"AA4pBA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAkBhE,UAAU,oBAAoB;IAC5B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;2EAEuE;IACvE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;2DAEuD;IACvD,OAAO,CAAC,EAAE;QAAE,EAAE,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAC5B;;;iBAGa;IACb,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB;;;8DAG0D;IAC1D,WAAW,CAAC,EAAE;QAAE,EAAE,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CAC/B;AAED,KAAK,WAAW,GAAG;IAAE,cAAc,CAAC,EAAE,kBAAkB,CAAC,oBAAoB,EAAE,oBAAoB,CAAC,CAAA;CAAE,CAAC;AAw8BvG,QAAA,MAAM,YAAY,kSAEhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
package/dist/vue/api.d.ts
CHANGED
|
@@ -3,51 +3,18 @@ import { type SupportedCountryCode, type FiscalYearEnd, type TimeSeriesGranulari
|
|
|
3
3
|
export type { Account, AccountBalance, AccountType, BalanceSheet, BalanceSheetSection, BookSummary, JournalEntry, JournalEntryKind, JournalLine, Ledger, LedgerRow, ProfitLoss, ReportPeriod, };
|
|
4
4
|
export interface OpenAppPayload {
|
|
5
5
|
kind: "accounting-app";
|
|
6
|
+
/** The host's opaque project id for the root this book lives under,
|
|
7
|
+
* stamped by the server on an `openBook` result. `null` is the
|
|
8
|
+
* default root; the field is absent only on a host that declared no
|
|
9
|
+
* scoping. A host that renders cards from more than one project keys
|
|
10
|
+
* them by `(scope, bookId)` — a bookId is unique within a root and
|
|
11
|
+
* nowhere else. */
|
|
12
|
+
scope?: string | null;
|
|
6
13
|
/** `null` when the workspace has zero books — the View renders the
|
|
7
14
|
* empty state and prompts for book creation. */
|
|
8
15
|
bookId: string | null;
|
|
9
16
|
initialTab?: string | undefined;
|
|
10
17
|
}
|
|
11
|
-
export declare function getBooks(): Promise<ApiResult<{
|
|
12
|
-
books: BookSummary[];
|
|
13
|
-
}>>;
|
|
14
|
-
export declare function createBook(input: {
|
|
15
|
-
name: string;
|
|
16
|
-
currency?: string | undefined;
|
|
17
|
-
country?: SupportedCountryCode | undefined;
|
|
18
|
-
/** Closing month 1-12 — required at the form boundary, but the
|
|
19
|
-
* server silently defaults an absent value to 12 (December). */
|
|
20
|
-
fiscalYearEnd?: FiscalYearEnd | undefined;
|
|
21
|
-
}): Promise<ApiResult<{
|
|
22
|
-
book: BookSummary;
|
|
23
|
-
}>>;
|
|
24
|
-
export declare function updateBook(input: {
|
|
25
|
-
bookId: string;
|
|
26
|
-
name?: string | undefined;
|
|
27
|
-
/** Pass `""` to explicitly clear the country (server treats it as
|
|
28
|
-
* the "drop the field" sentinel). Any other value must be one of
|
|
29
|
-
* the curated `SupportedCountryCode`s. */
|
|
30
|
-
country?: SupportedCountryCode | "" | undefined;
|
|
31
|
-
/** Closing month 1-12 — pure metadata, only changes how the
|
|
32
|
-
* date-range shortcuts resolve. No "clear" path; absence leaves the
|
|
33
|
-
* existing value untouched. */
|
|
34
|
-
fiscalYearEnd?: FiscalYearEnd | undefined;
|
|
35
|
-
}): Promise<ApiResult<{
|
|
36
|
-
book: BookSummary;
|
|
37
|
-
}>>;
|
|
38
|
-
export declare function deleteBook(bookId: string): Promise<ApiResult<{
|
|
39
|
-
deletedBookId: string;
|
|
40
|
-
deletedBookName: string;
|
|
41
|
-
}>>;
|
|
42
|
-
export declare function getAccounts(bookId: string): Promise<ApiResult<{
|
|
43
|
-
bookId: string;
|
|
44
|
-
accounts: Account[];
|
|
45
|
-
}>>;
|
|
46
|
-
export declare function upsertAccount(account: Account, bookId: string): Promise<ApiResult<{
|
|
47
|
-
bookId: string;
|
|
48
|
-
account: Account;
|
|
49
|
-
accounts: Account[];
|
|
50
|
-
}>>;
|
|
51
18
|
export interface AddEntriesItemInput {
|
|
52
19
|
date: string;
|
|
53
20
|
lines: JournalLine[];
|
|
@@ -58,61 +25,6 @@ export interface AddEntriesItemInput {
|
|
|
58
25
|
* no atomic transaction. */
|
|
59
26
|
replacesEntryId?: string | undefined;
|
|
60
27
|
}
|
|
61
|
-
export declare function addEntries(input: {
|
|
62
|
-
bookId: string;
|
|
63
|
-
/** One or more entries to post. The server validates every entry
|
|
64
|
-
* before any write, so a single bad entry rejects the whole
|
|
65
|
-
* batch. Pass a single-element array to post just one entry. */
|
|
66
|
-
entries: AddEntriesItemInput[];
|
|
67
|
-
}): Promise<ApiResult<{
|
|
68
|
-
bookId: string;
|
|
69
|
-
entries: JournalEntry[];
|
|
70
|
-
}>>;
|
|
71
|
-
export declare function voidEntry(input: {
|
|
72
|
-
entryId: string;
|
|
73
|
-
reason?: string | undefined;
|
|
74
|
-
bookId: string;
|
|
75
|
-
}): Promise<ApiResult<{
|
|
76
|
-
bookId: string;
|
|
77
|
-
reverseEntry: JournalEntry;
|
|
78
|
-
markerEntry: JournalEntry;
|
|
79
|
-
}>>;
|
|
80
|
-
export declare function getJournalEntries(input: {
|
|
81
|
-
from?: string | undefined;
|
|
82
|
-
to?: string | undefined;
|
|
83
|
-
accountCode?: string | undefined;
|
|
84
|
-
bookId: string;
|
|
85
|
-
}): Promise<ApiResult<{
|
|
86
|
-
bookId: string;
|
|
87
|
-
entries: JournalEntry[];
|
|
88
|
-
voidedEntryIds: string[];
|
|
89
|
-
}>>;
|
|
90
|
-
export declare function getOpeningBalances(bookId: string): Promise<ApiResult<{
|
|
91
|
-
bookId: string;
|
|
92
|
-
opening: JournalEntry | null;
|
|
93
|
-
}>>;
|
|
94
|
-
export declare function setOpeningBalances(input: {
|
|
95
|
-
asOfDate: string;
|
|
96
|
-
lines: JournalLine[];
|
|
97
|
-
memo?: string | undefined;
|
|
98
|
-
bookId: string;
|
|
99
|
-
}): Promise<ApiResult<{
|
|
100
|
-
bookId: string;
|
|
101
|
-
openingEntry: JournalEntry;
|
|
102
|
-
replacedExisting: boolean;
|
|
103
|
-
}>>;
|
|
104
|
-
export declare function getBalanceSheet(period: ReportPeriod, bookId: string): Promise<ApiResult<{
|
|
105
|
-
bookId: string;
|
|
106
|
-
balanceSheet: BalanceSheet;
|
|
107
|
-
}>>;
|
|
108
|
-
export declare function getProfitLoss(period: ReportPeriod, bookId: string): Promise<ApiResult<{
|
|
109
|
-
bookId: string;
|
|
110
|
-
profitLoss: ProfitLoss;
|
|
111
|
-
}>>;
|
|
112
|
-
export declare function getLedger(accountCode: string, period: ReportPeriod | undefined, bookId: string): Promise<ApiResult<{
|
|
113
|
-
bookId: string;
|
|
114
|
-
ledger: Ledger;
|
|
115
|
-
}>>;
|
|
116
28
|
export interface TimeSeriesPoint {
|
|
117
29
|
label: string;
|
|
118
30
|
from: string;
|
|
@@ -142,9 +54,129 @@ export interface TimeSeriesResult {
|
|
|
142
54
|
accountCode?: string | undefined;
|
|
143
55
|
points: TimeSeriesPoint[];
|
|
144
56
|
}
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
bookId: string
|
|
148
|
-
|
|
149
|
-
|
|
57
|
+
/** Build an api client bound to ONE project scope. */
|
|
58
|
+
declare function makeApi(getScope: () => string | null): {
|
|
59
|
+
getBalanceSheet: (period: ReportPeriod, bookId: string) => Promise<ApiResult<{
|
|
60
|
+
bookId: string;
|
|
61
|
+
balanceSheet: BalanceSheet;
|
|
62
|
+
}>>;
|
|
63
|
+
getProfitLoss: (period: ReportPeriod, bookId: string) => Promise<ApiResult<{
|
|
64
|
+
bookId: string;
|
|
65
|
+
profitLoss: ProfitLoss;
|
|
66
|
+
}>>;
|
|
67
|
+
getLedger: (accountCode: string, period: ReportPeriod | undefined, bookId: string) => Promise<ApiResult<{
|
|
68
|
+
bookId: string;
|
|
69
|
+
ledger: Ledger;
|
|
70
|
+
}>>;
|
|
71
|
+
getTimeSeries: (input: TimeSeriesInput) => Promise<ApiResult<TimeSeriesResult>>;
|
|
72
|
+
rebuildSnapshots: (bookId: string) => Promise<ApiResult<{
|
|
73
|
+
bookId: string;
|
|
74
|
+
rebuilt: string[];
|
|
75
|
+
}>>;
|
|
76
|
+
addEntries: (input: {
|
|
77
|
+
bookId: string;
|
|
78
|
+
/** One or more entries to post. The server validates every entry
|
|
79
|
+
* before any write, so a single bad entry rejects the whole
|
|
80
|
+
* batch. Pass a single-element array to post just one entry. */
|
|
81
|
+
entries: AddEntriesItemInput[];
|
|
82
|
+
}) => Promise<ApiResult<{
|
|
83
|
+
bookId: string;
|
|
84
|
+
entries: JournalEntry[];
|
|
85
|
+
}>>;
|
|
86
|
+
voidEntry: (input: {
|
|
87
|
+
entryId: string;
|
|
88
|
+
reason?: string | undefined;
|
|
89
|
+
bookId: string;
|
|
90
|
+
}) => Promise<ApiResult<{
|
|
91
|
+
bookId: string;
|
|
92
|
+
reverseEntry: JournalEntry;
|
|
93
|
+
markerEntry: JournalEntry;
|
|
94
|
+
}>>;
|
|
95
|
+
getJournalEntries: (input: {
|
|
96
|
+
from?: string | undefined;
|
|
97
|
+
to?: string | undefined;
|
|
98
|
+
accountCode?: string | undefined;
|
|
99
|
+
bookId: string;
|
|
100
|
+
}) => Promise<ApiResult<{
|
|
101
|
+
bookId: string;
|
|
102
|
+
entries: JournalEntry[];
|
|
103
|
+
voidedEntryIds: string[];
|
|
104
|
+
}>>;
|
|
105
|
+
getOpeningBalances: (bookId: string) => Promise<ApiResult<{
|
|
106
|
+
bookId: string;
|
|
107
|
+
opening: JournalEntry | null;
|
|
108
|
+
}>>;
|
|
109
|
+
setOpeningBalances: (input: {
|
|
110
|
+
asOfDate: string;
|
|
111
|
+
lines: JournalLine[];
|
|
112
|
+
memo?: string | undefined;
|
|
113
|
+
bookId: string;
|
|
114
|
+
}) => Promise<ApiResult<{
|
|
115
|
+
bookId: string;
|
|
116
|
+
openingEntry: JournalEntry;
|
|
117
|
+
replacedExisting: boolean;
|
|
118
|
+
}>>;
|
|
119
|
+
getAccounts: (bookId: string) => Promise<ApiResult<{
|
|
120
|
+
bookId: string;
|
|
121
|
+
accounts: Account[];
|
|
122
|
+
}>>;
|
|
123
|
+
upsertAccount: (account: Account, bookId: string) => Promise<ApiResult<{
|
|
124
|
+
bookId: string;
|
|
125
|
+
account: Account;
|
|
126
|
+
accounts: Account[];
|
|
127
|
+
}>>;
|
|
128
|
+
getBooks: () => Promise<ApiResult<{
|
|
129
|
+
books: BookSummary[];
|
|
130
|
+
}>>;
|
|
131
|
+
createBook: (input: {
|
|
132
|
+
name: string;
|
|
133
|
+
currency?: string | undefined;
|
|
134
|
+
country?: SupportedCountryCode | undefined;
|
|
135
|
+
/** Closing month 1-12 — required at the form boundary, but the
|
|
136
|
+
* server silently defaults an absent value to 12 (December). */
|
|
137
|
+
fiscalYearEnd?: FiscalYearEnd | undefined;
|
|
138
|
+
}) => Promise<ApiResult<{
|
|
139
|
+
book: BookSummary;
|
|
140
|
+
}>>;
|
|
141
|
+
updateBook: (input: {
|
|
142
|
+
bookId: string;
|
|
143
|
+
name?: string | undefined;
|
|
144
|
+
/** Pass `""` to explicitly clear the country (server treats it as
|
|
145
|
+
* the "drop the field" sentinel). Any other value must be one of
|
|
146
|
+
* the curated `SupportedCountryCode`s. */
|
|
147
|
+
country?: SupportedCountryCode | "" | undefined;
|
|
148
|
+
/** Closing month 1-12 — pure metadata, only changes how the
|
|
149
|
+
* date-range shortcuts resolve. No "clear" path; absence leaves the
|
|
150
|
+
* existing value untouched. */
|
|
151
|
+
fiscalYearEnd?: FiscalYearEnd | undefined;
|
|
152
|
+
}) => Promise<ApiResult<{
|
|
153
|
+
book: BookSummary;
|
|
154
|
+
}>>;
|
|
155
|
+
deleteBook: (bookId: string) => Promise<ApiResult<{
|
|
156
|
+
deletedBookId: string;
|
|
157
|
+
deletedBookName: string;
|
|
158
|
+
}>>;
|
|
159
|
+
};
|
|
160
|
+
/** The full accounting client surface, bound to one project. */
|
|
161
|
+
export type AccountingApi = ReturnType<typeof makeApi>;
|
|
162
|
+
/** A client pinned to one project for good — `null` meaning the host's
|
|
163
|
+
* default root. Use it for anything whose project is decided once
|
|
164
|
+
* (a card, a panel); use the tree-injected client (`useAccountingApi`)
|
|
165
|
+
* inside components. */
|
|
166
|
+
export declare function createAccountingApi(scope: string | null): AccountingApi;
|
|
167
|
+
/** Bind a component tree to the project its surface belongs to.
|
|
168
|
+
*
|
|
169
|
+
* A card was opened against the project its server envelope named
|
|
170
|
+
* (`OpenAppPayload.scope`). If its requests kept resolving the host's
|
|
171
|
+
* CURRENT project instead, switching projects would silently repoint
|
|
172
|
+
* an already-open card's reads and writes at another project's books —
|
|
173
|
+
* same bookId, different company. Call this once in the mounted app's
|
|
174
|
+
* setup, passing a GETTER: the surface's own scope can change when it
|
|
175
|
+
* is retargeted at another card, and the tree must follow the card it
|
|
176
|
+
* is showing rather than the one it first showed. */
|
|
177
|
+
export declare function provideAccountingApi(getScope: () => string | null): AccountingApi;
|
|
178
|
+
/** The api client for the surrounding tree, falling back to the
|
|
179
|
+
* host-scoped one for a surface nobody bound (a single-root host's
|
|
180
|
+
* every surface). */
|
|
181
|
+
export declare function useAccountingApi(): AccountingApi;
|
|
150
182
|
//# sourceMappingURL=api.d.ts.map
|
package/dist/vue/api.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/vue/api.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/vue/api.ts"],"names":[],"mappings":"AAYA,OAAO,EAA4C,KAAK,SAAS,EAAE,MAAM,eAAe,CAAC;AACzF,OAAO,EAIL,KAAK,oBAAoB,EACzB,KAAK,aAAa,EAClB,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,EACrB,KAAK,OAAO,EACZ,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,YAAY,EACjB,KAAK,mBAAmB,EACxB,KAAK,WAAW,EAChB,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAChB,KAAK,MAAM,EACX,KAAK,SAAS,EACd,KAAK,UAAU,EACf,KAAK,YAAY,EAClB,MAAM,WAAW,CAAC;AAMnB,YAAY,EACV,OAAO,EACP,cAAc,EACd,WAAW,EACX,YAAY,EACZ,mBAAmB,EACnB,WAAW,EACX,YAAY,EACZ,gBAAgB,EAChB,WAAW,EACX,MAAM,EACN,SAAS,EACT,UAAU,EACV,YAAY,GACb,CAAC;AAEF,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,gBAAgB,CAAC;IACvB;;;;;wBAKoB;IACpB,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB;qDACiD;IACjD,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;IACtB,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACjC;AAOD,MAAM,WAAW,mBAAmB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,WAAW,EAAE,CAAC;IACrB,I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AE,IAAI,EAAE,WAAW,CAAA;KAAE,CAAC,CAAC;yBAIjB,MAAM,KAAG,OAAO,CAAC,SAAS,CAAC;QAAE,aAAa,EAAE,MAAM,CAAC;QAAC,eAAe,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;EAqH5G;AAED,gEAAgE;AAChE,MAAM,MAAM,aAAa,GAAG,UAAU,CAAC,OAAO,OAAO,CAAC,CAAC;AAEvD;;;yBAGyB;AACzB,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,GAAG,aAAa,CAEvE;AASD;;;;;;;;;sDASsD;AACtD,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,MAAM,MAAM,GAAG,IAAI,GAAG,aAAa,CAIjF;AAED;;sBAEsB;AACtB,wBAAgB,gBAAgB,IAAI,aAAa,CAEhD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AccountsModal.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/AccountsModal.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AccountsModal.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/AccountsModal.vue"],"names":[],"mappings":"AAoTA,OAAO,EAAoB,KAAK,OAAO,EAAoB,MAAM,QAAQ,CAAC;AAY1E,KAAK,WAAW,GAAG;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,OAAO,EAAE,CAAA;CAAE,CAAC;AA0hB3D,QAAA,MAAM,YAAY;;;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BalanceSheet.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/BalanceSheet.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BalanceSheet.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/BalanceSheet.vue"],"names":[],"mappings":"AAuNA,KAAK,WAAW,GAAG;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AAgYzE,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BookSettings.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/BookSettings.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"BookSettings.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/BookSettings.vue"],"names":[],"mappings":"AA6SA,OAAO,EAIL,KAAK,oBAAoB,EAIzB,KAAK,aAAa,EACnB,MAAM,cAAc,CAAC;AAMtB,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,oBAAoB,GAAG,SAAS,CAAC;IAC3C,aAAa,CAAC,EAAE,aAAa,GAAG,SAAS,CAAC;CAC3C,CAAC;AAkiBF,QAAA,MAAM,YAAY;;;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"JournalEntryForm.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/JournalEntryForm.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"JournalEntryForm.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/JournalEntryForm.vue"],"names":[],"mappings":"AAogBA,OAAO,EAAoB,KAAK,OAAO,EAAE,KAAK,YAAY,EAAoB,MAAM,QAAQ,CAAC;AAC7F,OAAO,EAAkE,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AASzH,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,oBAAoB,GAAG,SAAS,CAAC;IAC3C,WAAW,CAAC,EAAE,YAAY,GAAG,IAAI,GAAG,SAAS,CAAC;CAC/C,CAAC;AAkzBF,QAAA,MAAM,YAAY;;;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"JournalList.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/JournalList.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"JournalList.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/JournalList.vue"],"names":[],"mappings":"AA+iBA,OAAO,EAAoB,KAAK,OAAO,EAA8D,MAAM,QAAQ,CAAC;AACpH,OAAO,EAA8E,KAAK,aAAa,EAAE,KAAK,oBAAoB,EAAE,MAAM,cAAc,CAAC;AAUzJ,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,oBAAoB,GAAG,SAAS,CAAC;IAC3C,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,aAAa,GAAG,SAAS,CAAC;IAC1C;;qEAEiE;IACjE,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACjC;;;;mEAI+D;IAC/D,gBAAgB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACvC,CAAC;AAmgCF,QAAA,MAAM,YAAY;;;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Ledger.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/Ledger.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Ledger.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/Ledger.vue"],"names":[],"mappings":"AAoNA,OAAO,EAAoB,KAAK,OAAO,EAAkC,MAAM,QAAQ,CAAC;AACxF,OAAO,EAA0G,KAAK,aAAa,EAAE,MAAM,cAAc,CAAC;AAS1J,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,aAAa,GAAG,SAAS,CAAC;IAC1C;;qEAEiE;IACjE,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACjC;;yEAEqE;IACrE,oBAAoB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAC3C,CAAC;AAmZF,QAAA,MAAM,YAAY,kSAEhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NewBookForm.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/NewBookForm.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NewBookForm.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/NewBookForm.vue"],"names":[],"mappings":"AAmOA,OAAO,EAAoB,KAAK,WAAW,EAAE,MAAM,QAAQ,CAAC;AA6C5D,KAAK,WAAW,GAAG;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAkWJ,QAAA,MAAM,YAAY;;;;;;;cArWH,OAAO;gBACL,OAAO;cACT,OAAO;6EAuWpB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"OpeningBalancesForm.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/OpeningBalancesForm.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"OpeningBalancesForm.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/OpeningBalancesForm.vue"],"names":[],"mappings":"AAoSA,OAAO,EAAoB,KAAK,OAAO,EAAuC,MAAM,QAAQ,CAAC;AAU7F,KAAK,WAAW,GAAG;IAAE,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,OAAO,EAAE,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,CAAC;AA0gB9F,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProfitLoss.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/ProfitLoss.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ProfitLoss.vue.d.ts","sourceRoot":"","sources":["../../../src/vue/components/ProfitLoss.vue"],"names":[],"mappings":"AAuKA,OAAO,EAA0G,KAAK,aAAa,EAAE,MAAM,cAAc,CAAC;AAQ1J,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,aAAa,GAAG,SAAS,CAAC;IAC1C;;qEAEiE;IACjE,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAClC,CAAC;AAkYF,QAAA,MAAM,YAAY;;;;kFAGhB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -21,10 +21,21 @@ export type AccountingSubscribe = (channel: string, handler: (payload: unknown)
|
|
|
21
21
|
* reactively. The plugin owns a self-contained vue-i18n instance and mirrors
|
|
22
22
|
* this tag onto it, so it shares NO i18n resources with the host. */
|
|
23
23
|
export type AccountingLocaleTag = () => string;
|
|
24
|
+
/** Project seam — the host's OPAQUE id for the project (root) the
|
|
25
|
+
* mounted accounting surface belongs to, or `null` for the host's
|
|
26
|
+
* default root. A single-root host omits it entirely and every
|
|
27
|
+
* request and channel name stays exactly what it is today.
|
|
28
|
+
*
|
|
29
|
+
* It rides dispatch requests as `ACCOUNTING_PROJECT_FIELD` and
|
|
30
|
+
* namespaces the pub/sub channel names, so two projects that both hold
|
|
31
|
+
* a book called `main` neither read nor refresh each other. It must be
|
|
32
|
+
* an id the host can resolve, never a path — it reaches the browser. */
|
|
33
|
+
export type AccountingProjectScope = () => string | null;
|
|
24
34
|
export interface AccountingHostContext {
|
|
25
35
|
apiCall: AccountingApiCall;
|
|
26
36
|
subscribe: AccountingSubscribe;
|
|
27
37
|
localeTag: AccountingLocaleTag;
|
|
38
|
+
projectScope?: AccountingProjectScope;
|
|
28
39
|
}
|
|
29
40
|
/** Called once by the host before any accounting View mounts. */
|
|
30
41
|
export declare function configureAccountingHost(context: AccountingHostContext): void;
|
|
@@ -36,4 +47,8 @@ export declare function hostSubscribe(channel: string, handler: (payload: unknow
|
|
|
36
47
|
/** The host's active i18n locale tag, read reactively by the plugin's own
|
|
37
48
|
* vue-i18n instance (see `./lang`). */
|
|
38
49
|
export declare function hostLocaleTag(): string;
|
|
50
|
+
/** The host's opaque project id for the mounted surface, or `null` when
|
|
51
|
+
* the host serves a single root (MulmoClaude) or the surface belongs to
|
|
52
|
+
* its default one. */
|
|
53
|
+
export declare function hostProjectScope(): string | null;
|
|
39
54
|
//# sourceMappingURL=hostContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hostContext.d.ts","sourceRoot":"","sources":["../../src/vue/hostContext.ts"],"names":[],"mappings":"AAiBA;mEACmE;AACnE,MAAM,MAAM,SAAS,CAAC,CAAC,IAAI;IAAE,EAAE,EAAE,IAAI,CAAC;IAAC,IAAI,EAAE,CAAC,CAAA;CAAE,GAAG;IAAE,EAAE,EAAE,KAAK,CAAC;IAAC,KAAK,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
|
version: Ref<number>;
|
|
7
7
|
}
|
|
8
|
-
|
|
8
|
+
/** The project a subscription belongs to: a fixed value, a getter for
|
|
9
|
+
* one that can change (the selected card's), or omitted to follow
|
|
10
|
+
* whatever project the host currently considers active. */
|
|
11
|
+
export type AccountingChannelScope = string | null | (() => string | null);
|
|
12
|
+
/** `scope` binds the subscription to one project — pass the scope the
|
|
13
|
+
* surface was opened for. Omit it and the channel follows whatever
|
|
14
|
+
* project the host currently considers active, which is right for a
|
|
15
|
+
* surface the host itself scopes and always `null` on a single-root
|
|
16
|
+
* host. */
|
|
17
|
+
export declare function useAccountingChannel(bookId: Ref<string | null>, onPayload?: (payload: BookChannelPayload) => void, scope?: AccountingChannelScope): UseAccountingChannelReturn;
|
|
9
18
|
/** Subscribe to "the list of books changed" events. Use in
|
|
10
19
|
* BookSwitcher.vue to refetch the dropdown contents when a sibling
|
|
11
|
-
* tab adds / deletes a book.
|
|
12
|
-
|
|
20
|
+
* tab adds / deletes a book. Re-binds on a scope change, like
|
|
21
|
+
* `useAccountingChannel`. */
|
|
22
|
+
export declare function useAccountingBooksChannel(onChange: () => void, scope?: AccountingChannelScope): void;
|
|
13
23
|
//# sourceMappingURL=useAccountingChannel.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAccountingChannel.d.ts","sourceRoot":"","sources":["../../src/vue/useAccountingChannel.ts"],"names":[],"mappings":"AAmBA,OAAO,
|
|
1
|
+
{"version":3,"file":"useAccountingChannel.d.ts","sourceRoot":"","sources":["../../src/vue/useAccountingChannel.ts"],"names":[],"mappings":"AAmBA,OAAO,EAAqC,KAAK,GAAG,EAAE,MAAM,KAAK,CAAC;AAClE,OAAO,EAA+C,KAAK,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAejG,MAAM,WAAW,0BAA0B;IACzC;iCAC6B;IAC7B,OAAO,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC;CACtB;AAED;;4DAE4D;AAC5D,MAAM,MAAM,sBAAsB,GAAG,MAAM,GAAG,IAAI,GAAG,CAAC,MAAM,MAAM,GAAG,IAAI,CAAC,CAAC;AAU3E;;;;YAIY;AACZ,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,GAAG,CAAC,MAAM,GAAG,IAAI,CAAC,EAC1B,SAAS,CAAC,EAAE,CAAC,OAAO,EAAE,kBAAkB,KAAK,IAAI,EACjD,KAAK,CAAC,EAAE,sBAAsB,GAC7B,0BAA0B,CA8B5B;AAED;;;8BAG8B;AAC9B,wBAAgB,yBAAyB,CAAC,QAAQ,EAAE,MAAM,IAAI,EAAE,KAAK,CAAC,EAAE,sBAAsB,GAAG,IAAI,CAepG"}
|