@powerhousedao/vetra 6.2.3 → 6.3.0-dev.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (98) hide show
  1. package/dist/codegen/index.d.ts +19 -7
  2. package/dist/codegen/index.d.ts.map +1 -1
  3. package/dist/codegen/index.js +29 -27
  4. package/dist/codegen/index.js.map +1 -1
  5. package/dist/codegen/spec.js +1 -1
  6. package/dist/document-models/app-module/index.d.ts +3 -34
  7. package/dist/document-models/app-module/index.js +1 -1
  8. package/dist/document-models/document-editor/index.d.ts +3 -32
  9. package/dist/document-models/index.d.ts +5 -5
  10. package/dist/document-models/index.js +2 -2
  11. package/dist/document-models/processor-module/index.d.ts +3 -35
  12. package/dist/document-models/processor-module/index.js +4 -4
  13. package/dist/document-models/subgraph-module/index.d.ts +3 -30
  14. package/dist/document-models/vetra-package/index.d.ts +3 -38
  15. package/dist/{editor-CiX3Tq3g.js → editor-BDR7IYJG.js} +3 -5
  16. package/dist/{editor-CiX3Tq3g.js.map → editor-BDR7IYJG.js.map} +1 -1
  17. package/dist/{editor-C5a0rBQj.js → editor-CbT_8Z6A.js} +4 -6
  18. package/dist/{editor-C5a0rBQj.js.map → editor-CbT_8Z6A.js.map} +1 -1
  19. package/dist/{editor-DpZVlVN1.js → editor-CnfajXGg.js} +3 -5
  20. package/dist/{editor-DpZVlVN1.js.map → editor-CnfajXGg.js.map} +1 -1
  21. package/dist/{editor-DpadPeVq.js → editor-Cnk0M044.js} +46 -27
  22. package/dist/editor-Cnk0M044.js.map +1 -0
  23. package/dist/{editor-BXOEFIDj.js → editor-D5SIbFn_.js} +3 -3
  24. package/dist/{editor-BXOEFIDj.js.map → editor-D5SIbFn_.js.map} +1 -1
  25. package/dist/{editor-DFEeM_dy.js → editor-SJk7cr6k.js} +3 -5
  26. package/dist/{editor-DFEeM_dy.js.map → editor-SJk7cr6k.js.map} +1 -1
  27. package/dist/editors/index.d.ts +17 -6
  28. package/dist/editors/index.d.ts.map +1 -1
  29. package/dist/editors/index.js +1 -1
  30. package/dist/{factory-BzUAqoGU.js → factory-BUuO4fIN.js} +11 -3
  31. package/dist/factory-BUuO4fIN.js.map +1 -0
  32. package/dist/{factory-BWrWHoS5.js → factory-C-Nm-wK8.js} +15 -11
  33. package/dist/factory-C-Nm-wK8.js.map +1 -0
  34. package/dist/index-BwHVZmO6.d.ts +43 -0
  35. package/dist/index-BwHVZmO6.d.ts.map +1 -0
  36. package/dist/{index-D6Ai0OOc.d.ts → index-C56rbYzd.d.ts} +2 -1
  37. package/dist/{index-D6Ai0OOc.d.ts.map → index-C56rbYzd.d.ts.map} +1 -1
  38. package/dist/index-CDV0nUS6.d.ts +36 -0
  39. package/dist/index-CDV0nUS6.d.ts.map +1 -0
  40. package/dist/{index-DPG4u1Ym.d.ts → index-ChQj71kz.d.ts} +4 -3
  41. package/dist/{index-DPG4u1Ym.d.ts.map → index-ChQj71kz.d.ts.map} +1 -1
  42. package/dist/index-CiPX7twW.d.ts +34 -0
  43. package/dist/index-CiPX7twW.d.ts.map +1 -0
  44. package/dist/{index-B52jv-LY.d.ts → index-CqDvbSe4.d.ts} +3 -2
  45. package/dist/{index-B52jv-LY.d.ts.map → index-CqDvbSe4.d.ts.map} +1 -1
  46. package/dist/index-DGhkn3As.d.ts +40 -0
  47. package/dist/index-DGhkn3As.d.ts.map +1 -0
  48. package/dist/index-DoopUfIG.d.ts +32 -0
  49. package/dist/index-DoopUfIG.d.ts.map +1 -0
  50. package/dist/{index-DplUuZMT.d.ts → index-RAhSmsFD.d.ts} +2 -1
  51. package/dist/{index-DplUuZMT.d.ts.map → index-RAhSmsFD.d.ts.map} +1 -1
  52. package/dist/index.d.ts +10 -5
  53. package/dist/index.d.ts.map +1 -1
  54. package/dist/index.js +3 -3
  55. package/dist/{module-Caxhis1M.js → module-23VayWKe.js} +7 -7
  56. package/dist/module-23VayWKe.js.map +1 -0
  57. package/dist/{module-CdpGkPNN.js → module-B6S4QGOx.js} +7 -7
  58. package/dist/module-B6S4QGOx.js.map +1 -0
  59. package/dist/{module-Db8mmgzN.js → module-BktWa0rB.js} +11 -9
  60. package/dist/module-BktWa0rB.js.map +1 -0
  61. package/dist/{module-D4lqkHHK.d.ts → module-C-jL7yqs.d.ts} +2 -1
  62. package/dist/{module-D4lqkHHK.d.ts.map → module-C-jL7yqs.d.ts.map} +1 -1
  63. package/dist/{ph-factories-HuC7_vvF.js → ph-factories-fEke-Nr8.js} +2 -2
  64. package/dist/{ph-factories-HuC7_vvF.js.map → ph-factories-fEke-Nr8.js.map} +1 -1
  65. package/dist/{processor-CsiUWh93.js → processor-CgDcxcaa.js} +426 -325
  66. package/dist/processor-CgDcxcaa.js.map +1 -0
  67. package/dist/processors/codegen/index.d.ts +11 -2
  68. package/dist/processors/codegen/index.d.ts.map +1 -1
  69. package/dist/processors/codegen/index.js +2 -2
  70. package/dist/processors/index.js +1 -1
  71. package/dist/processors/vetra-read-model/index.d.ts.map +1 -1
  72. package/dist/processors/vetra-read-model/index.js +1 -1
  73. package/dist/{spec-api-BIJ_jsGp.js → spec-api-BGj7gcQn.js} +18 -12
  74. package/dist/{spec-api-BIJ_jsGp.js.map → spec-api-BGj7gcQn.js.map} +1 -1
  75. package/dist/subgraph-type-lint-BZuO7F-G.js +116 -0
  76. package/dist/subgraph-type-lint-BZuO7F-G.js.map +1 -0
  77. package/dist/switchboard-B17FaODm.js +8 -0
  78. package/dist/{switchboard-kgDm1UIQ.js.map → switchboard-B17FaODm.js.map} +1 -1
  79. package/dist/{utils-w_21RRK6.js → utils-BJk4_43W.js} +22 -2
  80. package/dist/utils-BJk4_43W.js.map +1 -0
  81. package/package.json +13 -11
  82. package/style.css +2 -0
  83. package/dist/document-models/app-module/index.d.ts.map +0 -1
  84. package/dist/document-models/document-editor/index.d.ts.map +0 -1
  85. package/dist/document-models/processor-module/index.d.ts.map +0 -1
  86. package/dist/document-models/subgraph-module/index.d.ts.map +0 -1
  87. package/dist/document-models/vetra-package/index.d.ts.map +0 -1
  88. package/dist/editor-DpadPeVq.js.map +0 -1
  89. package/dist/factory-BWrWHoS5.js.map +0 -1
  90. package/dist/factory-BzUAqoGU.js.map +0 -1
  91. package/dist/module-Caxhis1M.js.map +0 -1
  92. package/dist/module-CdpGkPNN.js.map +0 -1
  93. package/dist/module-Db8mmgzN.js.map +0 -1
  94. package/dist/processor-CsiUWh93.js.map +0 -1
  95. package/dist/switchboard-kgDm1UIQ.js +0 -8
  96. package/dist/useVetraDocument-B0k3gNtw.js +0 -30
  97. package/dist/useVetraDocument-B0k3gNtw.js.map +0 -1
  98. package/dist/utils-w_21RRK6.js.map +0 -1
@@ -10,7 +10,7 @@ const documentModel = {
10
10
  website: "https://powerhouse.inc"
11
11
  },
12
12
  extension: ".app",
13
- description: "Declares a custom Drive App (a drive-level UI surface) shipped by a Vetra Reactor Package. Use one App Module document per drive app: configure which document types it handles, whether it accepts drag-and-drop, and mark it CONFIRMED to trigger codegen of the corresponding app scaffold under `apps/`.",
13
+ description: "Declares a custom Drive App (a drive-level UI surface) shipped by a Vetra Reactor Package. Use one App Module document per drive app: configure which document types it handles, whether it accepts drag-and-drop, and mark it CONFIRMED to trigger codegen of the corresponding app scaffold under `editors/<app-id>/`.",
14
14
  specifications: [{
15
15
  state: {
16
16
  local: {
@@ -19,7 +19,7 @@ const documentModel = {
19
19
  initialValue: ""
20
20
  },
21
21
  global: {
22
- schema: "\"\"\"\nConfiguration for a Drive App contributed by the package. Drive apps render a\ncustom view at the drive level (instead of, or alongside, the document file\ntree) and can opt into which document types they accept.\n\"\"\"\ntype AppModuleState {\n \"\"\"Display name of the drive app. Also used as the source for the generated folder name under `apps/`.\"\"\"\n name: String!\n \"\"\"Lifecycle status. While DRAFT the app definition is editable and codegen is skipped; switching to CONFIRMED triggers app scaffold generation.\"\"\"\n status: StatusType!\n \"\"\"Document type ids this app handles. `null` means the app accepts any document type; an empty list means it accepts none.\"\"\"\n allowedDocumentTypes: [String!]\n \"\"\"Whether the app surface accepts dropped files from the user. Defaults to true.\"\"\"\n isDragAndDropEnabled: Boolean!\n}\n\n\"\"\"\nLifecycle status of a module definition.\n- DRAFT: still being edited; codegen does not run.\n- CONFIRMED: locked in; codegen produces the corresponding scaffold.\n\"\"\"\nenum StatusType {\n DRAFT\n CONFIRMED\n}",
22
+ schema: "\"\"\"\nConfiguration for a Drive App contributed by the package. Drive apps render a\ncustom view at the drive level (instead of, or alongside, the document file\ntree) and can opt into which document types they accept.\n\"\"\"\ntype AppModuleState {\n \"\"\"Display name of the drive app. Also used as the source for the generated folder name under `editors/`.\"\"\"\n name: String!\n \"\"\"Lifecycle status. While DRAFT the app definition is editable and codegen is skipped; switching to CONFIRMED triggers app scaffold generation.\"\"\"\n status: StatusType!\n \"\"\"Document type ids this app handles. `null` and an empty list both mean the app accepts every document type.\"\"\"\n allowedDocumentTypes: [String!]\n \"\"\"Whether the app surface accepts dropped files from the user. Defaults to true.\"\"\"\n isDragAndDropEnabled: Boolean!\n}\n\n\"\"\"\nLifecycle status of a module definition.\n- DRAFT: still being edited; codegen does not run.\n- CONFIRMED: locked in; codegen produces the corresponding scaffold.\n\"\"\"\nenum StatusType {\n DRAFT\n CONFIRMED\n}",
23
23
  examples: [],
24
24
  initialValue: "{\n \"name\": \"\",\n \"status\": \"DRAFT\",\n \"allowedDocumentTypes\": null,\n \"isDragAndDropEnabled\": true\n}"
25
25
  }
@@ -32,7 +32,7 @@ const documentModel = {
32
32
  {
33
33
  id: "f2ba2ddc-8527-4162-93bd-e045e9932013",
34
34
  name: "SET_APP_NAME",
35
- description: "Set the display name of the drive app. Also determines the generated folder name under `apps/`.",
35
+ description: "Set the display name of the drive app. Also determines the generated folder name under `editors/`.",
36
36
  schema: "input SetAppNameInput {\n name: String!\n}",
37
37
  template: "",
38
38
  reducer: "",
@@ -54,7 +54,7 @@ const documentModel = {
54
54
  {
55
55
  id: "7376f168-695f-4aef-94d0-6e381666358c",
56
56
  name: "ADD_DOCUMENT_TYPE",
57
- description: "Append a document type id to the list of types this app handles. Initializes the list if it was `null` (accept-any).",
57
+ description: "Append a document type id to the list of types this app handles. The first type added narrows the app from every type to the listed ones.",
58
58
  schema: "input AddDocumentTypeInput {\n documentType: String!\n}",
59
59
  template: "",
60
60
  reducer: "",
@@ -65,7 +65,7 @@ const documentModel = {
65
65
  {
66
66
  id: "310e4e5b-3f14-4e9a-8e09-5583c7698a65",
67
67
  name: "REMOVE_DOCUMENT_TYPE",
68
- description: "Remove a document type id from the handled list. No-op if the type is not present.",
68
+ description: "Remove a document type id from the handled list. No-op if the type is not present. Removing the last type leaves an empty list, which accepts every type.",
69
69
  schema: "input RemoveDocumentTypeInput {\n documentType: String!\n}",
70
70
  template: "",
71
71
  reducer: "",
@@ -76,7 +76,7 @@ const documentModel = {
76
76
  {
77
77
  id: "b365727a-7df3-48f0-a4f8-02362f02ad1d",
78
78
  name: "SET_DOCUMENT_TYPES",
79
- description: "Replace the entire allowed-document-types list in one call. Pass an empty list to accept none.",
79
+ description: "Replace the entire allowed-document-types list in one call. An empty list accepts every document type.",
80
80
  schema: "input SetDocumentTypesInput {\n documentTypes: [String!]!\n}",
81
81
  template: "",
82
82
  reducer: "",
@@ -128,4 +128,4 @@ const AppModule = {
128
128
  //#endregion
129
129
  export { utils as n, documentModel as r, AppModule as t };
130
130
 
131
- //# sourceMappingURL=module-Caxhis1M.js.map
131
+ //# sourceMappingURL=module-23VayWKe.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"module-23VayWKe.js","names":["genUtils","customUtils"],"sources":["../document-models/app-module/v1/gen/document-model.ts","../document-models/app-module/v1/src/utils.ts","../document-models/app-module/v1/utils.ts","../document-models/app-module/v1/module.ts"],"sourcesContent":["import type { DocumentModelGlobalState } from \"document-model\";\n\nexport const documentModel: DocumentModelGlobalState = {\n id: \"powerhouse/app\",\n name: \"App Module\",\n author: {\n name: \"Powerhouse\",\n website: \"https://powerhouse.inc\",\n },\n extension: \".app\",\n description:\n \"Declares a custom Drive App (a drive-level UI surface) shipped by a Vetra Reactor Package. Use one App Module document per drive app: configure which document types it handles, whether it accepts drag-and-drop, and mark it CONFIRMED to trigger codegen of the corresponding app scaffold under `editors/<app-id>/`.\",\n specifications: [\n {\n state: {\n local: {\n schema: \"\",\n examples: [],\n initialValue: \"\",\n },\n global: {\n schema:\n '\"\"\"\\nConfiguration for a Drive App contributed by the package. Drive apps render a\\ncustom view at the drive level (instead of, or alongside, the document file\\ntree) and can opt into which document types they accept.\\n\"\"\"\\ntype AppModuleState {\\n \"\"\"Display name of the drive app. Also used as the source for the generated folder name under `editors/`.\"\"\"\\n name: String!\\n \"\"\"Lifecycle status. While DRAFT the app definition is editable and codegen is skipped; switching to CONFIRMED triggers app scaffold generation.\"\"\"\\n status: StatusType!\\n \"\"\"Document type ids this app handles. `null` and an empty list both mean the app accepts every document type.\"\"\"\\n allowedDocumentTypes: [String!]\\n \"\"\"Whether the app surface accepts dropped files from the user. Defaults to true.\"\"\"\\n isDragAndDropEnabled: Boolean!\\n}\\n\\n\"\"\"\\nLifecycle status of a module definition.\\n- DRAFT: still being edited; codegen does not run.\\n- CONFIRMED: locked in; codegen produces the corresponding scaffold.\\n\"\"\"\\nenum StatusType {\\n DRAFT\\n CONFIRMED\\n}',\n examples: [],\n initialValue:\n '{\\n \"name\": \"\",\\n \"status\": \"DRAFT\",\\n \"allowedDocumentTypes\": null,\\n \"isDragAndDropEnabled\": true\\n}',\n },\n },\n modules: [\n {\n id: \"d274599a-ceb5-4f2b-8651-b25787306734\",\n name: \"base_operations\",\n description:\n \"Set the app's identity, lifecycle status, and the document types it handles.\",\n operations: [\n {\n id: \"f2ba2ddc-8527-4162-93bd-e045e9932013\",\n name: \"SET_APP_NAME\",\n description:\n \"Set the display name of the drive app. Also determines the generated folder name under `editors/`.\",\n schema: \"input SetAppNameInput {\\n name: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"c842efa4-154c-4fd9-9d12-42bec51af4e9\",\n name: \"SET_APP_STATUS\",\n description:\n \"Move the app between DRAFT and CONFIRMED. Codegen only runs once the status is CONFIRMED.\",\n schema: \"input SetAppStatusInput {\\n status: StatusType!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"7376f168-695f-4aef-94d0-6e381666358c\",\n name: \"ADD_DOCUMENT_TYPE\",\n description:\n \"Append a document type id to the list of types this app handles. The first type added narrows the app from every type to the listed ones.\",\n schema:\n \"input AddDocumentTypeInput {\\n documentType: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"310e4e5b-3f14-4e9a-8e09-5583c7698a65\",\n name: \"REMOVE_DOCUMENT_TYPE\",\n description:\n \"Remove a document type id from the handled list. No-op if the type is not present. Removing the last type leaves an empty list, which accepts every type.\",\n schema:\n \"input RemoveDocumentTypeInput {\\n documentType: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"b365727a-7df3-48f0-a4f8-02362f02ad1d\",\n name: \"SET_DOCUMENT_TYPES\",\n description:\n \"Replace the entire allowed-document-types list in one call. An empty list accepts every document type.\",\n schema:\n \"input SetDocumentTypesInput {\\n documentTypes: [String!]!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n ],\n },\n {\n id: \"270faa10-92e9-40d0-b128-2de32704bcb5\",\n name: \"dnd_operations\",\n description:\n \"Toggle drag-and-drop file handling for the app surface.\",\n operations: [\n {\n id: \"077b1ab8-cb32-4b4e-a1fa-76178188c6a1\",\n name: \"SET_DRAG_AND_DROP_ENABLED\",\n description:\n \"Enable or disable drag-and-drop file handling on the app surface.\",\n schema:\n \"input SetDragAndDropEnabledInput {\\n enabled: Boolean!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n ],\n },\n ],\n version: 1,\n changeLog: [],\n },\n ],\n};\n","export {};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { DocumentModelUtils } from \"document-model\";\nimport type { AppModulePHState } from \"./gen/types.js\";\nimport { utils as genUtils } from \"./gen/utils.js\";\nimport * as customUtils from \"./src/utils.js\";\n\n/** Utils for the AppModule document model */\nexport const utils: DocumentModelUtils<AppModulePHState> = {\n ...genUtils,\n ...customUtils,\n};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { DocumentModelModule } from \"document-model\";\nimport { createState, defaultBaseState } from \"document-model\";\nimport { actions } from \"./actions.js\";\nimport { documentModel } from \"./gen/document-model.js\";\nimport { reducer } from \"./gen/reducer.js\";\nimport type { AppModulePHState } from \"./gen/types.js\";\nimport { utils } from \"./utils.js\";\n\n/** Document model module for the AppModule document type */\nexport const AppModule = {\n version: 1,\n reducer,\n actions,\n utils,\n documentModel: createState(defaultBaseState(), documentModel),\n} as const satisfies DocumentModelModule<AppModulePHState>;\n"],"mappings":";;;;AAEA,MAAa,gBAA0C;CACrD,IAAI;CACJ,MAAM;CACN,QAAQ;EACN,MAAM;EACN,SAAS;CACX;CACA,WAAW;CACX,aACE;CACF,gBAAgB,CACd;EACE,OAAO;GACL,OAAO;IACL,QAAQ;IACR,UAAU,CAAC;IACX,cAAc;GAChB;GACA,QAAQ;IACN,QACE;IACF,UAAU,CAAC;IACX,cACE;GACJ;EACF;EACA,SAAS,CACP;GACE,IAAI;GACJ,MAAM;GACN,aACE;GACF,YAAY;IACV;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QAAQ;KACR,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QAAQ;KACR,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QACE;KACF,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QACE;KACF,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QACE;KACF,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;GACF;EACF,GACA;GACE,IAAI;GACJ,MAAM;GACN,aACE;GACF,YAAY,CACV;IACE,IAAI;IACJ,MAAM;IACN,aACE;IACF,QACE;IACF,UAAU;IACV,SAAS;IACT,QAAQ,CAAC;IACT,UAAU,CAAC;IACX,OAAO;GACT,CACF;EACF,CACF;EACA,SAAS;EACT,WAAW,CAAC;CACd,CACF;AACF;;;;;;;AEpHA,MAAa,QAA8C;CACzD,GAAGA;CACH,GAAGC;AACL;;;;ACAA,MAAa,YAAY;CACvB,SAAS;CACT;CACA;CACA;CACA,eAAe,YAAY,iBAAiB,GAAG,aAAa;AAC9D"}
@@ -2,7 +2,7 @@ import { lazy } from "react";
2
2
  //#region editors/app-editor/module.ts
3
3
  /** Document editor module for the "powerhouse/app" document type */
4
4
  const AppEditor = {
5
- Component: lazy(() => import("./editor-BXOEFIDj.js")),
5
+ Component: lazy(() => import("./editor-D5SIbFn_.js")),
6
6
  documentTypes: ["powerhouse/app"],
7
7
  config: {
8
8
  id: "app-editor",
@@ -13,7 +13,7 @@ const AppEditor = {
13
13
  //#region editors/document-editor/module.ts
14
14
  /** Document editor module for the "powerhouse/document-editor" document type */
15
15
  const DocumentEditorEditor = {
16
- Component: lazy(() => import("./editor-DFEeM_dy.js")),
16
+ Component: lazy(() => import("./editor-SJk7cr6k.js")),
17
17
  documentTypes: ["powerhouse/document-editor"],
18
18
  config: {
19
19
  id: "document-editor-editor",
@@ -24,7 +24,7 @@ const DocumentEditorEditor = {
24
24
  //#region editors/processor-editor/module.ts
25
25
  /** Document editor module for the "powerhouse/processor" document type */
26
26
  const ProcessorModuleEditor = {
27
- Component: lazy(() => import("./editor-C5a0rBQj.js")),
27
+ Component: lazy(() => import("./editor-CbT_8Z6A.js")),
28
28
  documentTypes: ["powerhouse/processor"],
29
29
  config: {
30
30
  id: "processor-module-editor",
@@ -35,7 +35,7 @@ const ProcessorModuleEditor = {
35
35
  //#region editors/subgraph-editor/module.ts
36
36
  /** Document editor module for the "powerhouse/subgraph" document type */
37
37
  const SubgraphModuleEditor = {
38
- Component: lazy(() => import("./editor-CiX3Tq3g.js")),
38
+ Component: lazy(() => import("./editor-BDR7IYJG.js")),
39
39
  documentTypes: ["powerhouse/subgraph"],
40
40
  config: {
41
41
  id: "subgraph-module-editor",
@@ -45,7 +45,7 @@ const SubgraphModuleEditor = {
45
45
  //#endregion
46
46
  //#region editors/vetra-drive-app/module.ts
47
47
  const VetraDriveApp = {
48
- Component: lazy(() => import("./editor-DpadPeVq.js")),
48
+ Component: lazy(() => import("./editor-Cnk0M044.js")),
49
49
  documentTypes: ["powerhouse/document-drive"],
50
50
  config: {
51
51
  id: "vetra-drive-app",
@@ -56,7 +56,7 @@ const VetraDriveApp = {
56
56
  //#region editors/vetra-package/module.ts
57
57
  /** Document editor module for the "powerhouse/package" document type */
58
58
  const VetraPackageEditor = {
59
- Component: lazy(() => import("./editor-DpZVlVN1.js")),
59
+ Component: lazy(() => import("./editor-CnfajXGg.js")),
60
60
  documentTypes: ["powerhouse/package"],
61
61
  config: {
62
62
  id: "vetra-package-editor",
@@ -66,4 +66,4 @@ const VetraPackageEditor = {
66
66
  //#endregion
67
67
  export { DocumentEditorEditor as a, ProcessorModuleEditor as i, VetraDriveApp as n, AppEditor as o, SubgraphModuleEditor as r, VetraPackageEditor as t };
68
68
 
69
- //# sourceMappingURL=module-CdpGkPNN.js.map
69
+ //# sourceMappingURL=module-B6S4QGOx.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"module-B6S4QGOx.js","names":[],"sources":["../editors/app-editor/module.ts","../editors/document-editor/module.ts","../editors/processor-editor/module.ts","../editors/subgraph-editor/module.ts","../editors/vetra-drive-app/module.ts","../editors/vetra-package/module.ts"],"sourcesContent":["/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { EditorModule } from \"document-model\";\nimport type {\n AppModuleAction,\n AppModuleDocument,\n} from \"../../document-models/app-module/index.js\";\nimport { lazy } from \"react\";\n\n/** Document editor module for the \"powerhouse/app\" document type */\nexport const AppEditor: EditorModule<AppModuleDocument, AppModuleAction> = {\n Component: lazy(() => import(\"./editor.js\")),\n documentTypes: [\"powerhouse/app\"],\n config: {\n id: \"app-editor\",\n name: \"AppEditor\",\n },\n};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { EditorModule } from \"document-model\";\nimport type {\n DocumentEditorAction,\n DocumentEditorDocument,\n} from \"../../document-models/document-editor/index.js\";\nimport { lazy } from \"react\";\n\n/** Document editor module for the \"powerhouse/document-editor\" document type */\nexport const DocumentEditorEditor: EditorModule<\n DocumentEditorDocument,\n DocumentEditorAction\n> = {\n Component: lazy(() => import(\"./editor.js\")),\n documentTypes: [\"powerhouse/document-editor\"],\n config: {\n id: \"document-editor-editor\",\n name: \"Document Editor Editor\",\n },\n};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { EditorModule } from \"document-model\";\nimport type {\n ProcessorModuleAction,\n ProcessorModuleDocument,\n} from \"../../document-models/processor-module/index.js\";\nimport { lazy } from \"react\";\n\n/** Document editor module for the \"powerhouse/processor\" document type */\nexport const ProcessorModuleEditor: EditorModule<\n ProcessorModuleDocument,\n ProcessorModuleAction\n> = {\n Component: lazy(() => import(\"./editor.js\")),\n documentTypes: [\"powerhouse/processor\"],\n config: {\n id: \"processor-module-editor\",\n name: \"Processor Module Editor\",\n },\n};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { EditorModule } from \"document-model\";\nimport type {\n SubgraphModuleAction,\n SubgraphModuleDocument,\n} from \"../../document-models/subgraph-module/index.js\";\nimport { lazy } from \"react\";\n\n/** Document editor module for the \"powerhouse/subgraph\" document type */\nexport const SubgraphModuleEditor: EditorModule<\n SubgraphModuleDocument,\n SubgraphModuleAction\n> = {\n Component: lazy(() => import(\"./editor.js\")),\n documentTypes: [\"powerhouse/subgraph\"],\n config: {\n id: \"subgraph-module-editor\",\n name: \"Subgraph Module Editor\",\n },\n};\n","import type {\n DocumentDriveAction,\n DocumentDriveDocument,\n} from \"@powerhousedao/shared/document-drive\";\nimport type { EditorModule } from \"@powerhousedao/shared/document-model\";\nimport { lazy } from \"react\";\n\nexport const VetraDriveApp: EditorModule<\n DocumentDriveDocument,\n DocumentDriveAction\n> = {\n Component: lazy(() => import(\"./editor.js\")),\n documentTypes: [\"powerhouse/document-drive\"],\n config: {\n id: \"vetra-drive-app\",\n name: \"Vetra Drive App\",\n },\n};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { EditorModule } from \"document-model\";\nimport type {\n VetraPackageAction,\n VetraPackageDocument,\n} from \"../../document-models/vetra-package/index.js\";\nimport { lazy } from \"react\";\n\n/** Document editor module for the \"powerhouse/package\" document type */\nexport const VetraPackageEditor: EditorModule<\n VetraPackageDocument,\n VetraPackageAction\n> = {\n Component: lazy(() => import(\"./editor.js\")),\n documentTypes: [\"powerhouse/package\"],\n config: {\n id: \"vetra-package-editor\",\n name: \"Vetra Package Editor\",\n },\n};\n"],"mappings":";;;AAYA,MAAa,YAA8D;CACzE,WAAW,WAAW,OAAO,uBAAc;CAC3C,eAAe,CAAC,gBAAgB;CAChC,QAAQ;EACN,IAAI;EACJ,MAAM;CACR;AACF;;;;ACPA,MAAa,uBAGT;CACF,WAAW,WAAW,OAAO,uBAAc;CAC3C,eAAe,CAAC,4BAA4B;CAC5C,QAAQ;EACN,IAAI;EACJ,MAAM;CACR;AACF;;;;ACVA,MAAa,wBAGT;CACF,WAAW,WAAW,OAAO,uBAAc;CAC3C,eAAe,CAAC,sBAAsB;CACtC,QAAQ;EACN,IAAI;EACJ,MAAM;CACR;AACF;;;;ACVA,MAAa,uBAGT;CACF,WAAW,WAAW,OAAO,uBAAc;CAC3C,eAAe,CAAC,qBAAqB;CACrC,QAAQ;EACN,IAAI;EACJ,MAAM;CACR;AACF;;;ACfA,MAAa,gBAGT;CACF,WAAW,WAAW,OAAO,uBAAc;CAC3C,eAAe,CAAC,2BAA2B;CAC3C,QAAQ;EACN,IAAI;EACJ,MAAM;CACR;AACF;;;;ACLA,MAAa,qBAGT;CACF,WAAW,WAAW,OAAO,uBAAc;CAC3C,eAAe,CAAC,oBAAoB;CACpC,QAAQ;EACN,IAAI;EACJ,MAAM;CACR;AACF"}
@@ -1,5 +1,4 @@
1
- import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
2
- import { f as reducer, p as actions, r as utils$1 } from "./utils-w_21RRK6.js";
1
+ import { f as reducer, g as actions, h as utils_exports, r as utils$1 } from "./utils-BJk4_43W.js";
3
2
  import { createState, defaultBaseState } from "document-model";
4
3
  //#region document-models/processor-module/v1/gen/document-model.ts
5
4
  const documentModel = {
@@ -19,7 +18,7 @@ const documentModel = {
19
18
  initialValue: ""
20
19
  },
21
20
  global: {
22
- schema: "\"\"\"\nConfiguration for a processor contributed by the package. A processor receives\noperations from documents of matching types and runs server-side logic (e.g.\nbuilding a read model, indexing, syncing to an external system).\n\"\"\"\ntype ProcessorModuleState {\n \"\"\"Display name of the processor. Also determines the generated folder name under `processors/`.\"\"\"\n name: String!\n \"\"\"Processor implementation kind (e.g. 'read-model', 'relational-db'). Determines which scaffold codegen emits.\"\"\"\n type: String!\n \"\"\"Document types this processor subscribes to. Each entry has a stable id so it can be removed individually.\"\"\"\n documentTypes: [DocumentTypeItem!]!\n \"\"\"Lifecycle status. While DRAFT the processor definition is editable and codegen is skipped; switching to CONFIRMED triggers scaffold generation.\"\"\"\n status: StatusType!\n \"\"\"Drive-app names this processor is attached to. The processor runs in the context of each listed app.\"\"\"\n processorApps: [String!]!\n}\n\n\"\"\"A document type id (e.g. 'my-org/invoice') attached to the processor with a stable entry id.\"\"\"\ntype DocumentTypeItem {\n \"\"\"Stable identifier for the entry; used to remove it.\"\"\"\n id: OID!\n \"\"\"Document type id this processor subscribes to.\"\"\"\n documentType: String!\n}\n\n\"\"\"\nLifecycle status of a module definition.\n- DRAFT: still being edited; codegen does not run.\n- CONFIRMED: locked in; codegen produces the corresponding scaffold.\n\"\"\"\nenum StatusType {\n DRAFT\n CONFIRMED\n}",
21
+ schema: "\"\"\"\nConfiguration for a processor contributed by the package. A processor receives\noperations from documents of matching types and runs server-side logic (e.g.\nbuilding a read model, indexing, syncing to an external system).\n\"\"\"\ntype ProcessorModuleState {\n \"\"\"Display name of the processor. Also determines the generated folder name under `processors/`.\"\"\"\n name: String!\n \"\"\"Processor implementation kind: `analytics` or `relational`. Determines which scaffold codegen emits; codegen generates nothing for any other value.\"\"\"\n type: String!\n \"\"\"Document types this processor subscribes to. Each entry has a stable id so it can be removed individually.\"\"\"\n documentTypes: [DocumentTypeItem!]!\n \"\"\"Lifecycle status. While DRAFT the processor definition is editable and codegen is skipped; switching to CONFIRMED triggers scaffold generation.\"\"\"\n status: StatusType!\n \"\"\"Drive-app names this processor is attached to. The processor runs in the context of each listed app.\"\"\"\n processorApps: [String!]!\n}\n\n\"\"\"A document type id (e.g. 'my-org/invoice') attached to the processor with a stable entry id.\"\"\"\ntype DocumentTypeItem {\n \"\"\"Stable identifier for the entry; used to remove it.\"\"\"\n id: OID!\n \"\"\"Document type id this processor subscribes to.\"\"\"\n documentType: String!\n}\n\n\"\"\"\nLifecycle status of a module definition.\n- DRAFT: still being edited; codegen does not run.\n- CONFIRMED: locked in; codegen produces the corresponding scaffold.\n\"\"\"\nenum StatusType {\n DRAFT\n CONFIRMED\n}",
23
22
  examples: [],
24
23
  initialValue: "{\n \"name\": \"\",\n \"type\": \"\",\n \"documentTypes\": [],\n \"status\": \"DRAFT\",\n \"processorApps\": []\n}"
25
24
  }
@@ -43,11 +42,17 @@ const documentModel = {
43
42
  {
44
43
  id: "b8f28bb4-c6ae-40e6-86fa-29ef14ff8667",
45
44
  name: "SET_PROCESSOR_TYPE",
46
- description: "Set the processor implementation kind (e.g. 'read-model', 'relational-db'). Determines which scaffold codegen emits.",
45
+ description: "Set the processor implementation kind: `analytics` or `relational`. Determines which scaffold codegen emits. Any other value is rejected with UnsupportedProcessorTypeError.",
47
46
  schema: "input SetProcessorTypeInput {\n type: String!\n}",
48
47
  template: "",
49
48
  reducer: "",
50
- errors: [],
49
+ errors: [{
50
+ id: "ac9b9586-e2d5-4676-8c06-22890adcc2fd",
51
+ name: "UnsupportedProcessorTypeError",
52
+ code: "UNSUPPORTED_PROCESSOR_TYPE",
53
+ description: "The processor type is not `analytics` or `relational`, the kinds codegen can generate.",
54
+ template: ""
55
+ }],
51
56
  examples: [],
52
57
  scope: "global"
53
58
  },
@@ -113,9 +118,6 @@ const documentModel = {
113
118
  }]
114
119
  };
115
120
  //#endregion
116
- //#region document-models/processor-module/v1/src/utils.ts
117
- var utils_exports = /* @__PURE__ */ __exportAll({});
118
- //#endregion
119
121
  //#region document-models/processor-module/v1/utils.ts
120
122
  /** Utils for the ProcessorModule document model */
121
123
  const utils = {
@@ -135,4 +137,4 @@ const ProcessorModule = {
135
137
  //#endregion
136
138
  export { utils as n, documentModel as r, ProcessorModule as t };
137
139
 
138
- //# sourceMappingURL=module-Db8mmgzN.js.map
140
+ //# sourceMappingURL=module-BktWa0rB.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"module-BktWa0rB.js","names":["genUtils","customUtils"],"sources":["../document-models/processor-module/v1/gen/document-model.ts","../document-models/processor-module/v1/utils.ts","../document-models/processor-module/v1/module.ts"],"sourcesContent":["import type { DocumentModelGlobalState } from \"document-model\";\n\nexport const documentModel: DocumentModelGlobalState = {\n id: \"powerhouse/processor\",\n name: \"Processor Module\",\n author: {\n name: \"Powerhouse\",\n website: \"https://powerhouse.inc\",\n },\n extension: \".processor\",\n description:\n \"Declares a processor (a server-side function that reacts to document operations to build read models, send notifications, sync to external systems, etc.) shipped by a Vetra Reactor Package. Create one Processor Module document per processor: pick the processor type, list the document types it subscribes to, attach it to any drive apps that should run it, and mark it CONFIRMED to trigger codegen of the processor scaffold under `processors/`.\",\n specifications: [\n {\n state: {\n local: {\n schema: \"\",\n examples: [],\n initialValue: \"\",\n },\n global: {\n schema:\n '\"\"\"\\nConfiguration for a processor contributed by the package. A processor receives\\noperations from documents of matching types and runs server-side logic (e.g.\\nbuilding a read model, indexing, syncing to an external system).\\n\"\"\"\\ntype ProcessorModuleState {\\n \"\"\"Display name of the processor. Also determines the generated folder name under `processors/`.\"\"\"\\n name: String!\\n \"\"\"Processor implementation kind: `analytics` or `relational`. Determines which scaffold codegen emits; codegen generates nothing for any other value.\"\"\"\\n type: String!\\n \"\"\"Document types this processor subscribes to. Each entry has a stable id so it can be removed individually.\"\"\"\\n documentTypes: [DocumentTypeItem!]!\\n \"\"\"Lifecycle status. While DRAFT the processor definition is editable and codegen is skipped; switching to CONFIRMED triggers scaffold generation.\"\"\"\\n status: StatusType!\\n \"\"\"Drive-app names this processor is attached to. The processor runs in the context of each listed app.\"\"\"\\n processorApps: [String!]!\\n}\\n\\n\"\"\"A document type id (e.g. \\'my-org/invoice\\') attached to the processor with a stable entry id.\"\"\"\\ntype DocumentTypeItem {\\n \"\"\"Stable identifier for the entry; used to remove it.\"\"\"\\n id: OID!\\n \"\"\"Document type id this processor subscribes to.\"\"\"\\n documentType: String!\\n}\\n\\n\"\"\"\\nLifecycle status of a module definition.\\n- DRAFT: still being edited; codegen does not run.\\n- CONFIRMED: locked in; codegen produces the corresponding scaffold.\\n\"\"\"\\nenum StatusType {\\n DRAFT\\n CONFIRMED\\n}',\n examples: [],\n initialValue:\n '{\\n \"name\": \"\",\\n \"type\": \"\",\\n \"documentTypes\": [],\\n \"status\": \"DRAFT\",\\n \"processorApps\": []\\n}',\n },\n },\n modules: [\n {\n id: \"91ad39c1-4e8b-4127-b3c8-e835b85e6360\",\n name: \"base_operations\",\n description:\n \"Set the processor's identity, kind, lifecycle status, subscribed document types, and attached drive apps.\",\n operations: [\n {\n id: \"6f3a5c90-39f2-4302-a073-6195a71c5054\",\n name: \"SET_PROCESSOR_NAME\",\n description:\n \"Set the display name of the processor. Also determines the generated folder name under `processors/`.\",\n schema: \"input SetProcessorNameInput {\\n name: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"b8f28bb4-c6ae-40e6-86fa-29ef14ff8667\",\n name: \"SET_PROCESSOR_TYPE\",\n description:\n \"Set the processor implementation kind: `analytics` or `relational`. Determines which scaffold codegen emits. Any other value is rejected with UnsupportedProcessorTypeError.\",\n schema: \"input SetProcessorTypeInput {\\n type: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [\n {\n id: \"ac9b9586-e2d5-4676-8c06-22890adcc2fd\",\n name: \"UnsupportedProcessorTypeError\",\n code: \"UNSUPPORTED_PROCESSOR_TYPE\",\n description:\n \"The processor type is not `analytics` or `relational`, the kinds codegen can generate.\",\n template: \"\",\n },\n ],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"fbbd7a71-c495-4efc-b8f6-1e57798dbbb4\",\n name: \"ADD_DOCUMENT_TYPE\",\n description:\n \"Subscribe the processor to a document type. Caller supplies a stable id so the entry can be removed later.\",\n schema:\n \"input AddDocumentTypeInput {\\n id: OID!\\n documentType: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"544d413f-423c-4d97-9570-84a19bffeab9\",\n name: \"REMOVE_DOCUMENT_TYPE\",\n description:\n \"Unsubscribe the processor from a document type by removing its entry id.\",\n schema: \"input RemoveDocumentTypeInput {\\n id: OID!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"df5eb500-7308-498c-9b80-028878ee198b\",\n name: \"ADD_PROCESSOR_APP\",\n description:\n \"Attach the processor to a drive app by name. The processor will run in the context of that app.\",\n schema:\n \"input AddProcessorAppInput {\\n processorApp: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"07e4168f-1a7b-41ef-953d-219028be7bb9\",\n name: \"REMOVE_PROCESSOR_APP\",\n description:\n \"Detach the processor from a drive app by name. No-op if the app is not currently attached.\",\n schema:\n \"input RemoveProcessorAppInput {\\n processorApp: String!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n {\n id: \"7b6706eb-5e25-4d64-829a-e3a251380fd1\",\n name: \"SET_PROCESSOR_STATUS\",\n description:\n \"Move the processor between DRAFT and CONFIRMED. Codegen only runs once the status is CONFIRMED.\",\n schema:\n \"input SetProcessorStatusInput {\\n status: StatusType!\\n}\",\n template: \"\",\n reducer: \"\",\n errors: [],\n examples: [],\n scope: \"global\",\n },\n ],\n },\n ],\n version: 1,\n changeLog: [],\n },\n ],\n};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { DocumentModelUtils } from \"document-model\";\nimport type { ProcessorModulePHState } from \"./gen/types.js\";\nimport { utils as genUtils } from \"./gen/utils.js\";\nimport * as customUtils from \"./src/utils.js\";\n\n/** Utils for the ProcessorModule document model */\nexport const utils: DocumentModelUtils<ProcessorModulePHState> = {\n ...genUtils,\n ...customUtils,\n};\n","/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n */\nimport type { DocumentModelModule } from \"document-model\";\nimport { createState, defaultBaseState } from \"document-model\";\nimport { actions } from \"./actions.js\";\nimport { documentModel } from \"./gen/document-model.js\";\nimport { reducer } from \"./gen/reducer.js\";\nimport type { ProcessorModulePHState } from \"./gen/types.js\";\nimport { utils } from \"./utils.js\";\n\n/** Document model module for the ProcessorModule document type */\nexport const ProcessorModule = {\n version: 1,\n reducer,\n actions,\n utils,\n documentModel: createState(defaultBaseState(), documentModel),\n} as const satisfies DocumentModelModule<ProcessorModulePHState>;\n"],"mappings":";;;AAEA,MAAa,gBAA0C;CACrD,IAAI;CACJ,MAAM;CACN,QAAQ;EACN,MAAM;EACN,SAAS;CACX;CACA,WAAW;CACX,aACE;CACF,gBAAgB,CACd;EACE,OAAO;GACL,OAAO;IACL,QAAQ;IACR,UAAU,CAAC;IACX,cAAc;GAChB;GACA,QAAQ;IACN,QACE;IACF,UAAU,CAAC;IACX,cACE;GACJ;EACF;EACA,SAAS,CACP;GACE,IAAI;GACJ,MAAM;GACN,aACE;GACF,YAAY;IACV;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QAAQ;KACR,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QAAQ;KACR,UAAU;KACV,SAAS;KACT,QAAQ,CACN;MACE,IAAI;MACJ,MAAM;MACN,MAAM;MACN,aACE;MACF,UAAU;KACZ,CACF;KACA,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QACE;KACF,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QAAQ;KACR,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QACE;KACF,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QACE;KACF,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;IACA;KACE,IAAI;KACJ,MAAM;KACN,aACE;KACF,QACE;KACF,UAAU;KACV,SAAS;KACT,QAAQ,CAAC;KACT,UAAU,CAAC;KACX,OAAO;IACT;GACF;EACF,CACF;EACA,SAAS;EACT,WAAW,CAAC;CACd,CACF;AACF;;;;ACjIA,MAAa,QAAoD;CAC/D,GAAGA;CACH,GAAGC;AACL;;;;ACAA,MAAa,kBAAkB;CAC7B,SAAS;CACT;CACA;CACA;CACA,eAAe,YAAY,iBAAiB,GAAG,aAAa;AAC9D"}
@@ -422,6 +422,7 @@ declare const VetraPackage: {
422
422
  readonly actions: {
423
423
  setName: typeof import("document-model").setName;
424
424
  setPreferredEditor: typeof import("document-model").setPreferredEditor;
425
+ setSlug: typeof import("document-model").setSlug;
425
426
  undo: typeof import("document-model").undo;
426
427
  redo: typeof import("document-model").redo;
427
428
  noop: typeof import("document-model").noop;
@@ -442,4 +443,4 @@ declare const VetraPackage: {
442
443
  //#endregion
443
444
  export { VetraPackagePHState as $, VetraPackageDocumentHeaderSchema as A, SetPackageNameAction as At, removePackageKeyword as B, isDefinedNonNullAny as C, RemovePackageKeywordAction as Ct, defaultGlobalState as D, SetPackageCategoryAction as Dt, createVetraPackageDocument as E, SetPackageAuthorWebsiteAction as Et, isVetraPackageDocument as F, setPackageDescription as G, setPackageAuthorName as H, isVetraPackageState as I, setPackageNpmUrl as J, setPackageGithubUrl as K, documentModel as L, VetraPackagePHStateSchema as M, VetraPackageBaseOperationsAction as Mt, assertIsVetraPackageDocument as N, defaultLocalState as O, SetPackageDescriptionAction as Ot, assertIsVetraPackageState as P, VetraPackageLocalState as Q, addPackageKeyword as R, definedNonNullAnySchema as S, AddPackageKeywordAction as St, createState$1 as T, SetPackageAuthorNameAction as Tt, setPackageAuthorWebsite as U, setPackageAuthor as V, setPackageCategory as W, VetraPackageBaseOperationsOperations as X, VetraPackageController as Y, VetraPackageDocument as Z, SetPackageDescriptionInputSchema as _, SetPackageGithubUrlInput as _t, useVetraPackageDocumentsInSelectedDrive as a, Keyword as at, SetPackageNpmUrlInputSchema as b, VetraPackageState as bt, initialLocalState as c, MakeOptional as ct, KeywordSchema as d, Scalars as dt, AddPackageKeywordInput as et, RemovePackageKeywordInputSchema as f, SetPackageAuthorInput as ft, SetPackageCategoryInputSchema as g, SetPackageDescriptionInput as gt, SetPackageAuthorWebsiteInputSchema as h, SetPackageCategoryInput as ht, useVetraPackageDocumentById as i, InputMaybe as it, VetraPackageDocumentSchema as j, SetPackageNpmUrlAction as jt, defaultPHState as k, SetPackageGithubUrlAction as kt, AddPackageKeywordInputSchema as l, Maybe as lt, SetPackageAuthorNameInputSchema as m, SetPackageAuthorWebsiteInput as mt, utils as n, Exact as nt, useVetraPackageDocumentsInSelectedFolder as o, MakeEmpty as ot, SetPackageAuthorInputSchema as p, SetPackageAuthorNameInput as pt, setPackageName as q, useSelectedVetraPackageDocument as r, Incremental as rt, initialGlobalState as s, MakeMaybe as st, VetraPackage as t, Author as tt, AuthorSchema as u, RemovePackageKeywordInput as ut, SetPackageGithubUrlInputSchema as v, SetPackageNameInput as vt, reducer as w, SetPackageAuthorAction as wt, VetraPackageStateSchema as x, VetraPackageAction as xt, SetPackageNameInputSchema as y, SetPackageNpmUrlInput as yt, creators_d_exports as z };
444
445
  export {};
445
- //# sourceMappingURL=module-D4lqkHHK.d.ts.map
446
+ //# sourceMappingURL=module-C-jL7yqs.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"module-D4lqkHHK.d.ts","names":[],"sources":["../document-models/vetra-package/v1/gen/base-operations/actions.ts","../document-models/vetra-package/v1/gen/actions.ts","../document-models/vetra-package/v1/gen/schema/types.ts","../document-models/vetra-package/v1/gen/types.ts","../document-models/vetra-package/v1/gen/base-operations/operations.ts","../document-models/vetra-package/v1/gen/controller.ts","../document-models/vetra-package/v1/gen/base-operations/creators.ts","../document-models/vetra-package/v1/gen/document-model.ts","../document-models/vetra-package/v1/gen/document-schema.ts","../document-models/vetra-package/v1/gen/ph-factories.ts","../document-models/vetra-package/v1/gen/reducer.ts","../document-models/vetra-package/v1/gen/schema/zod.ts","../document-models/vetra-package/v1/gen/utils.ts","../document-models/vetra-package/v1/hooks.ts","../document-models/vetra-package/v1/utils.ts","../document-models/vetra-package/v1/module.ts"],"mappings":";;;;;KAkBY,uBAAuB;EACjC;EACA,OAAO;;KAEG,8BAA8B;EACxC;EACA,OAAO;;KAEG,2BAA2B;EACrC;EACA,OAAO;;KAEG,yBAAyB;EACnC;EACA,OAAO;;KAEG,6BAA6B;EACvC;EACA,OAAO;;KAEG,gCAAgC;EAC1C;EACA,OAAO;;KAEG,0BAA0B;EACpC;EACA,OAAO;;KAEG,6BAA6B;EACvC;EACA,OAAO;;KAEG,4BAA4B;EACtC;EACA,OAAO;;KAEG,yBAAyB;EACnC;EACA,OAAO;;KAGG,mCACR,uBACA,8BACA,2BACA,yBACA,6BACA,gCACA,0BACA,6BACA,4BACA;;;KC7DQ,qBAAqB;;;KCRrB,MAAM,KAAK;KACX,WAAW,KAAK;KAChB,MAAM;GAAa;QAC5B,WAAW,IAAI,EAAE;KAER,aAAa,GAAG,gBAAgB,KAAK,KAAK,GAAG,QACtD,UAAU,KAAK,MAAM,EAAE;KAEd,UAAU,GAAG,gBAAgB,KAAK,KAAK,GAAG,QACnD,UAAU,IAAI,MAAM,EAAE;KAEb,UACV;GAAa;GACb,gBAAgB,QACX,KAAK;KACA,YAAY,KACpB,OAEG,WAAW,KAAK,4CAA4C,EAAE;;KAGzD;EACV;IAAM;IAAe;;EACrB;IAAU;IAAe;;EACzB;IAAW;IAAgB;;EAC3B;IAAO;IAAe;;EACtB;IAAS;IAAe;;EACxB;IAAW;IAAgC;;EAC3C;IACE;MAAS;MAAe;;IACxB;MAAU;MAAe;;;EAE3B;IACE;MAAS;MAAc;;IACvB;MAAU;MAAc;;;EAE1B;IACE;MAAS;MAAc;;IACvB;MAAU;MAAc;;;EAE1B;IACE;MAAS;MAAc;;IACvB;MAAU;MAAc;;;EAE1B;IAA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AAE,UAAU,WAAW;iBAQxC,mCAAmC,IAAE,UACnD,WAAW;iBAOG,+BAA+B,IAAE,UAC/C,WAAW;iBAQG,mCAAmC,IAAE,UACnD,WAAW;iBAOG,sCAAsC,IAAE,UACtD,WAAW;iBAOG,iCAAiC,IAAE,UACjD,WAAW;iBAOG,oCAAoC,IAAE,UACpD,WAAW;iBAOG,kCAAkC,IAAE,UAClD,WAAW;iBAOG,6BAA6B,IAAE,UAC7C,WAAW;iBAOG,+BAA+B,IAAE,UAC/C,WAAW;iBAOG,2BAA2B,IAAE,UAC3C,WAAW;;;cC1GA,oBAAoB;cAYpB,mBAAmB;;;;iBChBhB,4BACd,yCAEG,sBAAsB,iBAAiB;;iBAQ5B,oCACd,sBACA,iBAAiB;;iBASH,2CAAuC;;iBAMvC,4CAAwC;;;;cCvC3C,OAAO,mBAAmB;;;;cCG1B;WACF"}
1
+ {"version":3,"file":"module-C-jL7yqs.d.ts","names":[],"sources":["../document-models/vetra-package/v1/gen/base-operations/actions.ts","../document-models/vetra-package/v1/gen/actions.ts","../document-models/vetra-package/v1/gen/schema/types.ts","../document-models/vetra-package/v1/gen/types.ts","../document-models/vetra-package/v1/gen/base-operations/operations.ts","../document-models/vetra-package/v1/gen/controller.ts","../document-models/vetra-package/v1/gen/base-operations/creators.ts","../document-models/vetra-package/v1/gen/document-model.ts","../document-models/vetra-package/v1/gen/document-schema.ts","../document-models/vetra-package/v1/gen/ph-factories.ts","../document-models/vetra-package/v1/gen/reducer.ts","../document-models/vetra-package/v1/gen/schema/zod.ts","../document-models/vetra-package/v1/gen/utils.ts","../document-models/vetra-package/v1/hooks.ts","../document-models/vetra-package/v1/utils.ts","../document-models/vetra-package/v1/module.ts"],"mappings":";;;;;KAkBY,uBAAuB;EACjC;EACA,OAAO;;KAEG,8BAA8B;EACxC;EACA,OAAO;;KAEG,2BAA2B;EACrC;EACA,OAAO;;KAEG,yBAAyB;EACnC;EACA,OAAO;;KAEG,6BAA6B;EACvC;EACA,OAAO;;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AE,UAC3C,WAAW;;;cC1GA,oBAAoB;cAYpB,mBAAmB;;;;iBChBhB,4BACd,yCAEG,sBAAsB,iBAAiB;;iBAQ5B,oCACd,sBACA,iBAAiB;;iBASH,2CAAuC;;iBAMvC,4CAAwC;;;;cCvC3C,OAAO,mBAAmB;;;;cCG1B;WACF"}
@@ -1,4 +1,4 @@
1
- import { r as utils } from "./utils-w_21RRK6.js";
1
+ import { r as utils } from "./utils-BJk4_43W.js";
2
2
  import { createBaseState, defaultBaseState } from "document-model";
3
3
  //#region document-models/processor-module/v1/gen/ph-factories.ts
4
4
  function defaultGlobalState() {
@@ -50,4 +50,4 @@ function createProcessorModuleDocument(state) {
50
50
  //#endregion
51
51
  export { defaultPHState as a, defaultLocalState as i, createState$1 as n, defaultGlobalState as r, createProcessorModuleDocument as t };
52
52
 
53
- //# sourceMappingURL=ph-factories-HuC7_vvF.js.map
53
+ //# sourceMappingURL=ph-factories-fEke-Nr8.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ph-factories-HuC7_vvF.js","names":["createState"],"sources":["../document-models/processor-module/v1/gen/ph-factories.ts"],"sourcesContent":["/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n * Factory methods for creating ProcessorModuleDocument instances\n */\nimport type { PHAuthState, PHBaseState, PHDocumentState } from \"document-model\";\nimport { createBaseState, defaultBaseState } from \"document-model\";\nimport type {\n ProcessorModuleDocument,\n ProcessorModuleGlobalState,\n ProcessorModuleLocalState,\n ProcessorModulePHState,\n} from \"./types.js\";\nimport { utils } from \"./utils.js\";\n\nexport function defaultGlobalState(): ProcessorModuleGlobalState {\n return {\n name: \"\",\n type: \"\",\n documentTypes: [],\n status: \"DRAFT\",\n processorApps: [],\n };\n}\n\nexport function defaultLocalState(): ProcessorModuleLocalState {\n return {};\n}\n\nexport function defaultPHState(): ProcessorModulePHState {\n return {\n ...defaultBaseState(),\n global: defaultGlobalState(),\n local: defaultLocalState(),\n };\n}\n\nexport function createGlobalState(\n state?: Partial<ProcessorModuleGlobalState>,\n): ProcessorModuleGlobalState {\n return {\n ...defaultGlobalState(),\n ...(state || {}),\n };\n}\n\nexport function createLocalState(\n state?: Partial<ProcessorModuleLocalState>,\n): ProcessorModuleLocalState {\n return {\n ...defaultLocalState(),\n ...(state || {}),\n } as ProcessorModuleLocalState;\n}\n\nexport function createState(\n baseState?: Partial<PHBaseState>,\n globalState?: Partial<ProcessorModuleGlobalState>,\n localState?: Partial<ProcessorModuleLocalState>,\n): ProcessorModulePHState {\n return {\n ...createBaseState(baseState?.auth, baseState?.document),\n global: createGlobalState(globalState),\n local: createLocalState(localState),\n };\n}\n\n/**\n * Creates a ProcessorModuleDocument with custom global and local state\n * This properly handles the PHBaseState requirements while allowing\n * document-specific state to be set.\n */\nexport function createProcessorModuleDocument(\n state?: Partial<{\n auth?: Partial<PHAuthState>;\n document?: Partial<PHDocumentState>;\n global?: Partial<ProcessorModuleGlobalState>;\n local?: Partial<ProcessorModuleLocalState>;\n }>,\n): ProcessorModuleDocument {\n const document = utils.createDocument(\n state\n ? createState(\n createBaseState(state.auth, state.document),\n state.global,\n state.local,\n )\n : undefined,\n );\n\n return document;\n}\n"],"mappings":";;;AAeA,SAAgB,qBAAiD;CAC/D,OAAO;EACL,MAAM;EACN,MAAM;EACN,eAAe,CAAC;EAChB,QAAQ;EACR,eAAe,CAAC;CAClB;AACF;AAEA,SAAgB,oBAA+C;CAC7D,OAAO,CAAC;AACV;AAEA,SAAgB,iBAAyC;CACvD,OAAO;EACL,GAAG,iBAAiB;EACpB,QAAQ,mBAAmB;EAC3B,OAAO,kBAAkB;CAC3B;AACF;AAEA,SAAgB,kBACd,OAC4B;CAC5B,OAAO;EACL,GAAG,mBAAmB;EACtB,GAAI,SAAS,CAAC;CAChB;AACF;AAEA,SAAgB,iBACd,OAC2B;CAC3B,OAAO;EACL,GAAG,kBAAkB;EACrB,GAAI,SAAS,CAAC;CAChB;AACF;AAEA,SAAgBA,cACd,WACA,aACA,YACwB;CACxB,OAAO;EACL,GAAG,gBAAgB,WAAW,MAAM,WAAW,QAAQ;EACvD,QAAQ,kBAAkB,WAAW;EACrC,OAAO,iBAAiB,UAAU;CACpC;AACF;;;;;;AAOA,SAAgB,8BACd,OAMyB;CAWzB,OAViB,MAAM,eACrB,QACIA,cACE,gBAAgB,MAAM,MAAM,MAAM,QAAQ,GAC1C,MAAM,QACN,MAAM,KACR,IACA,KAAA,CAGQ;AAChB"}
1
+ {"version":3,"file":"ph-factories-fEke-Nr8.js","names":["createState"],"sources":["../document-models/processor-module/v1/gen/ph-factories.ts"],"sourcesContent":["/**\n * WARNING: DO NOT EDIT\n * This file is auto-generated and updated by codegen\n * Factory methods for creating ProcessorModuleDocument instances\n */\nimport type { PHAuthState, PHBaseState, PHDocumentState } from \"document-model\";\nimport { createBaseState, defaultBaseState } from \"document-model\";\nimport type {\n ProcessorModuleDocument,\n ProcessorModuleGlobalState,\n ProcessorModuleLocalState,\n ProcessorModulePHState,\n} from \"./types.js\";\nimport { utils } from \"./utils.js\";\n\nexport function defaultGlobalState(): ProcessorModuleGlobalState {\n return {\n name: \"\",\n type: \"\",\n documentTypes: [],\n status: \"DRAFT\",\n processorApps: [],\n };\n}\n\nexport function defaultLocalState(): ProcessorModuleLocalState {\n return {};\n}\n\nexport function defaultPHState(): ProcessorModulePHState {\n return {\n ...defaultBaseState(),\n global: defaultGlobalState(),\n local: defaultLocalState(),\n };\n}\n\nexport function createGlobalState(\n state?: Partial<ProcessorModuleGlobalState>,\n): ProcessorModuleGlobalState {\n return {\n ...defaultGlobalState(),\n ...(state || {}),\n };\n}\n\nexport function createLocalState(\n state?: Partial<ProcessorModuleLocalState>,\n): ProcessorModuleLocalState {\n return {\n ...defaultLocalState(),\n ...(state || {}),\n } as ProcessorModuleLocalState;\n}\n\nexport function createState(\n baseState?: Partial<PHBaseState>,\n globalState?: Partial<ProcessorModuleGlobalState>,\n localState?: Partial<ProcessorModuleLocalState>,\n): ProcessorModulePHState {\n return {\n ...createBaseState(baseState?.auth, baseState?.document),\n global: createGlobalState(globalState),\n local: createLocalState(localState),\n };\n}\n\n/**\n * Creates a ProcessorModuleDocument with custom global and local state\n * This properly handles the PHBaseState requirements while allowing\n * document-specific state to be set.\n */\nexport function createProcessorModuleDocument(\n state?: Partial<{\n auth?: Partial<PHAuthState>;\n document?: Partial<PHDocumentState>;\n global?: Partial<ProcessorModuleGlobalState>;\n local?: Partial<ProcessorModuleLocalState>;\n }>,\n): ProcessorModuleDocument {\n const document = utils.createDocument(\n state\n ? createState(\n createBaseState(state.auth, state.document),\n state.global,\n state.local,\n )\n : undefined,\n );\n\n return document;\n}\n"],"mappings":";;;AAeA,SAAgB,qBAAiD;CAC/D,OAAO;EACL,MAAM;EACN,MAAM;EACN,eAAe,CAAC;EAChB,QAAQ;EACR,eAAe,CAAC;CAClB;AACF;AAEA,SAAgB,oBAA+C;CAC7D,OAAO,CAAC;AACV;AAEA,SAAgB,iBAAyC;CACvD,OAAO;EACL,GAAG,iBAAiB;EACpB,QAAQ,mBAAmB;EAC3B,OAAO,kBAAkB;CAC3B;AACF;AAEA,SAAgB,kBACd,OAC4B;CAC5B,OAAO;EACL,GAAG,mBAAmB;EACtB,GAAI,SAAS,CAAC;CAChB;AACF;AAEA,SAAgB,iBACd,OAC2B;CAC3B,OAAO;EACL,GAAG,kBAAkB;EACrB,GAAI,SAAS,CAAC;CAChB;AACF;AAEA,SAAgBA,cACd,WACA,aACA,YACwB;CACxB,OAAO;EACL,GAAG,gBAAgB,WAAW,MAAM,WAAW,QAAQ;EACvD,QAAQ,kBAAkB,WAAW;EACrC,OAAO,iBAAiB,UAAU;CACpC;AACF;;;;;;AAOA,SAAgB,8BACd,OAMyB;CAWzB,OAViB,MAAM,eACrB,QACIA,cACE,gBAAgB,MAAM,MAAM,MAAM,QAAQ,GAC1C,MAAM,QACN,MAAM,KACR,IACA,KAAA,CAGQ;AAChB"}