@powerhousedao/vetra 5.0.0 → 5.0.1-staging.10
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/actions.d.ts +18 -0
- package/dist/document-models/app-module/actions.d.ts.map +1 -0
- package/dist/document-models/app-module/actions.js +8 -0
- package/dist/document-models/app-module/gen/base-operations/creators.d.ts +2 -2
- package/dist/document-models/app-module/gen/base-operations/creators.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/base-operations/creators.js +6 -7
- package/dist/document-models/app-module/gen/creators.d.ts +2 -0
- package/dist/document-models/app-module/gen/creators.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/creators.js +2 -0
- package/dist/document-models/app-module/gen/dnd-operations/creators.d.ts +2 -2
- package/dist/document-models/app-module/gen/dnd-operations/creators.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/dnd-operations/creators.js +2 -3
- package/dist/document-models/app-module/gen/document-schema.d.ts +199 -0
- package/dist/document-models/app-module/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/app-module/gen/document-schema.js +33 -0
- package/dist/document-models/app-module/gen/document-type.d.ts +2 -0
- package/dist/document-models/app-module/gen/document-type.d.ts.map +1 -0
- package/dist/document-models/app-module/gen/document-type.js +1 -0
- package/dist/document-models/app-module/gen/index.d.ts +8 -1
- package/dist/document-models/app-module/gen/index.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/index.js +8 -1
- package/dist/document-models/app-module/gen/reducer.d.ts +1 -3
- package/dist/document-models/app-module/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/reducer.js +16 -16
- package/dist/document-models/app-module/gen/schema/index.d.ts +1 -1
- package/dist/document-models/app-module/gen/schema/index.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/schema/index.js +1 -1
- package/dist/document-models/app-module/gen/types.d.ts +1 -2
- package/dist/document-models/app-module/gen/types.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/types.js +0 -1
- package/dist/document-models/app-module/gen/utils.d.ts +5 -2
- package/dist/document-models/app-module/gen/utils.d.ts.map +1 -1
- package/dist/document-models/app-module/gen/utils.js +20 -3
- package/dist/document-models/app-module/hooks.d.ts +11 -0
- package/dist/document-models/app-module/hooks.d.ts.map +1 -0
- package/dist/document-models/app-module/hooks.js +26 -0
- package/dist/document-models/app-module/index.d.ts +5 -31
- package/dist/document-models/app-module/index.d.ts.map +1 -1
- package/dist/document-models/app-module/index.js +5 -18
- package/dist/document-models/app-module/module.d.ts +5 -0
- package/dist/document-models/app-module/module.d.ts.map +1 -0
- package/dist/document-models/app-module/module.js +10 -0
- package/dist/document-models/app-module/src/index.d.ts +2 -0
- package/dist/document-models/app-module/src/index.d.ts.map +1 -0
- package/dist/document-models/app-module/src/index.js +1 -0
- package/dist/document-models/app-module/src/reducers/base-operations.d.ts +2 -2
- package/dist/document-models/app-module/src/reducers/base-operations.d.ts.map +1 -1
- package/dist/document-models/app-module/src/reducers/base-operations.js +1 -1
- package/dist/document-models/app-module/src/reducers/dnd-operations.d.ts +2 -2
- package/dist/document-models/app-module/src/reducers/dnd-operations.d.ts.map +1 -1
- package/dist/document-models/app-module/src/reducers/dnd-operations.js +1 -1
- package/dist/document-models/app-module/src/tests/base-operations.test.js +32 -34
- package/dist/document-models/app-module/src/tests/dnd-operations.test.js +10 -13
- package/dist/document-models/app-module/src/tests/document-model.test.js +22 -21
- package/dist/document-models/app-module/utils.d.ts +14 -0
- package/dist/document-models/app-module/utils.d.ts.map +1 -0
- package/dist/document-models/app-module/utils.js +7 -0
- package/dist/document-models/document-editor/actions.d.ts +16 -0
- package/dist/document-models/document-editor/actions.d.ts.map +1 -0
- package/dist/document-models/document-editor/actions.js +4 -0
- package/dist/document-models/document-editor/gen/base-operations/creators.d.ts +2 -2
- package/dist/document-models/document-editor/gen/base-operations/creators.d.ts.map +1 -1
- package/dist/document-models/document-editor/gen/base-operations/creators.js +5 -6
- package/dist/document-models/document-editor/gen/creators.d.ts +1 -0
- package/dist/document-models/document-editor/gen/creators.d.ts.map +1 -1
- package/dist/document-models/document-editor/gen/creators.js +1 -0
- package/dist/document-models/document-editor/gen/document-schema.d.ts +180 -0
- package/dist/document-models/document-editor/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/document-editor/gen/document-schema.js +33 -0
- package/dist/document-models/document-editor/gen/document-type.d.ts +2 -0
- package/dist/document-models/document-editor/gen/document-type.d.ts.map +1 -0
- package/dist/document-models/document-editor/gen/document-type.js +1 -0
- package/dist/document-models/document-editor/gen/index.d.ts +7 -1
- package/dist/document-models/document-editor/gen/index.d.ts.map +1 -1
- package/dist/document-models/document-editor/gen/index.js +7 -1
- package/dist/document-models/document-editor/gen/reducer.d.ts +1 -3
- package/dist/document-models/document-editor/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/document-editor/gen/reducer.js +11 -11
- package/dist/document-models/document-editor/gen/schema/index.d.ts +1 -1
- package/dist/document-models/document-editor/gen/schema/index.d.ts.map +1 -1
- package/dist/document-models/document-editor/gen/schema/index.js +1 -1
- package/dist/document-models/document-editor/gen/types.d.ts +1 -2
- package/dist/document-models/document-editor/gen/types.d.ts.map +1 -1
- package/dist/document-models/document-editor/gen/types.js +0 -1
- package/dist/document-models/document-editor/gen/utils.d.ts +5 -2
- package/dist/document-models/document-editor/gen/utils.d.ts.map +1 -1
- package/dist/document-models/document-editor/gen/utils.js +20 -3
- package/dist/document-models/document-editor/hooks.d.ts +11 -0
- package/dist/document-models/document-editor/hooks.d.ts.map +1 -0
- package/dist/document-models/document-editor/hooks.js +26 -0
- package/dist/document-models/document-editor/index.d.ts +5 -29
- package/dist/document-models/document-editor/index.d.ts.map +1 -1
- package/dist/document-models/document-editor/index.js +5 -18
- package/dist/document-models/document-editor/module.d.ts +5 -0
- package/dist/document-models/document-editor/module.d.ts.map +1 -0
- package/dist/document-models/document-editor/module.js +10 -0
- package/dist/document-models/document-editor/src/index.d.ts +2 -0
- package/dist/document-models/document-editor/src/index.d.ts.map +1 -0
- package/dist/document-models/document-editor/src/index.js +1 -0
- package/dist/document-models/document-editor/src/reducers/base-operations.d.ts +2 -2
- package/dist/document-models/document-editor/src/reducers/base-operations.d.ts.map +1 -1
- package/dist/document-models/document-editor/src/reducers/base-operations.js +1 -1
- package/dist/document-models/document-editor/src/tests/base-operations.test.js +22 -24
- package/dist/document-models/document-editor/src/tests/document-model.test.js +24 -22
- package/dist/document-models/document-editor/utils.d.ts +14 -0
- package/dist/document-models/document-editor/utils.d.ts.map +1 -0
- package/dist/document-models/document-editor/utils.js +7 -0
- package/dist/document-models/document-models.d.ts +3 -0
- package/dist/document-models/document-models.d.ts.map +1 -0
- package/dist/document-models/document-models.js +12 -0
- package/dist/document-models/index.d.ts +9 -5
- package/dist/document-models/index.d.ts.map +1 -1
- package/dist/document-models/index.js +9 -5
- package/dist/document-models/processor-module/actions.d.ts +17 -0
- package/dist/document-models/processor-module/actions.d.ts.map +1 -0
- package/dist/document-models/processor-module/actions.js +4 -0
- package/dist/document-models/processor-module/gen/base-operations/creators.d.ts +2 -2
- package/dist/document-models/processor-module/gen/base-operations/creators.d.ts.map +1 -1
- package/dist/document-models/processor-module/gen/base-operations/creators.js +6 -7
- package/dist/document-models/processor-module/gen/creators.d.ts +1 -0
- package/dist/document-models/processor-module/gen/creators.d.ts.map +1 -1
- package/dist/document-models/processor-module/gen/creators.js +1 -0
- package/dist/document-models/processor-module/gen/document-schema.d.ts +199 -0
- package/dist/document-models/processor-module/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/processor-module/gen/document-schema.js +33 -0
- package/dist/document-models/processor-module/gen/document-type.d.ts +2 -0
- package/dist/document-models/processor-module/gen/document-type.d.ts.map +1 -0
- package/dist/document-models/processor-module/gen/document-type.js +1 -0
- package/dist/document-models/processor-module/gen/index.d.ts +7 -1
- package/dist/document-models/processor-module/gen/index.d.ts.map +1 -1
- package/dist/document-models/processor-module/gen/index.js +7 -1
- package/dist/document-models/processor-module/gen/reducer.d.ts +1 -3
- package/dist/document-models/processor-module/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/processor-module/gen/reducer.js +13 -13
- package/dist/document-models/processor-module/gen/schema/index.d.ts +1 -1
- package/dist/document-models/processor-module/gen/schema/index.d.ts.map +1 -1
- package/dist/document-models/processor-module/gen/schema/index.js +1 -1
- package/dist/document-models/processor-module/gen/types.d.ts +1 -2
- package/dist/document-models/processor-module/gen/types.d.ts.map +1 -1
- package/dist/document-models/processor-module/gen/types.js +0 -1
- package/dist/document-models/processor-module/gen/utils.d.ts +5 -2
- package/dist/document-models/processor-module/gen/utils.d.ts.map +1 -1
- package/dist/document-models/processor-module/gen/utils.js +20 -3
- package/dist/document-models/processor-module/hooks.d.ts +11 -0
- package/dist/document-models/processor-module/hooks.d.ts.map +1 -0
- package/dist/document-models/processor-module/hooks.js +26 -0
- package/dist/document-models/processor-module/index.d.ts +5 -30
- package/dist/document-models/processor-module/index.d.ts.map +1 -1
- package/dist/document-models/processor-module/index.js +5 -18
- package/dist/document-models/processor-module/module.d.ts +5 -0
- package/dist/document-models/processor-module/module.d.ts.map +1 -0
- package/dist/document-models/processor-module/module.js +10 -0
- package/dist/document-models/processor-module/src/index.d.ts +2 -0
- package/dist/document-models/processor-module/src/index.d.ts.map +1 -0
- package/dist/document-models/processor-module/src/index.js +1 -0
- package/dist/document-models/processor-module/src/reducers/base-operations.d.ts +2 -2
- package/dist/document-models/processor-module/src/reducers/base-operations.d.ts.map +1 -1
- package/dist/document-models/processor-module/src/reducers/base-operations.js +1 -1
- package/dist/document-models/processor-module/src/tests/base-operations.test.js +24 -26
- package/dist/document-models/processor-module/src/tests/document-model.test.js +26 -24
- package/dist/document-models/processor-module/utils.d.ts +14 -0
- package/dist/document-models/processor-module/utils.d.ts.map +1 -0
- package/dist/document-models/processor-module/utils.js +7 -0
- package/dist/document-models/subgraph-module/actions.d.ts +14 -0
- package/dist/document-models/subgraph-module/actions.d.ts.map +1 -0
- package/dist/document-models/subgraph-module/actions.js +4 -0
- package/dist/document-models/subgraph-module/gen/base-operations/creators.d.ts +2 -2
- package/dist/document-models/subgraph-module/gen/base-operations/creators.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/gen/base-operations/creators.js +3 -4
- package/dist/document-models/subgraph-module/gen/creators.d.ts +1 -0
- package/dist/document-models/subgraph-module/gen/creators.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/gen/creators.js +1 -0
- package/dist/document-models/subgraph-module/gen/document-schema.d.ts +161 -0
- package/dist/document-models/subgraph-module/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/subgraph-module/gen/document-schema.js +33 -0
- package/dist/document-models/subgraph-module/gen/document-type.d.ts +2 -0
- package/dist/document-models/subgraph-module/gen/document-type.d.ts.map +1 -0
- package/dist/document-models/subgraph-module/gen/document-type.js +1 -0
- package/dist/document-models/subgraph-module/gen/index.d.ts +7 -1
- package/dist/document-models/subgraph-module/gen/index.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/gen/index.js +7 -1
- package/dist/document-models/subgraph-module/gen/reducer.d.ts +1 -3
- package/dist/document-models/subgraph-module/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/gen/reducer.js +7 -7
- package/dist/document-models/subgraph-module/gen/schema/index.d.ts +1 -1
- package/dist/document-models/subgraph-module/gen/schema/index.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/gen/schema/index.js +1 -1
- package/dist/document-models/subgraph-module/gen/types.d.ts +1 -2
- package/dist/document-models/subgraph-module/gen/types.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/gen/types.js +0 -1
- package/dist/document-models/subgraph-module/gen/utils.d.ts +5 -2
- package/dist/document-models/subgraph-module/gen/utils.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/gen/utils.js +20 -3
- package/dist/document-models/subgraph-module/hooks.d.ts +11 -0
- package/dist/document-models/subgraph-module/hooks.d.ts.map +1 -0
- package/dist/document-models/subgraph-module/hooks.js +26 -0
- package/dist/document-models/subgraph-module/index.d.ts +5 -27
- package/dist/document-models/subgraph-module/index.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/index.js +5 -18
- package/dist/document-models/subgraph-module/module.d.ts +5 -0
- package/dist/document-models/subgraph-module/module.d.ts.map +1 -0
- package/dist/document-models/subgraph-module/module.js +10 -0
- package/dist/document-models/subgraph-module/src/index.d.ts +2 -0
- package/dist/document-models/subgraph-module/src/index.d.ts.map +1 -0
- package/dist/document-models/subgraph-module/src/index.js +1 -0
- package/dist/document-models/subgraph-module/src/reducers/base-operations.d.ts +2 -2
- package/dist/document-models/subgraph-module/src/reducers/base-operations.d.ts.map +1 -1
- package/dist/document-models/subgraph-module/src/reducers/base-operations.js +1 -1
- package/dist/document-models/subgraph-module/src/tests/base-operations.test.js +7 -9
- package/dist/document-models/subgraph-module/src/tests/document-model.test.js +9 -7
- package/dist/document-models/subgraph-module/utils.d.ts +14 -0
- package/dist/document-models/subgraph-module/utils.d.ts.map +1 -0
- package/dist/document-models/subgraph-module/utils.js +7 -0
- package/dist/document-models/vetra-package/actions.d.ts +22 -0
- package/dist/document-models/vetra-package/actions.d.ts.map +1 -0
- package/dist/document-models/vetra-package/actions.js +4 -0
- package/dist/document-models/vetra-package/gen/base-operations/creators.d.ts +2 -2
- package/dist/document-models/vetra-package/gen/base-operations/creators.d.ts.map +1 -1
- package/dist/document-models/vetra-package/gen/base-operations/creators.js +11 -12
- package/dist/document-models/vetra-package/gen/creators.d.ts +1 -0
- package/dist/document-models/vetra-package/gen/creators.d.ts.map +1 -1
- package/dist/document-models/vetra-package/gen/creators.js +1 -0
- package/dist/document-models/vetra-package/gen/document-schema.d.ts +256 -0
- package/dist/document-models/vetra-package/gen/document-schema.d.ts.map +1 -0
- package/dist/document-models/vetra-package/gen/document-schema.js +33 -0
- package/dist/document-models/vetra-package/gen/document-type.d.ts +2 -0
- package/dist/document-models/vetra-package/gen/document-type.d.ts.map +1 -0
- package/dist/document-models/vetra-package/gen/document-type.js +1 -0
- package/dist/document-models/vetra-package/gen/index.d.ts +7 -1
- package/dist/document-models/vetra-package/gen/index.d.ts.map +1 -1
- package/dist/document-models/vetra-package/gen/index.js +7 -1
- package/dist/document-models/vetra-package/gen/reducer.d.ts +1 -3
- package/dist/document-models/vetra-package/gen/reducer.d.ts.map +1 -1
- package/dist/document-models/vetra-package/gen/reducer.js +23 -23
- package/dist/document-models/vetra-package/gen/schema/index.d.ts +1 -1
- package/dist/document-models/vetra-package/gen/schema/index.d.ts.map +1 -1
- package/dist/document-models/vetra-package/gen/schema/index.js +1 -1
- package/dist/document-models/vetra-package/gen/types.d.ts +1 -2
- package/dist/document-models/vetra-package/gen/types.d.ts.map +1 -1
- package/dist/document-models/vetra-package/gen/types.js +0 -1
- package/dist/document-models/vetra-package/gen/utils.d.ts +5 -2
- package/dist/document-models/vetra-package/gen/utils.d.ts.map +1 -1
- package/dist/document-models/vetra-package/gen/utils.js +20 -3
- package/dist/document-models/vetra-package/hooks.d.ts +11 -0
- package/dist/document-models/vetra-package/hooks.d.ts.map +1 -0
- package/dist/document-models/vetra-package/hooks.js +26 -0
- package/dist/document-models/vetra-package/index.d.ts +5 -35
- package/dist/document-models/vetra-package/index.d.ts.map +1 -1
- package/dist/document-models/vetra-package/index.js +5 -18
- package/dist/document-models/vetra-package/module.d.ts +5 -0
- package/dist/document-models/vetra-package/module.d.ts.map +1 -0
- package/dist/document-models/vetra-package/module.js +10 -0
- package/dist/document-models/vetra-package/src/index.d.ts +2 -0
- package/dist/document-models/vetra-package/src/index.d.ts.map +1 -0
- package/dist/document-models/vetra-package/src/index.js +1 -0
- package/dist/document-models/vetra-package/src/reducers/base-operations.d.ts +2 -2
- package/dist/document-models/vetra-package/src/reducers/base-operations.d.ts.map +1 -1
- package/dist/document-models/vetra-package/src/reducers/base-operations.js +1 -1
- package/dist/document-models/vetra-package/src/tests/base-operations.test.js +1 -1
- package/dist/document-models/vetra-package/src/tests/document-model.test.js +27 -25
- package/dist/document-models/vetra-package/utils.d.ts +14 -0
- package/dist/document-models/vetra-package/utils.d.ts.map +1 -0
- package/dist/document-models/vetra-package/utils.js +7 -0
- package/dist/editors/app-editor/components/AppEditorForm.d.ts.map +1 -1
- package/dist/editors/app-editor/components/AppEditorForm.js +4 -3
- package/dist/editors/app-editor/components/EditName.d.ts +3 -0
- package/dist/editors/app-editor/components/EditName.d.ts.map +1 -0
- package/dist/editors/app-editor/components/EditName.js +31 -0
- package/dist/editors/app-editor/editor.d.ts +1 -1
- package/dist/editors/app-editor/editor.d.ts.map +1 -1
- package/dist/editors/app-editor/editor.js +2 -2
- package/dist/editors/app-editor/editor.test.js +1 -1
- package/dist/editors/app-editor/module.d.ts +4 -0
- package/dist/editors/app-editor/module.d.ts.map +1 -0
- package/dist/editors/app-editor/module.js +10 -0
- package/dist/editors/document-editor/editor.d.ts +1 -1
- package/dist/editors/document-editor/editor.d.ts.map +1 -1
- package/dist/editors/document-editor/editor.js +2 -2
- package/dist/editors/document-editor/editor.test.js +1 -1
- package/dist/editors/document-editor/module.d.ts +3 -0
- package/dist/editors/document-editor/module.d.ts.map +1 -0
- package/dist/editors/document-editor/{index.js → module.js} +3 -4
- package/dist/editors/editors.d.ts +3 -0
- package/dist/editors/editors.d.ts.map +1 -0
- package/dist/editors/editors.js +14 -0
- package/dist/editors/hooks/useVetraDocument.d.ts +9 -9
- package/dist/editors/hooks/useVetraDocument.d.ts.map +1 -1
- package/dist/editors/index.d.ts +6 -6
- package/dist/editors/index.d.ts.map +1 -1
- package/dist/editors/index.js +6 -6
- package/dist/editors/processor-editor/editor.d.ts +1 -1
- package/dist/editors/processor-editor/editor.d.ts.map +1 -1
- package/dist/editors/processor-editor/editor.js +2 -2
- package/dist/editors/processor-editor/editor.test.js +1 -1
- package/dist/editors/processor-editor/module.d.ts +3 -0
- package/dist/editors/processor-editor/module.d.ts.map +1 -0
- package/dist/editors/processor-editor/{index.js → module.js} +3 -4
- package/dist/editors/subgraph-editor/editor.d.ts +1 -1
- package/dist/editors/subgraph-editor/editor.d.ts.map +1 -1
- package/dist/editors/subgraph-editor/editor.js +2 -2
- package/dist/editors/subgraph-editor/editor.test.js +1 -1
- package/dist/editors/subgraph-editor/module.d.ts +3 -0
- package/dist/editors/subgraph-editor/module.d.ts.map +1 -0
- package/dist/editors/subgraph-editor/{index.js → module.js} +3 -4
- package/dist/editors/vetra-drive-app/components/EditorContainer.js +1 -1
- package/dist/editors/vetra-drive-app/components/ModuleItem.d.ts.map +1 -1
- package/dist/editors/vetra-drive-app/components/ModuleItem.js +2 -1
- package/dist/editors/vetra-drive-app/editor.d.ts +1 -1
- package/dist/editors/vetra-drive-app/editor.d.ts.map +1 -1
- package/dist/editors/vetra-drive-app/editor.js +3 -6
- package/dist/editors/vetra-drive-app/module.d.ts +3 -0
- package/dist/editors/vetra-drive-app/module.d.ts.map +1 -0
- package/dist/editors/vetra-drive-app/{index.js → module.js} +3 -4
- package/dist/editors/vetra-package/editor.d.ts +1 -1
- package/dist/editors/vetra-package/editor.d.ts.map +1 -1
- package/dist/editors/vetra-package/editor.js +2 -2
- package/dist/editors/vetra-package/editor.test.js +1 -1
- package/dist/editors/vetra-package/module.d.ts +4 -0
- package/dist/editors/vetra-package/module.d.ts.map +1 -0
- package/dist/editors/vetra-package/module.js +10 -0
- package/dist/index.d.ts +3 -9
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -5
- package/dist/processors/codegen/document-handlers/document-codegen-manager.js +1 -1
- package/dist/processors/codegen/document-handlers/generators/app-generator.d.ts.map +1 -1
- package/dist/processors/codegen/document-handlers/generators/app-generator.js +3 -0
- package/dist/processors/codegen/document-handlers/generators/document-editor-generator.d.ts.map +1 -1
- package/dist/processors/codegen/document-handlers/generators/document-editor-generator.js +3 -0
- package/dist/processors/codegen/document-handlers/generators/document-model-generator.d.ts.map +1 -1
- package/dist/processors/codegen/document-handlers/generators/document-model-generator.js +4 -0
- package/dist/processors/codegen/document-handlers/generators/package-generator.d.ts.map +1 -1
- package/dist/processors/codegen/document-handlers/generators/package-generator.js +3 -0
- package/dist/processors/codegen/document-handlers/generators/processor-generator.d.ts.map +1 -1
- package/dist/processors/codegen/document-handlers/generators/processor-generator.js +3 -0
- package/dist/processors/codegen/document-handlers/generators/subgraph-generator.d.ts.map +1 -1
- package/dist/processors/codegen/document-handlers/generators/subgraph-generator.js +3 -0
- package/dist/processors/codegen/document-handlers/generators/utils.d.ts +13 -0
- package/dist/processors/codegen/document-handlers/generators/utils.d.ts.map +1 -0
- package/dist/processors/codegen/document-handlers/generators/utils.js +29 -0
- package/dist/processors/vetra-read-model/migrations.d.ts.map +1 -1
- package/dist/processors/vetra-read-model/migrations.js +0 -1
- package/dist/style.css +5 -1
- package/dist/subgraphs/vetra-package/schema.d.ts.map +1 -1
- package/dist/subgraphs/vetra-package/schema.js +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/vite.config.d.ts.map +1 -1
- package/dist/vite.config.js +11 -1
- package/package.json +25 -18
- package/dist/editors/app-editor/index.d.ts +0 -4
- package/dist/editors/app-editor/index.d.ts.map +0 -1
- package/dist/editors/app-editor/index.js +0 -10
- package/dist/editors/document-editor/index.d.ts +0 -4
- package/dist/editors/document-editor/index.d.ts.map +0 -1
- package/dist/editors/processor-editor/index.d.ts +0 -4
- package/dist/editors/processor-editor/index.d.ts.map +0 -1
- package/dist/editors/subgraph-editor/index.d.ts +0 -4
- package/dist/editors/subgraph-editor/index.d.ts.map +0 -1
- package/dist/editors/vetra-drive-app/index.d.ts +0 -4
- package/dist/editors/vetra-drive-app/index.d.ts.map +0 -1
- package/dist/editors/vetra-package/index.d.ts +0 -5
- package/dist/editors/vetra-package/index.d.ts.map +0 -1
- package/dist/editors/vetra-package/index.js +0 -10
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import type { ProcessorModuleBaseOperationsOperations } from "
|
|
2
|
-
export declare const
|
|
1
|
+
import type { ProcessorModuleBaseOperationsOperations } from "@powerhousedao/vetra/document-models/processor-module";
|
|
2
|
+
export declare const processorModuleBaseOperationsOperations: ProcessorModuleBaseOperationsOperations;
|
|
3
3
|
//# sourceMappingURL=base-operations.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-operations.d.ts","sourceRoot":"","sources":["../../../../../document-models/processor-module/src/reducers/base-operations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uCAAuC,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"base-operations.d.ts","sourceRoot":"","sources":["../../../../../document-models/processor-module/src/reducers/base-operations.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uCAAuC,EAAE,MAAM,uDAAuD,CAAC;AAErH,eAAO,MAAM,uCAAuC,EAAE,uCAwCnD,CAAC"}
|
|
@@ -2,10 +2,8 @@
|
|
|
2
2
|
* This is a scaffold file meant for customization:
|
|
3
3
|
* - change it by adding new tests or modifying the existing ones
|
|
4
4
|
*/
|
|
5
|
+
import { addDocumentType, reducer, removeDocumentType, setProcessorName, setProcessorStatus, setProcessorType, utils, } from "@powerhousedao/vetra/document-models/processor-module";
|
|
5
6
|
import { beforeEach, describe, expect, it } from "vitest";
|
|
6
|
-
import * as creators from "../../gen/base-operations/creators.js";
|
|
7
|
-
import { reducer } from "../../gen/reducer.js";
|
|
8
|
-
import utils from "../../gen/utils.js";
|
|
9
7
|
describe("BaseOperations Operations", () => {
|
|
10
8
|
let document;
|
|
11
9
|
beforeEach(() => {
|
|
@@ -14,12 +12,12 @@ describe("BaseOperations Operations", () => {
|
|
|
14
12
|
describe("setProcessorName", () => {
|
|
15
13
|
it("should mutate state with new name", () => {
|
|
16
14
|
const input = { name: "My Processor" };
|
|
17
|
-
const updatedDocument = reducer(document,
|
|
15
|
+
const updatedDocument = reducer(document, setProcessorName(input));
|
|
18
16
|
expect(updatedDocument.state.global.name).toBe("My Processor");
|
|
19
17
|
});
|
|
20
18
|
it("should reject empty string and store error in operation", () => {
|
|
21
19
|
const input = { name: "" };
|
|
22
|
-
const updatedDocument = reducer(document,
|
|
20
|
+
const updatedDocument = reducer(document, setProcessorName(input));
|
|
23
21
|
expect(updatedDocument.operations.global).toHaveLength(1);
|
|
24
22
|
expect(updatedDocument.operations.global[0].error).toBe("Processor name cannot be empty");
|
|
25
23
|
expect(updatedDocument.state.global.name).toBe("");
|
|
@@ -28,12 +26,12 @@ describe("BaseOperations Operations", () => {
|
|
|
28
26
|
describe("setProcessorType", () => {
|
|
29
27
|
it("should mutate state with new type", () => {
|
|
30
28
|
const input = { type: "analytics" };
|
|
31
|
-
const updatedDocument = reducer(document,
|
|
29
|
+
const updatedDocument = reducer(document, setProcessorType(input));
|
|
32
30
|
expect(updatedDocument.state.global.type).toBe("analytics");
|
|
33
31
|
});
|
|
34
32
|
it("should reject empty string and store error in operation", () => {
|
|
35
33
|
const input = { type: "" };
|
|
36
|
-
const updatedDocument = reducer(document,
|
|
34
|
+
const updatedDocument = reducer(document, setProcessorType(input));
|
|
37
35
|
expect(updatedDocument.operations.global).toHaveLength(1);
|
|
38
36
|
expect(updatedDocument.operations.global[0].error).toBe("Processor type cannot be empty");
|
|
39
37
|
expect(updatedDocument.state.global.type).toBe("");
|
|
@@ -42,17 +40,17 @@ describe("BaseOperations Operations", () => {
|
|
|
42
40
|
describe("setProcessorStatus", () => {
|
|
43
41
|
it("should mutate state with new status", () => {
|
|
44
42
|
const input = { status: "CONFIRMED" };
|
|
45
|
-
const updatedDocument = reducer(document,
|
|
43
|
+
const updatedDocument = reducer(document, setProcessorStatus(input));
|
|
46
44
|
expect(updatedDocument.state.global.status).toBe("CONFIRMED");
|
|
47
45
|
});
|
|
48
46
|
it("should transition from DRAFT to CONFIRMED", () => {
|
|
49
47
|
expect(document.state.global.status).toBe("DRAFT");
|
|
50
|
-
const updatedDocument = reducer(document,
|
|
48
|
+
const updatedDocument = reducer(document, setProcessorStatus({ status: "CONFIRMED" }));
|
|
51
49
|
expect(updatedDocument.state.global.status).toBe("CONFIRMED");
|
|
52
50
|
});
|
|
53
51
|
it("should transition from CONFIRMED to DRAFT", () => {
|
|
54
|
-
const confirmedDoc = reducer(document,
|
|
55
|
-
const updatedDocument = reducer(confirmedDoc,
|
|
52
|
+
const confirmedDoc = reducer(document, setProcessorStatus({ status: "CONFIRMED" }));
|
|
53
|
+
const updatedDocument = reducer(confirmedDoc, setProcessorStatus({ status: "DRAFT" }));
|
|
56
54
|
expect(updatedDocument.state.global.status).toBe("DRAFT");
|
|
57
55
|
});
|
|
58
56
|
});
|
|
@@ -62,7 +60,7 @@ describe("BaseOperations Operations", () => {
|
|
|
62
60
|
id: "test-type-1",
|
|
63
61
|
documentType: "powerhouse/test",
|
|
64
62
|
};
|
|
65
|
-
const updatedDocument = reducer(document,
|
|
63
|
+
const updatedDocument = reducer(document, addDocumentType(input));
|
|
66
64
|
expect(updatedDocument.state.global.documentTypes).toContainEqual({
|
|
67
65
|
id: "test-type-1",
|
|
68
66
|
documentType: "powerhouse/test",
|
|
@@ -74,21 +72,21 @@ describe("BaseOperations Operations", () => {
|
|
|
74
72
|
id: "first-type",
|
|
75
73
|
documentType: "powerhouse/first",
|
|
76
74
|
};
|
|
77
|
-
const updatedDocument = reducer(document,
|
|
75
|
+
const updatedDocument = reducer(document, addDocumentType(input));
|
|
78
76
|
expect(updatedDocument.state.global.documentTypes).toEqual([
|
|
79
77
|
{ id: "first-type", documentType: "powerhouse/first" },
|
|
80
78
|
]);
|
|
81
79
|
});
|
|
82
80
|
it("should add multiple document types sequentially", () => {
|
|
83
|
-
let updatedDoc = reducer(document,
|
|
81
|
+
let updatedDoc = reducer(document, addDocumentType({
|
|
84
82
|
id: "type-1",
|
|
85
83
|
documentType: "powerhouse/a",
|
|
86
84
|
}));
|
|
87
|
-
updatedDoc = reducer(updatedDoc,
|
|
85
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
88
86
|
id: "type-2",
|
|
89
87
|
documentType: "powerhouse/b",
|
|
90
88
|
}));
|
|
91
|
-
updatedDoc = reducer(updatedDoc,
|
|
89
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
92
90
|
id: "type-3",
|
|
93
91
|
documentType: "powerhouse/c",
|
|
94
92
|
}));
|
|
@@ -111,10 +109,10 @@ describe("BaseOperations Operations", () => {
|
|
|
111
109
|
id: "duplicate",
|
|
112
110
|
documentType: "powerhouse/first",
|
|
113
111
|
};
|
|
114
|
-
let updatedDoc = reducer(document,
|
|
112
|
+
let updatedDoc = reducer(document, addDocumentType(input));
|
|
115
113
|
expect(updatedDoc.state.global.documentTypes).toHaveLength(1);
|
|
116
114
|
expect(updatedDoc.operations.global[0].error).toBeUndefined();
|
|
117
|
-
updatedDoc = reducer(updatedDoc,
|
|
115
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
118
116
|
id: "duplicate",
|
|
119
117
|
documentType: "powerhouse/second",
|
|
120
118
|
}));
|
|
@@ -125,42 +123,42 @@ describe("BaseOperations Operations", () => {
|
|
|
125
123
|
});
|
|
126
124
|
describe("removeDocumentType", () => {
|
|
127
125
|
it("should mutate state by removing document type from array", () => {
|
|
128
|
-
let updatedDoc = reducer(document,
|
|
126
|
+
let updatedDoc = reducer(document, addDocumentType({
|
|
129
127
|
id: "to-remove",
|
|
130
128
|
documentType: "powerhouse/test",
|
|
131
129
|
}));
|
|
132
|
-
updatedDoc = reducer(updatedDoc,
|
|
130
|
+
updatedDoc = reducer(updatedDoc, removeDocumentType({ id: "to-remove" }));
|
|
133
131
|
expect(updatedDoc.state.global.documentTypes).not.toContainEqual({
|
|
134
132
|
id: "to-remove",
|
|
135
133
|
documentType: "powerhouse/test",
|
|
136
134
|
});
|
|
137
135
|
});
|
|
138
136
|
it("should remove existing ID", () => {
|
|
139
|
-
let updatedDoc = reducer(document,
|
|
137
|
+
let updatedDoc = reducer(document, addDocumentType({
|
|
140
138
|
id: "existing",
|
|
141
139
|
documentType: "powerhouse/test",
|
|
142
140
|
}));
|
|
143
141
|
const lengthBefore = updatedDoc.state.global.documentTypes.length;
|
|
144
|
-
updatedDoc = reducer(updatedDoc,
|
|
142
|
+
updatedDoc = reducer(updatedDoc, removeDocumentType({ id: "existing" }));
|
|
145
143
|
expect(updatedDoc.state.global.documentTypes.length).toBe(lengthBefore - 1);
|
|
146
144
|
expect(updatedDoc.state.global.documentTypes.find((dt) => dt.id === "existing")).toBeUndefined();
|
|
147
145
|
});
|
|
148
146
|
it("should gracefully handle non-existent ID", () => {
|
|
149
147
|
const initialState = document.state.global.documentTypes;
|
|
150
|
-
const updatedDocument = reducer(document,
|
|
148
|
+
const updatedDocument = reducer(document, removeDocumentType({ id: "non-existent-id" }));
|
|
151
149
|
expect(updatedDocument.state.global.documentTypes).toEqual(initialState);
|
|
152
150
|
});
|
|
153
151
|
it("should handle empty array gracefully", () => {
|
|
154
152
|
expect(document.state.global.documentTypes).toEqual([]);
|
|
155
|
-
const updatedDocument = reducer(document,
|
|
153
|
+
const updatedDocument = reducer(document, removeDocumentType({ id: "any-id" }));
|
|
156
154
|
expect(updatedDocument.state.global.documentTypes).toEqual([]);
|
|
157
155
|
});
|
|
158
156
|
it("should add then immediately remove item", () => {
|
|
159
|
-
let updatedDoc = reducer(document,
|
|
157
|
+
let updatedDoc = reducer(document, addDocumentType({
|
|
160
158
|
id: "temp-type",
|
|
161
159
|
documentType: "powerhouse/temp",
|
|
162
160
|
}));
|
|
163
|
-
updatedDoc = reducer(updatedDoc,
|
|
161
|
+
updatedDoc = reducer(updatedDoc, removeDocumentType({ id: "temp-type" }));
|
|
164
162
|
expect(updatedDoc.state.global.documentTypes.find((dt) => dt.id === "temp-type")).toBeUndefined();
|
|
165
163
|
expect(updatedDoc.operations.global).toHaveLength(2);
|
|
166
164
|
});
|
|
@@ -2,10 +2,8 @@
|
|
|
2
2
|
* This is a scaffold file meant for customization:
|
|
3
3
|
* - change it by adding new tests or modifying the existing ones
|
|
4
4
|
*/
|
|
5
|
+
import { addDocumentType, reducer, removeDocumentType, setProcessorName, setProcessorStatus, setProcessorType, utils, } from "@powerhousedao/vetra/document-models/processor-module";
|
|
5
6
|
import { describe, expect, it } from "vitest";
|
|
6
|
-
import * as creators from "../../gen/base-operations/creators.js";
|
|
7
|
-
import { reducer } from "../../gen/reducer.js";
|
|
8
|
-
import utils from "../../gen/utils.js";
|
|
9
7
|
describe("Processor Module Document Model", () => {
|
|
10
8
|
it("should have correct initial values", () => {
|
|
11
9
|
const document = utils.createDocument();
|
|
@@ -13,16 +11,20 @@ describe("Processor Module Document Model", () => {
|
|
|
13
11
|
expect(document.state.global.type).toBe("");
|
|
14
12
|
expect(document.state.global.documentTypes).toEqual([]);
|
|
15
13
|
expect(document.state.global.status).toBe("DRAFT");
|
|
14
|
+
expect(utils.isStateOfType(document.state)).toBe(true);
|
|
15
|
+
expect(utils.assertIsStateOfType(document.state)).toBeUndefined();
|
|
16
|
+
expect(utils.isDocumentOfType(document)).toBe(true);
|
|
17
|
+
expect(utils.assertIsDocumentOfType(document)).toBeUndefined();
|
|
16
18
|
});
|
|
17
19
|
it("should handle multiple operations and maintain consistency", () => {
|
|
18
20
|
const document = utils.createDocument();
|
|
19
|
-
let updatedDoc = reducer(document,
|
|
20
|
-
updatedDoc = reducer(updatedDoc,
|
|
21
|
-
updatedDoc = reducer(updatedDoc,
|
|
21
|
+
let updatedDoc = reducer(document, setProcessorName({ name: "Test Processor" }));
|
|
22
|
+
updatedDoc = reducer(updatedDoc, setProcessorType({ type: "analytics" }));
|
|
23
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
22
24
|
id: "test-type",
|
|
23
25
|
documentType: "powerhouse/test",
|
|
24
26
|
}));
|
|
25
|
-
updatedDoc = reducer(updatedDoc,
|
|
27
|
+
updatedDoc = reducer(updatedDoc, setProcessorStatus({ status: "CONFIRMED" }));
|
|
26
28
|
// Verify state consistency
|
|
27
29
|
expect(updatedDoc.state.global.name).toBe("Test Processor");
|
|
28
30
|
expect(updatedDoc.state.global.type).toBe("analytics");
|
|
@@ -33,50 +35,50 @@ describe("Processor Module Document Model", () => {
|
|
|
33
35
|
it("should handle workflow: set name/type, add types, confirm status", () => {
|
|
34
36
|
const document = utils.createDocument();
|
|
35
37
|
// Step 1: Set processor name and type
|
|
36
|
-
let updatedDoc = reducer(document,
|
|
38
|
+
let updatedDoc = reducer(document, setProcessorName({ name: "Production Processor" }));
|
|
37
39
|
expect(updatedDoc.state.global.name).toBe("Production Processor");
|
|
38
|
-
updatedDoc = reducer(updatedDoc,
|
|
40
|
+
updatedDoc = reducer(updatedDoc, setProcessorType({ type: "data-analytics" }));
|
|
39
41
|
expect(updatedDoc.state.global.type).toBe("data-analytics");
|
|
40
42
|
// Step 2: Add document types
|
|
41
|
-
updatedDoc = reducer(updatedDoc,
|
|
43
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
42
44
|
id: "budget-docs",
|
|
43
45
|
documentType: "powerhouse/budget",
|
|
44
46
|
}));
|
|
45
|
-
updatedDoc = reducer(updatedDoc,
|
|
47
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
46
48
|
id: "invoice-docs",
|
|
47
49
|
documentType: "powerhouse/invoice",
|
|
48
50
|
}));
|
|
49
51
|
expect(updatedDoc.state.global.documentTypes).toHaveLength(2);
|
|
50
52
|
// Step 3: Confirm processor status
|
|
51
|
-
updatedDoc = reducer(updatedDoc,
|
|
53
|
+
updatedDoc = reducer(updatedDoc, setProcessorStatus({ status: "CONFIRMED" }));
|
|
52
54
|
expect(updatedDoc.state.global.status).toBe("CONFIRMED");
|
|
53
55
|
});
|
|
54
56
|
it("should handle reset scenario: remove all types and add new ones", () => {
|
|
55
57
|
const document = utils.createDocument();
|
|
56
58
|
// Add initial types
|
|
57
|
-
let updatedDoc = reducer(document,
|
|
59
|
+
let updatedDoc = reducer(document, addDocumentType({
|
|
58
60
|
id: "old-type-1",
|
|
59
61
|
documentType: "powerhouse/old1",
|
|
60
62
|
}));
|
|
61
|
-
updatedDoc = reducer(updatedDoc,
|
|
63
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
62
64
|
id: "old-type-2",
|
|
63
65
|
documentType: "powerhouse/old2",
|
|
64
66
|
}));
|
|
65
67
|
expect(updatedDoc.state.global.documentTypes).toHaveLength(2);
|
|
66
68
|
// Remove all types
|
|
67
|
-
updatedDoc = reducer(updatedDoc,
|
|
68
|
-
updatedDoc = reducer(updatedDoc,
|
|
69
|
+
updatedDoc = reducer(updatedDoc, removeDocumentType({ id: "old-type-1" }));
|
|
70
|
+
updatedDoc = reducer(updatedDoc, removeDocumentType({ id: "old-type-2" }));
|
|
69
71
|
expect(updatedDoc.state.global.documentTypes).toEqual([]);
|
|
70
72
|
// Add new types from scratch
|
|
71
|
-
updatedDoc = reducer(updatedDoc,
|
|
73
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
72
74
|
id: "new-type-1",
|
|
73
75
|
documentType: "powerhouse/new1",
|
|
74
76
|
}));
|
|
75
|
-
updatedDoc = reducer(updatedDoc,
|
|
77
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
76
78
|
id: "new-type-2",
|
|
77
79
|
documentType: "powerhouse/new2",
|
|
78
80
|
}));
|
|
79
|
-
updatedDoc = reducer(updatedDoc,
|
|
81
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({
|
|
80
82
|
id: "new-type-3",
|
|
81
83
|
documentType: "powerhouse/new3",
|
|
82
84
|
}));
|
|
@@ -88,15 +90,15 @@ describe("Processor Module Document Model", () => {
|
|
|
88
90
|
it("should maintain state integrity with complex add/remove sequences", () => {
|
|
89
91
|
const document = utils.createDocument();
|
|
90
92
|
// Add multiple types
|
|
91
|
-
let updatedDoc = reducer(document,
|
|
92
|
-
updatedDoc = reducer(updatedDoc,
|
|
93
|
-
updatedDoc = reducer(updatedDoc,
|
|
93
|
+
let updatedDoc = reducer(document, addDocumentType({ id: "type-a", documentType: "a" }));
|
|
94
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({ id: "type-b", documentType: "b" }));
|
|
95
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({ id: "type-c", documentType: "c" }));
|
|
94
96
|
expect(updatedDoc.state.global.documentTypes).toHaveLength(3);
|
|
95
97
|
// Remove middle one
|
|
96
|
-
updatedDoc = reducer(updatedDoc,
|
|
98
|
+
updatedDoc = reducer(updatedDoc, removeDocumentType({ id: "type-b" }));
|
|
97
99
|
expect(updatedDoc.state.global.documentTypes).toHaveLength(2);
|
|
98
100
|
// Add it back with new documentType
|
|
99
|
-
updatedDoc = reducer(updatedDoc,
|
|
101
|
+
updatedDoc = reducer(updatedDoc, addDocumentType({ id: "type-b", documentType: "b-new" }));
|
|
100
102
|
expect(updatedDoc.state.global.documentTypes).toHaveLength(3);
|
|
101
103
|
// Verify order and content
|
|
102
104
|
const typeB = updatedDoc.state.global.documentTypes.find((dt) => dt.id === "type-b");
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { ProcessorModulePHState } from "./gen/types.js";
|
|
2
|
+
/** Utils for the ProcessorModule document model */
|
|
3
|
+
export declare const utils: {
|
|
4
|
+
fileExtension: string;
|
|
5
|
+
createState: import("document-model").CreateState<ProcessorModulePHState>;
|
|
6
|
+
createDocument: import("document-model").CreateDocument<ProcessorModulePHState>;
|
|
7
|
+
loadFromInput: import("document-model").LoadFromInput<ProcessorModulePHState>;
|
|
8
|
+
saveToFileHandle: import("document-model").SaveToFileHandle;
|
|
9
|
+
isStateOfType: import("document-model").IsStateOfType<ProcessorModulePHState>;
|
|
10
|
+
assertIsStateOfType: import("document-model").AssertIsStateOfType<ProcessorModulePHState>;
|
|
11
|
+
isDocumentOfType: import("document-model").IsDocumentOfType<ProcessorModulePHState>;
|
|
12
|
+
assertIsDocumentOfType: import("document-model").AssertIsDocumentOfType<ProcessorModulePHState>;
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../../document-models/processor-module/utils.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,gBAAgB,CAAC;AAI7D,mDAAmD;AACnD,eAAO,MAAM,KAAK;;;;;;;;;;CAGoC,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/** Actions for the SubgraphModule document model */
|
|
2
|
+
export declare const actions: {
|
|
3
|
+
setSubgraphName: (input: import("./index.js").SetSubgraphNameInput) => import("./index.js").SetSubgraphNameAction;
|
|
4
|
+
setSubgraphStatus: (input: import("./index.js").SetSubgraphStatusInput) => import("./index.js").SetSubgraphStatusAction;
|
|
5
|
+
setName: (name: string) => import("document-model").SetNameAction;
|
|
6
|
+
undo: (skip?: number, scope?: string) => import("document-model").UndoAction;
|
|
7
|
+
redo: (count?: number, scope?: string) => import("document-model").RedoAction;
|
|
8
|
+
prune: (start?: number, end?: number, scope?: string) => import("document-model").SchemaPruneAction;
|
|
9
|
+
loadState: <TState extends import("document-model").PHBaseState = import("document-model").PHBaseState>(state: TState & {
|
|
10
|
+
name: string;
|
|
11
|
+
}, operations: number) => import("document-model").LoadStateAction;
|
|
12
|
+
noop: (scope?: string) => import("document-model").NOOPAction;
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=actions.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"actions.d.ts","sourceRoot":"","sources":["../../../document-models/subgraph-module/actions.ts"],"names":[],"mappings":"AAGA,oDAAoD;AACpD,eAAO,MAAM,OAAO;sBACyG,gDAA2B;wBAA4L,kDAA6B;;eAA0iN,CAAC,eAAe,CAAC;gBAAkE,CAAC,eAAe,CAAC;iBAAmE,CAAC,aAAa,CAAC,eAAe,CAAC;;;;gBAAqS,CAAC;CADp0O,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import type { SetSubgraphNameInput, SetSubgraphStatusInput } from "../types.js";
|
|
2
|
+
import type { SetSubgraphNameAction, SetSubgraphStatusAction } from "./actions.js";
|
|
3
3
|
export declare const setSubgraphName: (input: SetSubgraphNameInput) => SetSubgraphNameAction;
|
|
4
4
|
export declare const setSubgraphStatus: (input: SetSubgraphStatusInput) => SetSubgraphStatusAction;
|
|
5
5
|
//# sourceMappingURL=creators.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"creators.d.ts","sourceRoot":"","sources":["../../../../../document-models/subgraph-module/gen/base-operations/creators.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"creators.d.ts","sourceRoot":"","sources":["../../../../../document-models/subgraph-module/gen/base-operations/creators.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,oBAAoB,EAAE,sBAAsB,EAAE,MAAM,aAAa,CAAC;AAChF,OAAO,KAAK,EACV,qBAAqB,EACrB,uBAAuB,EACxB,MAAM,cAAc,CAAC;AAEtB,eAAO,MAAM,eAAe,GAAI,OAAO,oBAAoB,0BAOxD,CAAC;AAEJ,eAAO,MAAM,iBAAiB,GAAI,OAAO,sBAAsB,4BAO5D,CAAC"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { createAction } from "document-model/core";
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
export const
|
|
5
|
-
export const setSubgraphStatus = (input) => createAction("SET_SUBGRAPH_STATUS", { ...input }, undefined, z.SetSubgraphStatusInputSchema, "global");
|
|
2
|
+
import { SetSubgraphNameInputSchema, SetSubgraphStatusInputSchema, } from "../schema/zod.js";
|
|
3
|
+
export const setSubgraphName = (input) => createAction("SET_SUBGRAPH_NAME", { ...input }, undefined, SetSubgraphNameInputSchema, "global");
|
|
4
|
+
export const setSubgraphStatus = (input) => createAction("SET_SUBGRAPH_STATUS", { ...input }, undefined, SetSubgraphStatusInputSchema, "global");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"creators.d.ts","sourceRoot":"","sources":["../../../../document-models/subgraph-module/gen/creators.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC"}
|
|
1
|
+
{"version":3,"file":"creators.d.ts","sourceRoot":"","sources":["../../../../document-models/subgraph-module/gen/creators.ts"],"names":[],"mappings":"AAAA,cAAc,+BAA+B,CAAC;AAC9C,OAAO,KAAK,qBAAqB,MAAM,+BAA+B,CAAC"}
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import type { SubgraphModuleDocument, SubgraphModulePHState } from "./types.js";
|
|
3
|
+
/** Schema for validating the header object of a SubgraphModule document */
|
|
4
|
+
export declare const SubgraphModuleDocumentHeaderSchema: z.ZodObject<{
|
|
5
|
+
id: z.ZodString;
|
|
6
|
+
name: z.ZodString;
|
|
7
|
+
createdAtUtcIso: z.ZodString;
|
|
8
|
+
lastModifiedAtUtcIso: z.ZodString;
|
|
9
|
+
} & {
|
|
10
|
+
documentType: z.ZodLiteral<"powerhouse/subgraph">;
|
|
11
|
+
}, "strip", z.ZodTypeAny, {
|
|
12
|
+
documentType: "powerhouse/subgraph";
|
|
13
|
+
name: string;
|
|
14
|
+
id: string;
|
|
15
|
+
createdAtUtcIso: string;
|
|
16
|
+
lastModifiedAtUtcIso: string;
|
|
17
|
+
}, {
|
|
18
|
+
documentType: "powerhouse/subgraph";
|
|
19
|
+
name: string;
|
|
20
|
+
id: string;
|
|
21
|
+
createdAtUtcIso: string;
|
|
22
|
+
lastModifiedAtUtcIso: string;
|
|
23
|
+
}>;
|
|
24
|
+
/** Schema for validating the state object of a SubgraphModule document */
|
|
25
|
+
export declare const SubgraphModulePHStateSchema: z.ZodObject<{} & {
|
|
26
|
+
global: z.ZodObject<Required<{
|
|
27
|
+
name: z.ZodType<string, any, string>;
|
|
28
|
+
status: z.ZodType<import("./types.js").StatusType, any, import("./types.js").StatusType>;
|
|
29
|
+
}>, z.UnknownKeysParam, z.ZodTypeAny, {
|
|
30
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
31
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
32
|
+
}, {
|
|
33
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
34
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
35
|
+
}>;
|
|
36
|
+
}, "strip", z.ZodTypeAny, {
|
|
37
|
+
global: {
|
|
38
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
39
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
40
|
+
};
|
|
41
|
+
}, {
|
|
42
|
+
global: {
|
|
43
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
44
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
45
|
+
};
|
|
46
|
+
}>;
|
|
47
|
+
export declare const SubgraphModuleDocumentSchema: z.ZodObject<{
|
|
48
|
+
header: z.ZodObject<{
|
|
49
|
+
id: z.ZodString;
|
|
50
|
+
name: z.ZodString;
|
|
51
|
+
createdAtUtcIso: z.ZodString;
|
|
52
|
+
lastModifiedAtUtcIso: z.ZodString;
|
|
53
|
+
} & {
|
|
54
|
+
documentType: z.ZodLiteral<"powerhouse/subgraph">;
|
|
55
|
+
}, "strip", z.ZodTypeAny, {
|
|
56
|
+
documentType: "powerhouse/subgraph";
|
|
57
|
+
name: string;
|
|
58
|
+
id: string;
|
|
59
|
+
createdAtUtcIso: string;
|
|
60
|
+
lastModifiedAtUtcIso: string;
|
|
61
|
+
}, {
|
|
62
|
+
documentType: "powerhouse/subgraph";
|
|
63
|
+
name: string;
|
|
64
|
+
id: string;
|
|
65
|
+
createdAtUtcIso: string;
|
|
66
|
+
lastModifiedAtUtcIso: string;
|
|
67
|
+
}>;
|
|
68
|
+
state: z.ZodObject<{} & {
|
|
69
|
+
global: z.ZodObject<Required<{
|
|
70
|
+
name: z.ZodType<string, any, string>;
|
|
71
|
+
status: z.ZodType<import("./types.js").StatusType, any, import("./types.js").StatusType>;
|
|
72
|
+
}>, z.UnknownKeysParam, z.ZodTypeAny, {
|
|
73
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
74
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
75
|
+
}, {
|
|
76
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
77
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
78
|
+
}>;
|
|
79
|
+
}, "strip", z.ZodTypeAny, {
|
|
80
|
+
global: {
|
|
81
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
82
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
83
|
+
};
|
|
84
|
+
}, {
|
|
85
|
+
global: {
|
|
86
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
87
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
88
|
+
};
|
|
89
|
+
}>;
|
|
90
|
+
initialState: z.ZodObject<{} & {
|
|
91
|
+
global: z.ZodObject<Required<{
|
|
92
|
+
name: z.ZodType<string, any, string>;
|
|
93
|
+
status: z.ZodType<import("./types.js").StatusType, any, import("./types.js").StatusType>;
|
|
94
|
+
}>, z.UnknownKeysParam, z.ZodTypeAny, {
|
|
95
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
96
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
97
|
+
}, {
|
|
98
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
99
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
100
|
+
}>;
|
|
101
|
+
}, "strip", z.ZodTypeAny, {
|
|
102
|
+
global: {
|
|
103
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
104
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
105
|
+
};
|
|
106
|
+
}, {
|
|
107
|
+
global: {
|
|
108
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
109
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
110
|
+
};
|
|
111
|
+
}>;
|
|
112
|
+
}, "strip", z.ZodTypeAny, {
|
|
113
|
+
header: {
|
|
114
|
+
documentType: "powerhouse/subgraph";
|
|
115
|
+
name: string;
|
|
116
|
+
id: string;
|
|
117
|
+
createdAtUtcIso: string;
|
|
118
|
+
lastModifiedAtUtcIso: string;
|
|
119
|
+
};
|
|
120
|
+
state: {
|
|
121
|
+
global: {
|
|
122
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
123
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
124
|
+
};
|
|
125
|
+
};
|
|
126
|
+
initialState: {
|
|
127
|
+
global: {
|
|
128
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
129
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
130
|
+
};
|
|
131
|
+
};
|
|
132
|
+
}, {
|
|
133
|
+
header: {
|
|
134
|
+
documentType: "powerhouse/subgraph";
|
|
135
|
+
name: string;
|
|
136
|
+
id: string;
|
|
137
|
+
createdAtUtcIso: string;
|
|
138
|
+
lastModifiedAtUtcIso: string;
|
|
139
|
+
};
|
|
140
|
+
state: {
|
|
141
|
+
global: {
|
|
142
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
143
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
144
|
+
};
|
|
145
|
+
};
|
|
146
|
+
initialState: {
|
|
147
|
+
global: {
|
|
148
|
+
status: import("./types.js").StatusType | `${import("./types.js").StatusType}`;
|
|
149
|
+
name: import("./types.js").Scalars["String"]["output"];
|
|
150
|
+
};
|
|
151
|
+
};
|
|
152
|
+
}>;
|
|
153
|
+
/** Simple helper function to check if a state object is a SubgraphModule document state object */
|
|
154
|
+
export declare function isSubgraphModuleState(state: unknown): state is SubgraphModulePHState;
|
|
155
|
+
/** Simple helper function to assert that a document state object is a SubgraphModule document state object */
|
|
156
|
+
export declare function assertIsSubgraphModuleState(state: unknown): asserts state is SubgraphModulePHState;
|
|
157
|
+
/** Simple helper function to check if a document is a SubgraphModule document */
|
|
158
|
+
export declare function isSubgraphModuleDocument(document: unknown): document is SubgraphModuleDocument;
|
|
159
|
+
/** Simple helper function to assert that a document is a SubgraphModule document */
|
|
160
|
+
export declare function assertIsSubgraphModuleDocument(document: unknown): asserts document is SubgraphModuleDocument;
|
|
161
|
+
//# sourceMappingURL=document-schema.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"document-schema.d.ts","sourceRoot":"","sources":["../../../../document-models/subgraph-module/gen/document-schema.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,KAAK,EAAE,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAC;AAEhF,2EAA2E;AAC3E,eAAO,MAAM,kCAAkC;;;;;;;;;;;;;;;;;;;EAG3C,CAAC;AAEL,0EAA0E;AAC1E,eAAO,MAAM,2BAA2B;;;;;;cAqCkP,sCAAkB;;;cAAlB,sCAAkB;;;;;cAAlB,sCAAkB;;;;;cAAlB,sCAAkB;;EAnC1S,CAAC;AAEH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAiCiP,sCAAkB;;;kBAAlB,sCAAkB;;;;;kBAAlB,sCAAkB;;;;;kBAAlB,sCAAkB;;;;;;;;;kBAAlB,sCAAkB;;;kBAAlB,sCAAkB;;;;;kBAAlB,sCAAkB;;;;;kBAAlB,sCAAkB;;;;;;;;;;;;;;kBAAlB,sCAAkB;;;;;;kBAAlB,sCAAkB;;;;;;;;;;;;;;kBAAlB,sCAAkB;;;;;;kBAAlB,sCAAkB;;;EA7B1S,CAAC;AAEH,kGAAkG;AAClG,wBAAgB,qBAAqB,CACnC,KAAK,EAAE,OAAO,GACb,KAAK,IAAI,qBAAqB,CAEhC;AAED,8GAA8G;AAC9G,wBAAgB,2BAA2B,CACzC,KAAK,EAAE,OAAO,GACb,OAAO,CAAC,KAAK,IAAI,qBAAqB,CAExC;AAED,iFAAiF;AACjF,wBAAgB,wBAAwB,CACtC,QAAQ,EAAE,OAAO,GAChB,QAAQ,IAAI,sBAAsB,CAEpC;AAED,oFAAoF;AACpF,wBAAgB,8BAA8B,CAC5C,QAAQ,EAAE,OAAO,GAChB,OAAO,CAAC,QAAQ,IAAI,sBAAsB,CAE5C"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { BaseDocumentHeaderSchema, BaseDocumentStateSchema, } from "document-model";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
import { subgraphModuleDocumentType } from "./document-type.js";
|
|
4
|
+
import { SubgraphModuleStateSchema } from "./schema/zod.js";
|
|
5
|
+
/** Schema for validating the header object of a SubgraphModule document */
|
|
6
|
+
export const SubgraphModuleDocumentHeaderSchema = BaseDocumentHeaderSchema.extend({
|
|
7
|
+
documentType: z.literal(subgraphModuleDocumentType),
|
|
8
|
+
});
|
|
9
|
+
/** Schema for validating the state object of a SubgraphModule document */
|
|
10
|
+
export const SubgraphModulePHStateSchema = BaseDocumentStateSchema.extend({
|
|
11
|
+
global: SubgraphModuleStateSchema(),
|
|
12
|
+
});
|
|
13
|
+
export const SubgraphModuleDocumentSchema = z.object({
|
|
14
|
+
header: SubgraphModuleDocumentHeaderSchema,
|
|
15
|
+
state: SubgraphModulePHStateSchema,
|
|
16
|
+
initialState: SubgraphModulePHStateSchema,
|
|
17
|
+
});
|
|
18
|
+
/** Simple helper function to check if a state object is a SubgraphModule document state object */
|
|
19
|
+
export function isSubgraphModuleState(state) {
|
|
20
|
+
return SubgraphModulePHStateSchema.safeParse(state).success;
|
|
21
|
+
}
|
|
22
|
+
/** Simple helper function to assert that a document state object is a SubgraphModule document state object */
|
|
23
|
+
export function assertIsSubgraphModuleState(state) {
|
|
24
|
+
SubgraphModulePHStateSchema.parse(state);
|
|
25
|
+
}
|
|
26
|
+
/** Simple helper function to check if a document is a SubgraphModule document */
|
|
27
|
+
export function isSubgraphModuleDocument(document) {
|
|
28
|
+
return SubgraphModuleDocumentSchema.safeParse(document).success;
|
|
29
|
+
}
|
|
30
|
+
/** Simple helper function to assert that a document is a SubgraphModule document */
|
|
31
|
+
export function assertIsSubgraphModuleDocument(document) {
|
|
32
|
+
SubgraphModuleDocumentSchema.parse(document);
|
|
33
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"document-type.d.ts","sourceRoot":"","sources":["../../../../document-models/subgraph-module/gen/document-type.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,0BAA0B,wBAAwB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const subgraphModuleDocumentType = "powerhouse/subgraph";
|
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
export * from "./actions.js";
|
|
2
2
|
export * from "./document-model.js";
|
|
3
3
|
export * from "./types.js";
|
|
4
|
-
export *
|
|
4
|
+
export * from "./creators.js";
|
|
5
5
|
export { createSubgraphModuleDocument, createState, defaultPHState, defaultGlobalState, defaultLocalState, } from "./ph-factories.js";
|
|
6
|
+
export * from "./utils.js";
|
|
7
|
+
export * from "./reducer.js";
|
|
8
|
+
export * from "./schema/index.js";
|
|
9
|
+
export * from "./document-type.js";
|
|
10
|
+
export * from "./document-schema.js";
|
|
11
|
+
export * from "./base-operations/operations.js";
|
|
6
12
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../document-models/subgraph-module/gen/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,qBAAqB,CAAC;AACpC,cAAc,YAAY,CAAC;AAC3B,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../document-models/subgraph-module/gen/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,qBAAqB,CAAC;AACpC,cAAc,YAAY,CAAC;AAC3B,cAAc,eAAe,CAAC;AAC9B,OAAO,EACL,4BAA4B,EAC5B,WAAW,EACX,cAAc,EACd,kBAAkB,EAClB,iBAAiB,GAClB,MAAM,mBAAmB,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,oBAAoB,CAAC;AACnC,cAAc,sBAAsB,CAAC;AACrC,cAAc,iCAAiC,CAAC"}
|