document-model 1.0.13 → 1.0.14

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.
@@ -5,12 +5,17 @@ export interface ISignal<T extends string = string, I = unknown> {
5
5
  export type CreateChildDocumentInput = {
6
6
  id: string;
7
7
  documentType: string;
8
- initialState?: unknown;
8
+ document?: Document;
9
9
  };
10
10
  export type CreateChildDocumentSignal = ISignal<'CREATE_CHILD_DOCUMENT', CreateChildDocumentInput>;
11
11
  export type DeleteChildDocumentInput = {
12
12
  id: string;
13
13
  };
14
14
  export type DeleteChildDocumentSignal = ISignal<'DELETE_CHILD_DOCUMENT', DeleteChildDocumentInput>;
15
- export type Signal = CreateChildDocumentSignal | DeleteChildDocumentSignal;
15
+ export type CopyhildDocumentInput = {
16
+ id: string;
17
+ newId: string;
18
+ };
19
+ export type CopyChildDocumentSignal = ISignal<'COPY_CHILD_DOCUMENT', CopyhildDocumentInput>;
20
+ export type Signal = CreateChildDocumentSignal | DeleteChildDocumentSignal | CopyChildDocumentSignal;
16
21
  export type SignalDispatch = (signal: Signal) => void;
@@ -5,12 +5,17 @@ export interface ISignal<T extends string = string, I = unknown> {
5
5
  export type CreateChildDocumentInput = {
6
6
  id: string;
7
7
  documentType: string;
8
- initialState?: unknown;
8
+ document?: Document;
9
9
  };
10
10
  export type CreateChildDocumentSignal = ISignal<'CREATE_CHILD_DOCUMENT', CreateChildDocumentInput>;
11
11
  export type DeleteChildDocumentInput = {
12
12
  id: string;
13
13
  };
14
14
  export type DeleteChildDocumentSignal = ISignal<'DELETE_CHILD_DOCUMENT', DeleteChildDocumentInput>;
15
- export type Signal = CreateChildDocumentSignal | DeleteChildDocumentSignal;
15
+ export type CopyhildDocumentInput = {
16
+ id: string;
17
+ newId: string;
18
+ };
19
+ export type CopyChildDocumentSignal = ISignal<'COPY_CHILD_DOCUMENT', CopyhildDocumentInput>;
20
+ export type Signal = CreateChildDocumentSignal | DeleteChildDocumentSignal | CopyChildDocumentSignal;
16
21
  export type SignalDispatch = (signal: Signal) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "document-model",
3
- "version": "1.0.13",
3
+ "version": "1.0.14",
4
4
  "license": "AGPL-3.0-only",
5
5
  "private": false,
6
6
  "files": [