@powerhousedao/vetra 6.0.0-dev.252 → 6.0.0-dev.254
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/document-models/app-module/index.d.ts +3 -339
- package/dist/document-models/app-module/index.d.ts.map +1 -1
- package/dist/document-models/document-editor/index.d.ts +3 -315
- package/dist/document-models/document-editor/index.d.ts.map +1 -1
- package/dist/document-models/index.d.ts +5 -5
- package/dist/document-models/processor-module/index.d.ts +3 -347
- package/dist/document-models/processor-module/index.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/index.d.ts +3 -286
- package/dist/document-models/subgraph-module/index.d.ts.map +1 -1
- package/dist/document-models/vetra-package/index.d.ts +3 -376
- package/dist/document-models/vetra-package/index.d.ts.map +1 -1
- package/dist/index-BdmD5tsW.d.ts +393 -0
- package/dist/index-BdmD5tsW.d.ts.map +1 -0
- package/dist/index-BfK0fsx4.d.ts +424 -0
- package/dist/index-BfK0fsx4.d.ts.map +1 -0
- package/dist/index.d.ts +136 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/module-BYEvqA47.d.ts +357 -0
- package/dist/module-BYEvqA47.d.ts.map +1 -0
- package/dist/module-CCqD26Hf.d.ts +478 -0
- package/dist/module-CCqD26Hf.d.ts.map +1 -0
- package/dist/module-CpP8D2Hl.d.ts +437 -0
- package/dist/module-CpP8D2Hl.d.ts.map +1 -0
- package/package.json +8 -8
- package/dist/module-BoX1rWiq.d.ts +0 -6
- package/dist/module-BoX1rWiq.d.ts.map +0 -1
- package/dist/module-CG6K37P8.d.ts +0 -6
- package/dist/module-CG6K37P8.d.ts.map +0 -1
- package/dist/module-Cr-9knz_.d.ts +0 -6
- package/dist/module-Cr-9knz_.d.ts.map +0 -1
- package/dist/module-DhhQLYnQ.d.ts +0 -6
- package/dist/module-DhhQLYnQ.d.ts.map +0 -1
- package/dist/module-J-kGIl1E.d.ts +0 -6
- package/dist/module-J-kGIl1E.d.ts.map +0 -1
|
@@ -0,0 +1,393 @@
|
|
|
1
|
+
import * as document_model0 from "document-model";
|
|
2
|
+
import { Action, DocumentModelGlobalState, DocumentModelUtils, PHAuthState, PHBaseState, PHDocument, PHDocumentController, PHDocumentState, Reducer, SignalDispatch } from "document-model";
|
|
3
|
+
import * as z$1 from "zod";
|
|
4
|
+
import { z } from "zod";
|
|
5
|
+
import { DocumentDispatch } from "@powerhousedao/reactor-browser";
|
|
6
|
+
|
|
7
|
+
//#region document-models/document-editor/v1/actions.d.ts
|
|
8
|
+
/** Actions for the DocumentEditor document model */
|
|
9
|
+
declare const actions: {
|
|
10
|
+
setEditorName: (input: SetEditorNameInput) => SetEditorNameAction;
|
|
11
|
+
addDocumentType: (input: AddDocumentTypeInput) => AddDocumentTypeAction;
|
|
12
|
+
removeDocumentType: (input: RemoveDocumentTypeInput) => RemoveDocumentTypeAction;
|
|
13
|
+
setEditorStatus: (input: SetEditorStatusInput) => SetEditorStatusAction;
|
|
14
|
+
setName: (name: string | {
|
|
15
|
+
name: string;
|
|
16
|
+
}) => document_model0.SetNameAction;
|
|
17
|
+
setPreferredEditor: (input: string | null | {
|
|
18
|
+
preferredEditor: string | null;
|
|
19
|
+
}) => document_model0.SetPreferredEditorAction;
|
|
20
|
+
undo: (count?: number, scope?: string) => document_model0.UndoAction;
|
|
21
|
+
redo: (count?: number, scope?: string) => document_model0.RedoAction;
|
|
22
|
+
prune: (start?: number, end?: number, scope?: string) => document_model0.SchemaPruneAction;
|
|
23
|
+
loadState: <TState extends document_model0.PHBaseState = document_model0.PHBaseState>(state: TState & {
|
|
24
|
+
name: string;
|
|
25
|
+
}, operations: number) => document_model0.LoadStateAction;
|
|
26
|
+
noop: (scope?: string) => document_model0.NOOPAction;
|
|
27
|
+
};
|
|
28
|
+
//#endregion
|
|
29
|
+
//#region document-models/document-editor/v1/gen/schema/types.d.ts
|
|
30
|
+
type Maybe<T> = T | null | undefined;
|
|
31
|
+
type InputMaybe<T> = T | null | undefined;
|
|
32
|
+
type Exact<T extends {
|
|
33
|
+
[key: string]: unknown;
|
|
34
|
+
}> = { [K in keyof T]: T[K] };
|
|
35
|
+
type MakeOptional<T, K extends keyof T> = Omit<T, K> & { [SubKey in K]?: Maybe<T[SubKey]> };
|
|
36
|
+
type MakeMaybe<T, K extends keyof T> = Omit<T, K> & { [SubKey in K]: Maybe<T[SubKey]> };
|
|
37
|
+
type MakeEmpty<T extends {
|
|
38
|
+
[key: string]: unknown;
|
|
39
|
+
}, K extends keyof T> = { [_ in K]?: never };
|
|
40
|
+
type Incremental<T> = T | { [P in keyof T]?: P extends " $fragmentName" | "__typename" ? T[P] : never };
|
|
41
|
+
/** All built-in and custom scalars, mapped to their actual values */
|
|
42
|
+
type Scalars = {
|
|
43
|
+
ID: {
|
|
44
|
+
input: string;
|
|
45
|
+
output: string;
|
|
46
|
+
};
|
|
47
|
+
String: {
|
|
48
|
+
input: string;
|
|
49
|
+
output: string;
|
|
50
|
+
};
|
|
51
|
+
Boolean: {
|
|
52
|
+
input: boolean;
|
|
53
|
+
output: boolean;
|
|
54
|
+
};
|
|
55
|
+
Int: {
|
|
56
|
+
input: number;
|
|
57
|
+
output: number;
|
|
58
|
+
};
|
|
59
|
+
Float: {
|
|
60
|
+
input: number;
|
|
61
|
+
output: number;
|
|
62
|
+
};
|
|
63
|
+
Address: {
|
|
64
|
+
input: `${string}:0x${string}`;
|
|
65
|
+
output: `${string}:0x${string}`;
|
|
66
|
+
};
|
|
67
|
+
Amount: {
|
|
68
|
+
input: {
|
|
69
|
+
unit?: string;
|
|
70
|
+
value?: number;
|
|
71
|
+
};
|
|
72
|
+
output: {
|
|
73
|
+
unit?: string;
|
|
74
|
+
value?: number;
|
|
75
|
+
};
|
|
76
|
+
};
|
|
77
|
+
Amount_Crypto: {
|
|
78
|
+
input: {
|
|
79
|
+
unit: string;
|
|
80
|
+
value: string;
|
|
81
|
+
};
|
|
82
|
+
output: {
|
|
83
|
+
unit: string;
|
|
84
|
+
value: string;
|
|
85
|
+
};
|
|
86
|
+
};
|
|
87
|
+
Amount_Currency: {
|
|
88
|
+
input: {
|
|
89
|
+
unit: string;
|
|
90
|
+
value: string;
|
|
91
|
+
};
|
|
92
|
+
output: {
|
|
93
|
+
unit: string;
|
|
94
|
+
value: string;
|
|
95
|
+
};
|
|
96
|
+
};
|
|
97
|
+
Amount_Fiat: {
|
|
98
|
+
input: {
|
|
99
|
+
unit: string;
|
|
100
|
+
value: number;
|
|
101
|
+
};
|
|
102
|
+
output: {
|
|
103
|
+
unit: string;
|
|
104
|
+
value: number;
|
|
105
|
+
};
|
|
106
|
+
};
|
|
107
|
+
Amount_Money: {
|
|
108
|
+
input: number;
|
|
109
|
+
output: number;
|
|
110
|
+
};
|
|
111
|
+
Amount_Percentage: {
|
|
112
|
+
input: number;
|
|
113
|
+
output: number;
|
|
114
|
+
};
|
|
115
|
+
Amount_Tokens: {
|
|
116
|
+
input: number;
|
|
117
|
+
output: number;
|
|
118
|
+
};
|
|
119
|
+
Attachment: {
|
|
120
|
+
input: string;
|
|
121
|
+
output: string;
|
|
122
|
+
};
|
|
123
|
+
Currency: {
|
|
124
|
+
input: string;
|
|
125
|
+
output: string;
|
|
126
|
+
};
|
|
127
|
+
Date: {
|
|
128
|
+
input: string;
|
|
129
|
+
output: string;
|
|
130
|
+
};
|
|
131
|
+
DateTime: {
|
|
132
|
+
input: string;
|
|
133
|
+
output: string;
|
|
134
|
+
};
|
|
135
|
+
EmailAddress: {
|
|
136
|
+
input: string;
|
|
137
|
+
output: string;
|
|
138
|
+
};
|
|
139
|
+
EthereumAddress: {
|
|
140
|
+
input: string;
|
|
141
|
+
output: string;
|
|
142
|
+
};
|
|
143
|
+
OID: {
|
|
144
|
+
input: string;
|
|
145
|
+
output: string;
|
|
146
|
+
};
|
|
147
|
+
OLabel: {
|
|
148
|
+
input: string;
|
|
149
|
+
output: string;
|
|
150
|
+
};
|
|
151
|
+
PHID: {
|
|
152
|
+
input: string;
|
|
153
|
+
output: string;
|
|
154
|
+
};
|
|
155
|
+
URL: {
|
|
156
|
+
input: string;
|
|
157
|
+
output: string;
|
|
158
|
+
};
|
|
159
|
+
Unknown: {
|
|
160
|
+
input: unknown;
|
|
161
|
+
output: unknown;
|
|
162
|
+
};
|
|
163
|
+
Upload: {
|
|
164
|
+
input: File;
|
|
165
|
+
output: File;
|
|
166
|
+
};
|
|
167
|
+
};
|
|
168
|
+
type AddDocumentTypeInput = {
|
|
169
|
+
documentType: Scalars["String"]["input"];
|
|
170
|
+
id: Scalars["OID"]["input"];
|
|
171
|
+
};
|
|
172
|
+
/**
|
|
173
|
+
* Configuration for a document editor contributed by the package. The editor is
|
|
174
|
+
* registered against every document type listed in `documentTypes`; Connect picks
|
|
175
|
+
* the first matching editor when opening a document.
|
|
176
|
+
*/
|
|
177
|
+
type DocumentEditorState = {
|
|
178
|
+
/** Document types this editor can edit. Each entry has a stable id so it can be removed individually. */documentTypes: Array<DocumentTypeItem>; /** Display name of the editor. Also determines the generated folder name under `editors/`. */
|
|
179
|
+
name: Scalars["String"]["output"]; /** Lifecycle status. While DRAFT the editor definition is editable and codegen is skipped; switching to CONFIRMED triggers scaffold generation. */
|
|
180
|
+
status: StatusType;
|
|
181
|
+
};
|
|
182
|
+
/** A document type id (e.g. 'powerhouse/document-drive') attached to the editor with a stable entry id. */
|
|
183
|
+
type DocumentTypeItem = {
|
|
184
|
+
/** Document type id this editor handles (e.g. 'my-org/invoice'). */documentType: Scalars["String"]["output"]; /** Stable identifier for the entry; used to remove it. */
|
|
185
|
+
id: Scalars["OID"]["output"];
|
|
186
|
+
};
|
|
187
|
+
type RemoveDocumentTypeInput = {
|
|
188
|
+
id: Scalars["OID"]["input"];
|
|
189
|
+
};
|
|
190
|
+
type SetEditorNameInput = {
|
|
191
|
+
name: Scalars["String"]["input"];
|
|
192
|
+
};
|
|
193
|
+
type SetEditorStatusInput = {
|
|
194
|
+
status: StatusType;
|
|
195
|
+
};
|
|
196
|
+
/**
|
|
197
|
+
* Lifecycle status of a module definition.
|
|
198
|
+
* - DRAFT: still being edited; codegen does not run.
|
|
199
|
+
* - CONFIRMED: locked in; codegen produces the corresponding scaffold.
|
|
200
|
+
*/
|
|
201
|
+
type StatusType = "CONFIRMED" | "DRAFT";
|
|
202
|
+
//#endregion
|
|
203
|
+
//#region document-models/document-editor/v1/gen/types.d.ts
|
|
204
|
+
type DocumentEditorLocalState = Record<PropertyKey, never>;
|
|
205
|
+
type DocumentEditorPHState = PHBaseState & {
|
|
206
|
+
global: DocumentEditorState;
|
|
207
|
+
local: DocumentEditorLocalState;
|
|
208
|
+
};
|
|
209
|
+
type DocumentEditorDocument = PHDocument<DocumentEditorPHState>;
|
|
210
|
+
//#endregion
|
|
211
|
+
//#region document-models/document-editor/v1/gen/base-operations/actions.d.ts
|
|
212
|
+
type SetEditorNameAction = Action & {
|
|
213
|
+
type: "SET_EDITOR_NAME";
|
|
214
|
+
input: SetEditorNameInput;
|
|
215
|
+
};
|
|
216
|
+
type AddDocumentTypeAction = Action & {
|
|
217
|
+
type: "ADD_DOCUMENT_TYPE";
|
|
218
|
+
input: AddDocumentTypeInput;
|
|
219
|
+
};
|
|
220
|
+
type RemoveDocumentTypeAction = Action & {
|
|
221
|
+
type: "REMOVE_DOCUMENT_TYPE";
|
|
222
|
+
input: RemoveDocumentTypeInput;
|
|
223
|
+
};
|
|
224
|
+
type SetEditorStatusAction = Action & {
|
|
225
|
+
type: "SET_EDITOR_STATUS";
|
|
226
|
+
input: SetEditorStatusInput;
|
|
227
|
+
};
|
|
228
|
+
type DocumentEditorBaseOperationsAction = SetEditorNameAction | AddDocumentTypeAction | RemoveDocumentTypeAction | SetEditorStatusAction;
|
|
229
|
+
//#endregion
|
|
230
|
+
//#region document-models/document-editor/v1/gen/actions.d.ts
|
|
231
|
+
type DocumentEditorAction = DocumentEditorBaseOperationsAction;
|
|
232
|
+
//#endregion
|
|
233
|
+
//#region document-models/document-editor/v1/gen/base-operations/operations.d.ts
|
|
234
|
+
interface DocumentEditorBaseOperationsOperations {
|
|
235
|
+
setEditorNameOperation: (state: DocumentEditorState, action: SetEditorNameAction, dispatch?: SignalDispatch) => void;
|
|
236
|
+
addDocumentTypeOperation: (state: DocumentEditorState, action: AddDocumentTypeAction, dispatch?: SignalDispatch) => void;
|
|
237
|
+
removeDocumentTypeOperation: (state: DocumentEditorState, action: RemoveDocumentTypeAction, dispatch?: SignalDispatch) => void;
|
|
238
|
+
setEditorStatusOperation: (state: DocumentEditorState, action: SetEditorStatusAction, dispatch?: SignalDispatch) => void;
|
|
239
|
+
}
|
|
240
|
+
//#endregion
|
|
241
|
+
//#region document-models/document-editor/v1/gen/controller.d.ts
|
|
242
|
+
declare const DocumentEditorController: new (initialDocument?: document_model0.PHDocument<DocumentEditorPHState> | undefined) => PHDocumentController<DocumentEditorPHState> & document_model0.ActionMap<DocumentEditorBaseOperationsAction, PHDocumentController<DocumentEditorPHState>>;
|
|
243
|
+
declare namespace creators_d_exports {
|
|
244
|
+
export { addDocumentType, removeDocumentType, setEditorName, setEditorStatus };
|
|
245
|
+
}
|
|
246
|
+
declare const setEditorName: (input: SetEditorNameInput) => SetEditorNameAction;
|
|
247
|
+
declare const addDocumentType: (input: AddDocumentTypeInput) => AddDocumentTypeAction;
|
|
248
|
+
declare const removeDocumentType: (input: RemoveDocumentTypeInput) => RemoveDocumentTypeAction;
|
|
249
|
+
declare const setEditorStatus: (input: SetEditorStatusInput) => SetEditorStatusAction;
|
|
250
|
+
//#endregion
|
|
251
|
+
//#region document-models/document-editor/v1/gen/document-model.d.ts
|
|
252
|
+
declare const documentModel: DocumentModelGlobalState;
|
|
253
|
+
//#endregion
|
|
254
|
+
//#region document-models/document-editor/v1/gen/document-schema.d.ts
|
|
255
|
+
/** Schema for validating the header object of a DocumentEditor document */
|
|
256
|
+
declare const DocumentEditorDocumentHeaderSchema: z.ZodObject<{
|
|
257
|
+
id: z.ZodString;
|
|
258
|
+
name: z.ZodString;
|
|
259
|
+
createdAtUtcIso: z.ZodString;
|
|
260
|
+
lastModifiedAtUtcIso: z.ZodString;
|
|
261
|
+
documentType: z.ZodLiteral<"powerhouse/document-editor">;
|
|
262
|
+
}, z.core.$strip>;
|
|
263
|
+
/** Schema for validating the state object of a DocumentEditor document */
|
|
264
|
+
declare const DocumentEditorPHStateSchema: z.ZodObject<{
|
|
265
|
+
global: z.ZodObject<Required<{
|
|
266
|
+
documentTypes: z.ZodType<DocumentTypeItem[], unknown, z.core.$ZodTypeInternals<DocumentTypeItem[], unknown>>;
|
|
267
|
+
name: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
268
|
+
status: z.ZodType<StatusType, unknown, z.core.$ZodTypeInternals<StatusType, unknown>>;
|
|
269
|
+
}>, z.core.$strip>;
|
|
270
|
+
}, z.core.$strip>;
|
|
271
|
+
declare const DocumentEditorDocumentSchema: z.ZodObject<{
|
|
272
|
+
header: z.ZodObject<{
|
|
273
|
+
id: z.ZodString;
|
|
274
|
+
name: z.ZodString;
|
|
275
|
+
createdAtUtcIso: z.ZodString;
|
|
276
|
+
lastModifiedAtUtcIso: z.ZodString;
|
|
277
|
+
documentType: z.ZodLiteral<"powerhouse/document-editor">;
|
|
278
|
+
}, z.core.$strip>;
|
|
279
|
+
state: z.ZodObject<{
|
|
280
|
+
global: z.ZodObject<Required<{
|
|
281
|
+
documentTypes: z.ZodType<DocumentTypeItem[], unknown, z.core.$ZodTypeInternals<DocumentTypeItem[], unknown>>;
|
|
282
|
+
name: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
283
|
+
status: z.ZodType<StatusType, unknown, z.core.$ZodTypeInternals<StatusType, unknown>>;
|
|
284
|
+
}>, z.core.$strip>;
|
|
285
|
+
}, z.core.$strip>;
|
|
286
|
+
initialState: z.ZodObject<{
|
|
287
|
+
global: z.ZodObject<Required<{
|
|
288
|
+
documentTypes: z.ZodType<DocumentTypeItem[], unknown, z.core.$ZodTypeInternals<DocumentTypeItem[], unknown>>;
|
|
289
|
+
name: z.ZodType<string, unknown, z.core.$ZodTypeInternals<string, unknown>>;
|
|
290
|
+
status: z.ZodType<StatusType, unknown, z.core.$ZodTypeInternals<StatusType, unknown>>;
|
|
291
|
+
}>, z.core.$strip>;
|
|
292
|
+
}, z.core.$strip>;
|
|
293
|
+
}, z.core.$strip>;
|
|
294
|
+
/** Simple helper function to check if a state object is a DocumentEditor document state object */
|
|
295
|
+
declare function isDocumentEditorState(state: unknown): state is DocumentEditorPHState;
|
|
296
|
+
/** Simple helper function to assert that a document state object is a DocumentEditor document state object */
|
|
297
|
+
declare function assertIsDocumentEditorState(state: unknown): asserts state is DocumentEditorPHState;
|
|
298
|
+
/** Simple helper function to check if a document is a DocumentEditor document */
|
|
299
|
+
declare function isDocumentEditorDocument(document: unknown): document is DocumentEditorDocument;
|
|
300
|
+
/** Simple helper function to assert that a document is a DocumentEditor document */
|
|
301
|
+
declare function assertIsDocumentEditorDocument(document: unknown): asserts document is DocumentEditorDocument;
|
|
302
|
+
//#endregion
|
|
303
|
+
//#region document-models/document-editor/v1/gen/document-type.d.ts
|
|
304
|
+
/**
|
|
305
|
+
* WARNING: DO NOT EDIT
|
|
306
|
+
* This file is auto-generated and updated by codegen
|
|
307
|
+
*/
|
|
308
|
+
declare const documentEditorDocumentType = "powerhouse/document-editor";
|
|
309
|
+
//#endregion
|
|
310
|
+
//#region document-models/document-editor/v1/gen/ph-factories.d.ts
|
|
311
|
+
declare function defaultGlobalState(): DocumentEditorState;
|
|
312
|
+
declare function defaultLocalState(): DocumentEditorLocalState;
|
|
313
|
+
declare function defaultPHState(): DocumentEditorPHState;
|
|
314
|
+
declare function createState$1(baseState?: Partial<PHBaseState>, globalState?: Partial<DocumentEditorState>, localState?: Partial<DocumentEditorLocalState>): DocumentEditorPHState;
|
|
315
|
+
/**
|
|
316
|
+
* Creates a DocumentEditorDocument with custom global and local state
|
|
317
|
+
* This properly handles the PHBaseState requirements while allowing
|
|
318
|
+
* document-specific state to be set.
|
|
319
|
+
*/
|
|
320
|
+
declare function createDocumentEditorDocument(state?: Partial<{
|
|
321
|
+
auth?: Partial<PHAuthState>;
|
|
322
|
+
document?: Partial<PHDocumentState>;
|
|
323
|
+
global?: Partial<DocumentEditorState>;
|
|
324
|
+
local?: Partial<DocumentEditorLocalState>;
|
|
325
|
+
}>): DocumentEditorDocument;
|
|
326
|
+
//#endregion
|
|
327
|
+
//#region document-models/document-editor/v1/gen/reducer.d.ts
|
|
328
|
+
declare const reducer: Reducer<DocumentEditorPHState>;
|
|
329
|
+
//#endregion
|
|
330
|
+
//#region document-models/document-editor/v1/gen/schema/zod.d.ts
|
|
331
|
+
type Properties<T> = Required<{ [K in keyof T]: z$1.ZodType<T[K]> }>;
|
|
332
|
+
type definedNonNullAny = {};
|
|
333
|
+
declare const isDefinedNonNullAny: (v: any) => v is definedNonNullAny;
|
|
334
|
+
declare const definedNonNullAnySchema: z$1.ZodAny & z$1.ZodType<definedNonNullAny, any, z$1.core.$ZodTypeInternals<definedNonNullAny, any>>;
|
|
335
|
+
declare const StatusTypeSchema: z$1.ZodEnum<{
|
|
336
|
+
CONFIRMED: "CONFIRMED";
|
|
337
|
+
DRAFT: "DRAFT";
|
|
338
|
+
}>;
|
|
339
|
+
declare function AddDocumentTypeInputSchema(): z$1.ZodObject<Properties<AddDocumentTypeInput>>;
|
|
340
|
+
declare function DocumentEditorStateSchema(): z$1.ZodObject<Properties<DocumentEditorState>>;
|
|
341
|
+
declare function DocumentTypeItemSchema(): z$1.ZodObject<Properties<DocumentTypeItem>>;
|
|
342
|
+
declare function RemoveDocumentTypeInputSchema(): z$1.ZodObject<Properties<RemoveDocumentTypeInput>>;
|
|
343
|
+
declare function SetEditorNameInputSchema(): z$1.ZodObject<Properties<SetEditorNameInput>>;
|
|
344
|
+
declare function SetEditorStatusInputSchema(): z$1.ZodObject<Properties<SetEditorStatusInput>>;
|
|
345
|
+
//#endregion
|
|
346
|
+
//#region document-models/document-editor/v1/gen/utils.d.ts
|
|
347
|
+
declare const initialGlobalState: DocumentEditorState;
|
|
348
|
+
declare const initialLocalState: DocumentEditorLocalState;
|
|
349
|
+
//#endregion
|
|
350
|
+
//#region document-models/document-editor/v1/hooks.d.ts
|
|
351
|
+
/** Hook to get a DocumentEditor document by its id */
|
|
352
|
+
declare function useDocumentEditorDocumentById(documentId: string | null | undefined): [DocumentEditorDocument, DocumentDispatch<DocumentEditorAction>] | [undefined, undefined];
|
|
353
|
+
/** Hook to get the selected DocumentEditor document */
|
|
354
|
+
declare function useSelectedDocumentEditorDocument(): [DocumentEditorDocument, DocumentDispatch<DocumentEditorAction>];
|
|
355
|
+
/** Hook to get all DocumentEditor documents in the selected drive */
|
|
356
|
+
declare function useDocumentEditorDocumentsInSelectedDrive(): DocumentEditorDocument[] | undefined;
|
|
357
|
+
/** Hook to get all DocumentEditor documents in the selected folder */
|
|
358
|
+
declare function useDocumentEditorDocumentsInSelectedFolder(): DocumentEditorDocument[] | undefined;
|
|
359
|
+
//#endregion
|
|
360
|
+
//#region document-models/document-editor/v1/module.d.ts
|
|
361
|
+
/** Document model module for the DocumentEditor document type */
|
|
362
|
+
declare const DocumentEditor: {
|
|
363
|
+
readonly version: 1;
|
|
364
|
+
readonly reducer: document_model0.Reducer<DocumentEditorPHState>;
|
|
365
|
+
readonly actions: {
|
|
366
|
+
setEditorName: (input: SetEditorNameInput) => SetEditorNameAction;
|
|
367
|
+
addDocumentType: (input: AddDocumentTypeInput) => AddDocumentTypeAction;
|
|
368
|
+
removeDocumentType: (input: RemoveDocumentTypeInput) => RemoveDocumentTypeAction;
|
|
369
|
+
setEditorStatus: (input: SetEditorStatusInput) => SetEditorStatusAction;
|
|
370
|
+
setName: (name: string | {
|
|
371
|
+
name: string;
|
|
372
|
+
}) => document_model0.SetNameAction;
|
|
373
|
+
setPreferredEditor: (input: string | null | {
|
|
374
|
+
preferredEditor: string | null;
|
|
375
|
+
}) => document_model0.SetPreferredEditorAction;
|
|
376
|
+
undo: (count?: number, scope?: string) => document_model0.UndoAction;
|
|
377
|
+
redo: (count?: number, scope?: string) => document_model0.RedoAction;
|
|
378
|
+
prune: (start?: number, end?: number, scope?: string) => document_model0.SchemaPruneAction;
|
|
379
|
+
loadState: <TState extends document_model0.PHBaseState = document_model0.PHBaseState>(state: TState & {
|
|
380
|
+
name: string;
|
|
381
|
+
}, operations: number) => document_model0.LoadStateAction;
|
|
382
|
+
noop: (scope?: string) => document_model0.NOOPAction;
|
|
383
|
+
};
|
|
384
|
+
readonly utils: document_model0.DocumentModelUtils<DocumentEditorPHState>;
|
|
385
|
+
readonly documentModel: document_model0.DocumentModelPHState;
|
|
386
|
+
};
|
|
387
|
+
//#endregion
|
|
388
|
+
//#region document-models/document-editor/v1/utils.d.ts
|
|
389
|
+
/** Utils for the DocumentEditor document model */
|
|
390
|
+
declare const utils: DocumentModelUtils<DocumentEditorPHState>;
|
|
391
|
+
//#endregion
|
|
392
|
+
export { Incremental as $, isDocumentEditorDocument as A, DocumentEditorAction as B, defaultPHState as C, DocumentEditorPHStateSchema as D, DocumentEditorDocumentSchema as E, removeDocumentType as F, SetEditorStatusAction as G, DocumentEditorBaseOperationsAction as H, setEditorName as I, DocumentEditorPHState as J, DocumentEditorDocument as K, setEditorStatus as L, documentModel as M, addDocumentType as N, assertIsDocumentEditorDocument as O, creators_d_exports as P, Exact as Q, DocumentEditorController as R, defaultLocalState as S, DocumentEditorDocumentHeaderSchema as T, RemoveDocumentTypeAction as U, AddDocumentTypeAction as V, SetEditorNameAction as W, DocumentEditorState as X, AddDocumentTypeInput as Y, DocumentTypeItem as Z, isDefinedNonNullAny as _, useDocumentEditorDocumentsInSelectedFolder as a, RemoveDocumentTypeInput as at, createState$1 as b, initialLocalState as c, SetEditorStatusInput as ct, DocumentTypeItemSchema as d, InputMaybe as et, RemoveDocumentTypeInputSchema as f, definedNonNullAnySchema as g, StatusTypeSchema as h, useDocumentEditorDocumentsInSelectedDrive as i, Maybe as it, isDocumentEditorState as j, assertIsDocumentEditorState as k, AddDocumentTypeInputSchema as l, StatusType as lt, SetEditorStatusInputSchema as m, DocumentEditor as n, MakeMaybe as nt, useSelectedDocumentEditorDocument as o, Scalars as ot, SetEditorNameInputSchema as p, DocumentEditorLocalState as q, useDocumentEditorDocumentById as r, MakeOptional as rt, initialGlobalState as s, SetEditorNameInput as st, utils as t, MakeEmpty as tt, DocumentEditorStateSchema as u, actions as ut, reducer as v, documentEditorDocumentType as w, defaultGlobalState as x, createDocumentEditorDocument as y, DocumentEditorBaseOperationsOperations as z };
|
|
393
|
+
//# sourceMappingURL=index-BdmD5tsW.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-BdmD5tsW.d.ts","names":[],"sources":["../document-models/document-editor/v1/actions.ts","../document-models/document-editor/v1/gen/schema/types.ts","../document-models/document-editor/v1/gen/types.ts","../document-models/document-editor/v1/gen/base-operations/actions.ts","../document-models/document-editor/v1/gen/actions.ts","../document-models/document-editor/v1/gen/base-operations/operations.ts","../document-models/document-editor/v1/gen/controller.ts","../document-models/document-editor/v1/gen/base-operations/creators.ts","../document-models/document-editor/v1/gen/document-model.ts","../document-models/document-editor/v1/gen/document-schema.ts","../document-models/document-editor/v1/gen/document-type.ts","../document-models/document-editor/v1/gen/ph-factories.ts","../document-models/document-editor/v1/gen/reducer.ts","../document-models/document-editor/v1/gen/schema/zod.ts","../document-models/document-editor/v1/gen/utils.ts","../document-models/document-editor/v1/hooks.ts","../document-models/document-editor/v1/module.ts","../document-models/document-editor/v1/utils.ts"],"mappings":";;;;;;;;cASa,OAAA;kBAIuO,KAAA,EADnP,kBAAA,KAC4Q,mBAAA;oBAAoL,KAAA,EAApL,oBAAA,KAA+M,qBAAA;uBAA6L,KAAA,EAA7L,uBAAA,KAA2N,wBAAA;oBAAmM,KAAA,EAAnM,oBAAA,KAA8N,qBAAA;;;QAAA,eAAA,CAAA,aAAA;;;;yBAAs+U,KAAA,8BAAgB,UAAA;yBAA0C,KAAA,cAA1C,eAAA,CAA0D,UAAA;0BAA2C,GAAA,WAAc,KAAA,cAAzD,eAAA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