@powerhousedao/ph-cli 6.2.3-dev.90 → 6.2.3-dev.91
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/authoring-mode-DWbbsuWh.mjs +23 -0
- package/dist/authoring-mode-DWbbsuWh.mjs.map +1 -0
- package/dist/{check-BdeBTBzN.mjs → check-Dmx8U75w.mjs} +4 -4
- package/dist/{check-BdeBTBzN.mjs.map → check-Dmx8U75w.mjs.map} +1 -1
- package/dist/{cli-connect-override-CY_Zf7wG.mjs → cli-connect-override-CLHLCeF5.mjs} +4 -4
- package/dist/{cli-connect-override-CY_Zf7wG.mjs.map → cli-connect-override-CLHLCeF5.mjs.map} +1 -1
- package/dist/cli.mjs +4 -4
- package/dist/{compound-BSOW40st-CWIT2x84.mjs → compound-Cv5yxdLC-DAYAbASE.mjs} +6 -5
- package/dist/compound-Cv5yxdLC-DAYAbASE.mjs.map +1 -0
- package/dist/{connect-build-6OzCZczA.mjs → connect-build-D20s-YzT.mjs} +4 -4
- package/dist/{connect-build-6OzCZczA.mjs.map → connect-build-D20s-YzT.mjs.map} +1 -1
- package/dist/{connect-config-nuwLOG8I.mjs → connect-config-CoB5ejxj.mjs} +4 -4
- package/dist/{connect-config-nuwLOG8I.mjs.map → connect-config-CoB5ejxj.mjs.map} +1 -1
- package/dist/{connect-studio-Mhhe7W5g.mjs → connect-studio-CCjF7Fo2.mjs} +3 -3
- package/dist/{connect-studio-B3amPdLj.mjs → connect-studio-DWKRk0Zc.mjs} +4 -4
- package/dist/{connect-studio-B3amPdLj.mjs.map → connect-studio-DWKRk0Zc.mjs.map} +1 -1
- package/dist/{dist-Dw0p_A5j.mjs → dist-CF0RfguD.mjs} +4 -4
- package/dist/{dist-Dw0p_A5j.mjs.map → dist-CF0RfguD.mjs.map} +1 -1
- package/dist/{explain-BS1cIzPW.mjs → explain-BD6bemOK.mjs} +5 -5
- package/dist/{explain-BS1cIzPW.mjs.map → explain-BD6bemOK.mjs.map} +1 -1
- package/dist/{export-BkYfEgBr.mjs → export-BiIRQJ7L.mjs} +4 -4
- package/dist/{export-BkYfEgBr.mjs.map → export-BiIRQJ7L.mjs.map} +1 -1
- package/dist/{generate-all-sPjxvgql.mjs → generate-all-BWpiTcED.mjs} +6 -6
- package/dist/generate-all-BWpiTcED.mjs.map +1 -0
- package/dist/generate-document-model-vzFHWp4O.mjs +114 -0
- package/dist/generate-document-model-vzFHWp4O.mjs.map +1 -0
- package/dist/{generate-editor-kTiUOmDW.mjs → generate-editor-DdoapkEK.mjs} +7 -7
- package/dist/generate-editor-DdoapkEK.mjs.map +1 -0
- package/dist/{generate-piece-C6ymlErL.mjs → generate-piece-DpFUr1ON.mjs} +4 -4
- package/dist/{generate-piece-C6ymlErL.mjs.map → generate-piece-DpFUr1ON.mjs.map} +1 -1
- package/dist/{get-version-CdS7U_Q8.mjs → get-version-CxLCsLBV.mjs} +4 -4
- package/dist/{get-version-CdS7U_Q8.mjs.map → get-version-CxLCsLBV.mjs.map} +1 -1
- package/dist/{index-BCSl7lP0.d.mts → index-CuWHsoBB.d.mts} +3 -2
- package/dist/{index-BCSl7lP0.d.mts.map → index-CuWHsoBB.d.mts.map} +1 -1
- package/dist/{mcp-DnKGQZ10.mjs → mcp-Dcr-uDkJ.mjs} +4 -4
- package/dist/{mcp-DnKGQZ10.mjs.map → mcp-Dcr-uDkJ.mjs.map} +1 -1
- package/dist/ph-cli-commands-CyyNfLq9.mjs +4 -0
- package/dist/{ph-cli-commands-DQ7kfVak.mjs → ph-cli-commands-Dc6yyVlK.mjs} +27 -15
- package/dist/ph-cli-commands-Dc6yyVlK.mjs.map +1 -0
- package/dist/{run-sugar-5TYsoc3n.mjs → run-sugar-DZjQhZb1.mjs} +4 -4
- package/dist/{run-sugar-5TYsoc3n.mjs.map → run-sugar-DZjQhZb1.mjs.map} +1 -1
- package/dist/runners/connect.d.mts +1 -1
- package/dist/runners/connect.mjs +2 -2
- package/dist/runners/switchboard.d.mts +1 -1
- package/dist/{vetra-CwhVV4_U.mjs → vetra-s0oeZqMz.mjs} +6 -6
- package/dist/{vetra-CwhVV4_U.mjs.map → vetra-s0oeZqMz.mjs.map} +1 -1
- package/package.json +15 -15
- package/dist/compound-BSOW40st-CWIT2x84.mjs.map +0 -1
- package/dist/generate-all-sPjxvgql.mjs.map +0 -1
- package/dist/generate-document-model-CiW13Vf7.mjs +0 -60
- package/dist/generate-document-model-CiW13Vf7.mjs.map +0 -1
- package/dist/generate-editor-kTiUOmDW.mjs.map +0 -1
- package/dist/ph-cli-commands-DQ7kfVak.mjs.map +0 -1
- package/dist/ph-cli-commands-oih3l80w.mjs +0 -4
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="edf3c0ce-f462-506f-a23d-a305b93c5a18")}catch(e){}}();
|
|
3
|
+
import { t as warnSubgraphTypeConflicts } from "./warn-subgraph-type-conflicts-BOHBmThq.mjs";
|
|
4
|
+
import { r as selectScaffoldGeneration, t as selectDocumentModelGeneration } from "./authoring-mode-DWbbsuWh.mjs";
|
|
5
|
+
import { t as resolveModuleDirName } from "./module-dir-1avCXsBi.mjs";
|
|
6
|
+
import { existsSync } from "node:fs";
|
|
7
|
+
import { join } from "node:path";
|
|
8
|
+
import { loadDocumentModel } from "@powerhousedao/codegen";
|
|
9
|
+
import { handleMutuallyExclusiveOptions } from "@powerhousedao/shared/clis";
|
|
10
|
+
import { readPackage } from "read-pkg";
|
|
11
|
+
import { buildTsMorphProject } from "@powerhousedao/codegen/utils";
|
|
12
|
+
import { extractDocumentModelDocuments, getDocument, saveSpec } from "@powerhousedao/vetra/codegen";
|
|
13
|
+
import { capitalCase, kebabCase } from "change-case";
|
|
14
|
+
//#region src/services/definitions/code-first-scaffold.ts
|
|
15
|
+
async function scaffoldCodeFirstDocumentModel(generation, name, projectDir, project) {
|
|
16
|
+
const modelName = name.trim();
|
|
17
|
+
if (modelName === "") throw new Error("--name needs a document model name.");
|
|
18
|
+
const namespace = await documentTypeNamespace(projectDir);
|
|
19
|
+
const documentType = `${namespace}/${kebabCase(modelName)}`;
|
|
20
|
+
const editorName = `${capitalCase(modelName)} Editor`;
|
|
21
|
+
const editorDirName = kebabCase(editorName);
|
|
22
|
+
if (existsSync(join(projectDir, "editors", editorDirName))) throw new Error(`editors/${editorDirName} already exists. Choose another --name, or move that editor first.`);
|
|
23
|
+
const result = await generation.scaffoldDocumentModel({
|
|
24
|
+
name: modelName,
|
|
25
|
+
documentType,
|
|
26
|
+
author: {
|
|
27
|
+
name: namespace,
|
|
28
|
+
website: null
|
|
29
|
+
}
|
|
30
|
+
}, project);
|
|
31
|
+
for (const path of result.written) console.log(`Wrote ${path}`);
|
|
32
|
+
console.log(result.registration === "unchanged" ? "powerhouse.config.json definitionSources already lists this model" : `Registered ${documentType} in powerhouse.config.json definitionSources (${result.registration})`);
|
|
33
|
+
await generation.generateEditor({
|
|
34
|
+
editorName,
|
|
35
|
+
documentTypes: [documentType],
|
|
36
|
+
editorId: editorDirName,
|
|
37
|
+
editorDirName
|
|
38
|
+
}, project);
|
|
39
|
+
await project.save();
|
|
40
|
+
console.log(`Generated editor "${editorName}" in editors/${editorDirName}`);
|
|
41
|
+
}
|
|
42
|
+
async function documentTypeNamespace(projectDir) {
|
|
43
|
+
const { name } = await readPackage({
|
|
44
|
+
cwd: projectDir,
|
|
45
|
+
normalize: false
|
|
46
|
+
});
|
|
47
|
+
if (!name) throw new Error("--name puts the document type under the package name. Add a name to package.json.");
|
|
48
|
+
return name.replace(/^@/, "").replaceAll("/", "-");
|
|
49
|
+
}
|
|
50
|
+
//#endregion
|
|
51
|
+
//#region src/services/generate-document-model.ts
|
|
52
|
+
async function startGenerateDocumentModel(args, projectDir) {
|
|
53
|
+
const { document, dir, all, extract, name, debug } = args;
|
|
54
|
+
if (debug) console.log({ args });
|
|
55
|
+
const project = buildTsMorphProject(projectDir);
|
|
56
|
+
if (name !== void 0) {
|
|
57
|
+
handleMutuallyExclusiveOptions({
|
|
58
|
+
"--name": name,
|
|
59
|
+
"--document": document,
|
|
60
|
+
"--dir": dir,
|
|
61
|
+
"--all": all || void 0,
|
|
62
|
+
"--extract": extract || void 0
|
|
63
|
+
}, "generation mode");
|
|
64
|
+
await scaffoldCodeFirstDocumentModel(selectScaffoldGeneration(args, projectDir), name, projectDir, project);
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
if (extract) {
|
|
68
|
+
const docs = extractDocumentModelDocuments(project);
|
|
69
|
+
for (const doc of docs) {
|
|
70
|
+
const path = await saveSpec(doc, projectDir);
|
|
71
|
+
console.log(`Wrote ${path}`);
|
|
72
|
+
}
|
|
73
|
+
return;
|
|
74
|
+
}
|
|
75
|
+
if (all) {
|
|
76
|
+
const { documentModels, unreadableDirs, codeFirstDocumentModels } = await selectDocumentModelGeneration(args, projectDir).generateAllDocumentModels(project);
|
|
77
|
+
await project.save();
|
|
78
|
+
if (documentModels.length === 0 && unreadableDirs.length === 0 && codeFirstDocumentModels.length === 0) console.log("No document models found in document-models/.");
|
|
79
|
+
for (const { name } of documentModels) console.log(`Regenerated document model "${name}"`);
|
|
80
|
+
for (const { name } of codeFirstDocumentModels) console.log(`Updated the exports of code-first document model "${name}"`);
|
|
81
|
+
for (const dirName of unreadableDirs) console.warn(`Skipped document-models/${dirName}: expected a valid document model spec at document-models/${dirName}/${dirName}.json. Kept the manifest's document models.`);
|
|
82
|
+
await warnSubgraphTypeConflicts(projectDir);
|
|
83
|
+
return;
|
|
84
|
+
} else if (document) {
|
|
85
|
+
const generation = selectDocumentModelGeneration(args, projectDir);
|
|
86
|
+
if (document.endsWith(".phd")) {
|
|
87
|
+
const doc = await getDocument(document);
|
|
88
|
+
await generation.generateDocumentModel(doc.state.global, project);
|
|
89
|
+
} else {
|
|
90
|
+
const state = await loadDocumentModel(document);
|
|
91
|
+
await generation.generateDocumentModel(state, project);
|
|
92
|
+
}
|
|
93
|
+
} else if (dir) {
|
|
94
|
+
const dirName = resolveModuleDirName(projectDir, "document-models", dir, "my-document-model");
|
|
95
|
+
const specPath = join(projectDir, "document-models", dirName, `${dirName}.json`);
|
|
96
|
+
if (!existsSync(specPath)) throw new Error(`document-models/${dirName} has no ${dirName}.json.`);
|
|
97
|
+
const state = await loadDocumentModel(specPath);
|
|
98
|
+
await selectDocumentModelGeneration(args, projectDir).generateDocumentModel(state, project);
|
|
99
|
+
await project.save();
|
|
100
|
+
console.log(`Regenerated document model "${state.name}" in document-models/${dirName}`);
|
|
101
|
+
await warnSubgraphTypeConflicts(projectDir);
|
|
102
|
+
return;
|
|
103
|
+
} else {
|
|
104
|
+
console.log("Please specify one of `document`, `dir`, `all`, or `extract`.");
|
|
105
|
+
return;
|
|
106
|
+
}
|
|
107
|
+
await project.save();
|
|
108
|
+
await warnSubgraphTypeConflicts(projectDir);
|
|
109
|
+
}
|
|
110
|
+
//#endregion
|
|
111
|
+
export { startGenerateDocumentModel };
|
|
112
|
+
|
|
113
|
+
//# sourceMappingURL=generate-document-model-vzFHWp4O.mjs.map
|
|
114
|
+
//# debugId=edf3c0ce-f462-506f-a23d-a305b93c5a18
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generate-document-model-vzFHWp4O.mjs","sources":["../src/services/definitions/code-first-scaffold.ts","../src/services/generate-document-model.ts"],"sourcesContent":["import type { CodeFirstModelGeneration } from \"@powerhousedao/codegen\";\nimport { capitalCase, kebabCase } from \"change-case\";\nimport { existsSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { readPackage } from \"read-pkg\";\nimport type { Project } from \"ts-morph\";\n\nexport async function scaffoldCodeFirstDocumentModel(\n generation: CodeFirstModelGeneration,\n name: string,\n projectDir: string,\n project: Project,\n) {\n const modelName = name.trim();\n if (modelName === \"\") {\n throw new Error(\"--name needs a document model name.\");\n }\n const namespace = await documentTypeNamespace(projectDir);\n const documentType = `${namespace}/${kebabCase(modelName)}`;\n const editorName = `${capitalCase(modelName)} Editor`;\n const editorDirName = kebabCase(editorName);\n if (existsSync(join(projectDir, \"editors\", editorDirName))) {\n throw new Error(\n `editors/${editorDirName} already exists. Choose another --name, or move that editor first.`,\n );\n }\n\n const result = await generation.scaffoldDocumentModel(\n {\n name: modelName,\n documentType,\n author: { name: namespace, website: null },\n },\n project,\n );\n for (const path of result.written) {\n console.log(`Wrote ${path}`);\n }\n console.log(\n result.registration === \"unchanged\"\n ? \"powerhouse.config.json definitionSources already lists this model\"\n : `Registered ${documentType} in powerhouse.config.json definitionSources (${result.registration})`,\n );\n\n await generation.generateEditor(\n {\n editorName,\n documentTypes: [documentType],\n editorId: editorDirName,\n editorDirName,\n },\n project,\n );\n await project.save();\n console.log(`Generated editor \"${editorName}\" in editors/${editorDirName}`);\n}\n\nasync function documentTypeNamespace(projectDir: string) {\n const { name } = await readPackage({ cwd: projectDir, normalize: false });\n if (!name) {\n throw new Error(\n \"--name puts the document type under the package name. Add a name to package.json.\",\n );\n }\n return name.replace(/^@/, \"\").replaceAll(\"/\", \"-\");\n}\n","import { loadDocumentModel } from \"@powerhousedao/codegen\";\nimport { buildTsMorphProject } from \"@powerhousedao/codegen/utils\";\nimport {\n extractDocumentModelDocuments,\n getDocument,\n saveSpec,\n} from \"@powerhousedao/vetra/codegen\";\nimport { handleMutuallyExclusiveOptions } from \"@powerhousedao/shared/clis\";\nimport type { DocumentModelDocument } from \"@powerhousedao/shared/document-model\";\nimport { existsSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport type { GenerateDocumentModelArgs } from \"../types.js\";\nimport { resolveModuleDirName } from \"../utils/module-dir.js\";\nimport { warnSubgraphTypeConflicts } from \"../utils/warn-subgraph-type-conflicts.js\";\nimport {\n selectDocumentModelGeneration,\n selectScaffoldGeneration,\n} from \"./definitions/authoring-mode.js\";\nimport { scaffoldCodeFirstDocumentModel } from \"./definitions/code-first-scaffold.js\";\n\nexport async function startGenerateDocumentModel(\n args: GenerateDocumentModelArgs,\n projectDir: string,\n) {\n const { document, dir, all, extract, name, debug } = args;\n if (debug) {\n console.log({ args });\n }\n const project = buildTsMorphProject(projectDir);\n if (name !== undefined) {\n handleMutuallyExclusiveOptions(\n {\n \"--name\": name,\n \"--document\": document,\n \"--dir\": dir,\n \"--all\": all || undefined,\n \"--extract\": extract || undefined,\n },\n \"generation mode\",\n );\n const generation = selectScaffoldGeneration(args, projectDir);\n await scaffoldCodeFirstDocumentModel(generation, name, projectDir, project);\n return;\n }\n if (extract) {\n const docs = extractDocumentModelDocuments(project);\n for (const doc of docs) {\n const path = await saveSpec(doc, projectDir);\n console.log(`Wrote ${path}`);\n }\n return;\n }\n if (all) {\n const { documentModels, unreadableDirs, codeFirstDocumentModels } =\n await selectDocumentModelGeneration(\n args,\n projectDir,\n ).generateAllDocumentModels(project);\n await project.save();\n if (\n documentModels.length === 0 &&\n unreadableDirs.length === 0 &&\n codeFirstDocumentModels.length === 0\n ) {\n console.log(\"No document models found in document-models/.\");\n }\n for (const { name } of documentModels) {\n console.log(`Regenerated document model \"${name}\"`);\n }\n for (const { name } of codeFirstDocumentModels) {\n console.log(`Updated the exports of code-first document model \"${name}\"`);\n }\n for (const dirName of unreadableDirs) {\n console.warn(\n `Skipped document-models/${dirName}: expected a valid document model spec at document-models/${dirName}/${dirName}.json. Kept the manifest's document models.`,\n );\n }\n await warnSubgraphTypeConflicts(projectDir);\n return;\n } else if (document) {\n const generation = selectDocumentModelGeneration(args, projectDir);\n if (document.endsWith(\".phd\")) {\n const doc = (await getDocument(document)) as DocumentModelDocument;\n await generation.generateDocumentModel(doc.state.global, project);\n } else {\n const state = await loadDocumentModel(document);\n await generation.generateDocumentModel(state, project);\n }\n } else if (dir) {\n const dirName = resolveModuleDirName(\n projectDir,\n \"document-models\",\n dir,\n \"my-document-model\",\n );\n const specPath = join(\n projectDir,\n \"document-models\",\n dirName,\n `${dirName}.json`,\n );\n if (!existsSync(specPath)) {\n throw new Error(`document-models/${dirName} has no ${dirName}.json.`);\n }\n const state = await loadDocumentModel(specPath);\n await selectDocumentModelGeneration(args, projectDir).generateDocumentModel(\n state,\n project,\n );\n await project.save();\n console.log(\n `Regenerated document model \"${state.name}\" in document-models/${dirName}`,\n );\n await warnSubgraphTypeConflicts(projectDir);\n return;\n } else {\n console.log(\n \"Please specify one of `document`, `dir`, `all`, or `extract`.\",\n );\n return;\n }\n await project.save();\n await warnSubgraphTypeConflicts(projectDir);\n}\n"],"names":[],"mappings":"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","debug_id":"edf3c0ce-f462-506f-a23d-a305b93c5a18"}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="4535eeb7-fe12-5c56-bd4a-286b6b513227")}catch(e){}}();
|
|
3
|
+
import { n as selectProjectModelGeneration } from "./authoring-mode-DWbbsuWh.mjs";
|
|
3
4
|
import { t as resolveModuleDirName } from "./module-dir-1avCXsBi.mjs";
|
|
4
5
|
import { existsSync } from "node:fs";
|
|
5
6
|
import { join } from "node:path";
|
|
6
|
-
import { generateAllEditors, generateEditor } from "@powerhousedao/codegen";
|
|
7
7
|
import { buildTsMorphProject, getEditorMetadata } from "@powerhousedao/codegen/utils";
|
|
8
8
|
import { extractEditorDocuments, generateEditorFromDocument, getDocument, saveSpec } from "@powerhousedao/vetra/codegen";
|
|
9
9
|
//#region src/services/generate-editor.ts
|
|
@@ -23,7 +23,7 @@ async function startGenerateEditor(args, projectDir) {
|
|
|
23
23
|
}
|
|
24
24
|
const report = [];
|
|
25
25
|
if (all) {
|
|
26
|
-
const { editors, unreadableDirs } = await generateAllEditors(project);
|
|
26
|
+
const { editors, unreadableDirs } = await selectProjectModelGeneration(projectDir).generateAllEditors(project);
|
|
27
27
|
if (editors.length === 0 && unreadableDirs.length === 0) report.push("No document editors found in editors/.");
|
|
28
28
|
for (const editor of editors) report.push(`Regenerated editor "${editor.name}" in editors/${editor.dirName}`);
|
|
29
29
|
for (const dirName of unreadableDirs) console.warn(`Skipped editors/${dirName}: expected its module.ts to export ${MODULE_FILE_EXPECTATION}. Kept the manifest's editors.`);
|
|
@@ -32,7 +32,7 @@ async function startGenerateEditor(args, projectDir) {
|
|
|
32
32
|
await generateEditorFromDocument(doc, project);
|
|
33
33
|
} else if (name) {
|
|
34
34
|
if (!documentType) throw new Error("Please specify a document type for the new editor to generate.");
|
|
35
|
-
await generateEditor({
|
|
35
|
+
await selectProjectModelGeneration(projectDir).generateEditor({
|
|
36
36
|
editorName: name,
|
|
37
37
|
documentTypes: [documentType]
|
|
38
38
|
}, project);
|
|
@@ -43,7 +43,7 @@ async function startGenerateEditor(args, projectDir) {
|
|
|
43
43
|
if (!editorArgs) throw new Error(`Could not read editors/${dirName}/module.ts: expected ${MODULE_FILE_EXPECTATION}.`);
|
|
44
44
|
if (editorArgs.documentTypes.includes("powerhouse/document-drive")) throw new Error(`editors/${dirName} is a drive app, not a document editor. Use \`ph-cli generate app --dir ${dirName}\` instead.`);
|
|
45
45
|
const { name: editorName, id: editorId, dirName: editorDirName, documentTypes } = editorArgs;
|
|
46
|
-
await generateEditor({
|
|
46
|
+
await selectProjectModelGeneration(projectDir).generateEditor({
|
|
47
47
|
editorName,
|
|
48
48
|
editorId,
|
|
49
49
|
editorDirName,
|
|
@@ -60,5 +60,5 @@ async function startGenerateEditor(args, projectDir) {
|
|
|
60
60
|
//#endregion
|
|
61
61
|
export { startGenerateEditor };
|
|
62
62
|
|
|
63
|
-
//# sourceMappingURL=generate-editor-
|
|
64
|
-
//# debugId=
|
|
63
|
+
//# sourceMappingURL=generate-editor-DdoapkEK.mjs.map
|
|
64
|
+
//# debugId=4535eeb7-fe12-5c56-bd4a-286b6b513227
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"generate-editor-DdoapkEK.mjs","sources":["../src/services/generate-editor.ts"],"sourcesContent":["import {\n buildTsMorphProject,\n getEditorMetadata,\n} from \"@powerhousedao/codegen/utils\";\nimport {\n extractEditorDocuments,\n generateEditorFromDocument,\n getDocument,\n saveSpec,\n} from \"@powerhousedao/vetra/codegen\";\nimport type { DocumentEditorDocument } from \"@powerhousedao/vetra/document-models/document-editor\";\nimport { existsSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport type { GenerateEditorArgs } from \"../types.js\";\nimport { resolveModuleDirName } from \"../utils/module-dir.js\";\nimport { selectProjectModelGeneration } from \"./definitions/authoring-mode.js\";\n\nconst MODULE_FILE_EXPECTATION =\n \"an EditorModule with string literals for config.id, config.name and documentTypes\";\n\nexport async function startGenerateEditor(\n args: GenerateEditorArgs,\n projectDir: string,\n) {\n const { name, documentType, document, dir, all, extract, debug } = args;\n if (debug) {\n console.log({ args });\n }\n const project = buildTsMorphProject(projectDir);\n if (extract) {\n const docs = extractEditorDocuments(project);\n if (docs.length === 0) {\n console.log(\"No document editors found in editors/.\");\n }\n for (const doc of docs) {\n const path = await saveSpec(doc, projectDir);\n console.log(`Wrote ${path}`);\n }\n return;\n }\n const report: string[] = [];\n if (all) {\n const { editors, unreadableDirs } =\n await selectProjectModelGeneration(projectDir).generateAllEditors(\n project,\n );\n if (editors.length === 0 && unreadableDirs.length === 0) {\n report.push(\"No document editors found in editors/.\");\n }\n for (const editor of editors) {\n report.push(\n `Regenerated editor \"${editor.name}\" in editors/${editor.dirName}`,\n );\n }\n for (const dirName of unreadableDirs) {\n console.warn(\n `Skipped editors/${dirName}: expected its module.ts to export ${MODULE_FILE_EXPECTATION}. Kept the manifest's editors.`,\n );\n }\n } else if (document) {\n const doc = (await getDocument(document)) as DocumentEditorDocument;\n await generateEditorFromDocument(doc, project);\n } else if (name) {\n if (!documentType) {\n throw new Error(\n \"Please specify a document type for the new editor to generate.\",\n );\n }\n await selectProjectModelGeneration(projectDir).generateEditor(\n { editorName: name, documentTypes: [documentType] },\n project,\n );\n } else if (dir) {\n const dirName = resolveModuleDirName(\n projectDir,\n \"editors\",\n dir,\n \"my-editor\",\n );\n if (!existsSync(join(projectDir, \"editors\", dirName, \"module.ts\"))) {\n throw new Error(`editors/${dirName} has no module.ts.`);\n }\n const editorArgs = getEditorMetadata(project, dirName);\n if (!editorArgs) {\n throw new Error(\n `Could not read editors/${dirName}/module.ts: expected ${MODULE_FILE_EXPECTATION}.`,\n );\n }\n if (editorArgs.documentTypes.includes(\"powerhouse/document-drive\")) {\n throw new Error(\n `editors/${dirName} is a drive app, not a document editor. Use \\`ph-cli generate app --dir ${dirName}\\` instead.`,\n );\n }\n const {\n name: editorName,\n id: editorId,\n dirName: editorDirName,\n documentTypes,\n } = editorArgs;\n await selectProjectModelGeneration(projectDir).generateEditor(\n {\n editorName,\n editorId,\n editorDirName,\n documentTypes,\n },\n project,\n );\n report.push(\n `Regenerated editor \"${editorName}\" in editors/${editorDirName}`,\n );\n } else {\n console.log(\n \"Please specify one of `name`, `document`, `dir`, `all`, or `extract`.\",\n );\n return;\n }\n await project.save();\n for (const line of report) {\n console.log(line);\n }\n}\n"],"names":[],"mappings":";;;;;;;;;AAiBA,MAAM,0BACJ;AAEF,eAAsB,oBACpB,MACA,YACA;CACA,MAAM,EAAE,MAAM,cAAc,UAAU,KAAK,KAAK,SAAS,UAAU;CACnE,IAAI,OACF,QAAQ,IAAI,EAAE,KAAK,CAAC;CAEtB,MAAM,UAAU,oBAAoB,UAAU;CAC9C,IAAI,SAAS;EACX,MAAM,OAAO,uBAAuB,OAAO;EAC3C,IAAI,KAAK,WAAW,GAClB,QAAQ,IAAI,wCAAwC;EAEtD,KAAK,MAAM,OAAO,MAAM;GACtB,MAAM,OAAO,MAAM,SAAS,KAAK,UAAU;GAC3C,QAAQ,IAAI,SAAS,MAAM;EAC7B;EACA;CACF;CACA,MAAM,SAAmB,CAAC;CAC1B,IAAI,KAAK;EACP,MAAM,EAAE,SAAS,mBACf,MAAM,6BAA6B,UAAU,CAAC,CAAC,mBAC7C,OACF;EACF,IAAI,QAAQ,WAAW,KAAK,eAAe,WAAW,GACpD,OAAO,KAAK,wCAAwC;EAEtD,KAAK,MAAM,UAAU,SACnB,OAAO,KACL,uBAAuB,OAAO,KAAK,eAAe,OAAO,SAC3D;EAEF,KAAK,MAAM,WAAW,gBACpB,QAAQ,KACN,mBAAmB,QAAQ,qCAAqC,wBAAwB,+BAC1F;CAEJ,OAAO,IAAI,UAAU;EACnB,MAAM,MAAO,MAAM,YAAY,QAAQ;EACvC,MAAM,2BAA2B,KAAK,OAAO;CAC/C,OAAO,IAAI,MAAM;EACf,IAAI,CAAC,cACH,MAAM,IAAI,MACR,gEACF;EAEF,MAAM,6BAA6B,UAAU,CAAC,CAAC,eAC7C;GAAE,YAAY;GAAM,eAAe,CAAC,YAAY;EAAE,GAClD,OACF;CACF,OAAO,IAAI,KAAK;EACd,MAAM,UAAU,qBACd,YACA,WACA,KACA,WACF;EACA,IAAI,CAAC,WAAW,KAAK,YAAY,WAAW,SAAS,WAAW,CAAC,GAC/D,MAAM,IAAI,MAAM,WAAW,QAAQ,mBAAmB;EAExD,MAAM,aAAa,kBAAkB,SAAS,OAAO;EACrD,IAAI,CAAC,YACH,MAAM,IAAI,MACR,0BAA0B,QAAQ,uBAAuB,wBAAwB,EACnF;EAEF,IAAI,WAAW,cAAc,SAAS,2BAA2B,GAC/D,MAAM,IAAI,MACR,WAAW,QAAQ,0EAA0E,QAAQ,YACvG;EAEF,MAAM,EACJ,MAAM,YACN,IAAI,UACJ,SAAS,eACT,kBACE;EACJ,MAAM,6BAA6B,UAAU,CAAC,CAAC,eAC7C;GACE;GACA;GACA;GACA;EACF,GACA,OACF;EACA,OAAO,KACL,uBAAuB,WAAW,eAAe,eACnD;CACF,OAAO;EACL,QAAQ,IACN,uEACF;EACA;CACF;CACA,MAAM,QAAQ,KAAK;CACnB,KAAK,MAAM,QAAQ,QACjB,QAAQ,IAAI,IAAI;AAEpB","debug_id":"4535eeb7-fe12-5c56-bd4a-286b6b513227"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
2
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="90cbd4ec-396f-5e58-949f-8a21be6e8da7")}catch(e){}}();
|
|
3
3
|
import { t as installAddedDependencies$1 } from "./install-added-dependencies-DnZFR3aE.mjs";
|
|
4
4
|
import { t as resolveModuleDirName } from "./module-dir-1avCXsBi.mjs";
|
|
5
5
|
import { existsSync } from "node:fs";
|
|
@@ -7,8 +7,8 @@ import { join } from "node:path";
|
|
|
7
7
|
import { detectFeatures, generateAllPieces, generatePiece, syncFeatureDependencies } from "@powerhousedao/codegen";
|
|
8
8
|
import { readPackage } from "read-pkg";
|
|
9
9
|
import { buildTsMorphProject, readPiecesList } from "@powerhousedao/codegen/utils";
|
|
10
|
-
import { derivePieceId } from "@powerhousedao/codegen/name-builders";
|
|
11
10
|
import { kebabCase } from "change-case";
|
|
11
|
+
import { derivePieceId } from "@powerhousedao/codegen/name-builders";
|
|
12
12
|
import enquirer from "enquirer";
|
|
13
13
|
//#region src/services/generate-piece.ts
|
|
14
14
|
async function resolvePieceId(v) {
|
|
@@ -69,5 +69,5 @@ async function startGeneratePiece(args, projectDir) {
|
|
|
69
69
|
//#endregion
|
|
70
70
|
export { startGeneratePiece };
|
|
71
71
|
|
|
72
|
-
//# sourceMappingURL=generate-piece-
|
|
73
|
-
//# debugId=
|
|
72
|
+
//# sourceMappingURL=generate-piece-DpFUr1ON.mjs.map
|
|
73
|
+
//# debugId=90cbd4ec-396f-5e58-949f-8a21be6e8da7
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generate-piece-
|
|
1
|
+
{"version":3,"file":"generate-piece-DpFUr1ON.mjs","sources":["../src/services/generate-piece.ts"],"sourcesContent":["import {\n detectFeatures,\n generateAllPieces,\n generatePiece,\n syncFeatureDependencies,\n} from \"@powerhousedao/codegen\";\nimport { derivePieceId } from \"@powerhousedao/codegen/name-builders\";\nimport {\n buildTsMorphProject,\n readPiecesList,\n} from \"@powerhousedao/codegen/utils\";\nimport { kebabCase } from \"change-case\";\nimport enquirer from \"enquirer\";\nimport { existsSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { readPackage } from \"read-pkg\";\nimport type { Project } from \"ts-morph\";\nimport type { GeneratePieceArgs } from \"../types.js\";\nimport { installAddedDependencies } from \"../utils/install-added-dependencies.js\";\nimport { resolveModuleDirName } from \"../utils/module-dir.js\";\n\n// The id a block type will name, asked for only where deriving one would claim\n// a namespace nobody owns; CI, with no TTY, takes the derived value.\nasync function resolvePieceId(v: {\n project: Project;\n projectDir: string;\n pieceName: string;\n id?: string;\n}): Promise<string> {\n if (v.id) return v.id;\n const pkg = await readPackage({ cwd: v.projectDir, normalize: false });\n const { id, needsConfirmation } = derivePieceId({\n packageName: pkg.name ?? \"\",\n slug: kebabCase(v.pieceName),\n hasOtherPieces: readPiecesList(v.project).length > 0,\n });\n if (!needsConfirmation || !process.stdin.isTTY) return id;\n const { prompt } = enquirer;\n const result = await prompt<{ pieceId: string }>([\n {\n type: \"input\",\n name: \"pieceId\",\n message:\n \"What id should this piece have? A workflow step names it as its pieceName.\",\n initial: id,\n required: true,\n },\n ]);\n return result.pieceId || id;\n}\n\nexport async function startGeneratePiece(\n args: GeneratePieceArgs,\n projectDir: string,\n) {\n const {\n namePositional,\n name: nameOption,\n id,\n auth,\n description,\n dir,\n all,\n debug,\n } = args;\n if (debug) {\n console.log({ args });\n }\n const project = buildTsMorphProject(projectDir);\n const name = namePositional ?? nameOption;\n const report: string[] = [];\n if (all) {\n await generateAllPieces(project);\n } else if (dir) {\n const dirName = resolveModuleDirName(projectDir, \"pieces\", dir, \"my-piece\");\n if (!existsSync(join(projectDir, \"pieces\", dirName, \"index.ts\"))) {\n throw new Error(`pieces/${dirName} has no index.ts.`);\n }\n await generateAllPieces(project, dirName);\n report.push(`Re-registered the piece in pieces/${dirName}`);\n } else if (name) {\n const pieceId = await resolvePieceId({\n project,\n projectDir,\n pieceName: name,\n id,\n });\n await generatePiece(\n { pieceName: name, pieceId, auth, description },\n project,\n );\n } else {\n console.log(\"Please specify one of `name`, `dir`, or `all`.\");\n return;\n }\n await project.save();\n for (const line of report) {\n console.log(line);\n }\n const added = await syncFeatureDependencies(\n detectFeatures(projectDir),\n projectDir,\n );\n await installAddedDependencies(added, projectDir, args.skipInstall);\n}\n"],"names":["installAddedDependencies"],"mappings":";;;;;;;;;;;;;AAuBA,eAAe,eAAe,GAKV;CAClB,IAAI,EAAE,IAAI,OAAO,EAAE;CACnB,MAAM,MAAM,MAAM,YAAY;EAAE,KAAK,EAAE;EAAY,WAAW;CAAM,CAAC;CACrE,MAAM,EAAE,IAAI,sBAAsB,cAAc;EAC9C,aAAa,IAAI,QAAQ;EACzB,MAAM,UAAU,EAAE,SAAS;EAC3B,gBAAgB,eAAe,EAAE,OAAO,CAAC,CAAC,SAAS;CACrD,CAAC;CACD,IAAI,CAAC,qBAAqB,CAAC,QAAQ,MAAM,OAAO,OAAO;CACvD,MAAM,EAAE,WAAW;CAWnB,QAAO,MAVc,OAA4B,CAC/C;EACE,MAAM;EACN,MAAM;EACN,SACE;EACF,SAAS;EACT,UAAU;CACZ,CACF,CAAC,EAAA,CACa,WAAW;AAC3B;AAEA,eAAsB,mBACpB,MACA,YACA;CACA,MAAM,EACJ,gBACA,MAAM,YACN,IACA,MACA,aACA,KACA,KACA,UACE;CACJ,IAAI,OACF,QAAQ,IAAI,EAAE,KAAK,CAAC;CAEtB,MAAM,UAAU,oBAAoB,UAAU;CAC9C,MAAM,OAAO,kBAAkB;CAC/B,MAAM,SAAmB,CAAC;CAC1B,IAAI,KACF,MAAM,kBAAkB,OAAO;MAC1B,IAAI,KAAK;EACd,MAAM,UAAU,qBAAqB,YAAY,UAAU,KAAK,UAAU;EAC1E,IAAI,CAAC,WAAW,KAAK,YAAY,UAAU,SAAS,UAAU,CAAC,GAC7D,MAAM,IAAI,MAAM,UAAU,QAAQ,kBAAkB;EAEtD,MAAM,kBAAkB,SAAS,OAAO;EACxC,OAAO,KAAK,qCAAqC,SAAS;CAC5D,OAAO,IAAI,MAAM;EACf,MAAM,UAAU,MAAM,eAAe;GACnC;GACA;GACA,WAAW;GACX;EACF,CAAC;EACD,MAAM,cACJ;GAAE,WAAW;GAAM;GAAS;GAAM;EAAY,GAC9C,OACF;CACF,OAAO;EACL,QAAQ,IAAI,gDAAgD;EAC5D;CACF;CACA,MAAM,QAAQ,KAAK;CACnB,KAAK,MAAM,QAAQ,QACjB,QAAQ,IAAI,IAAI;CAElB,MAAM,QAAQ,MAAM,wBAClB,eAAe,UAAU,GACzB,UACF;CACA,MAAMA,2BAAyB,OAAO,YAAY,KAAK,WAAW;AACpE","debug_id":"90cbd4ec-396f-5e58-949f-8a21be6e8da7"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
//#region src/get-version.ts
|
|
2
2
|
|
|
3
|
-
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="
|
|
3
|
+
!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="ab077922-fa06-595e-a284-4f76cf64b6f4")}catch(e){}}();
|
|
4
4
|
function getVersion() {
|
|
5
|
-
return "6.2.3-dev.
|
|
5
|
+
return "6.2.3-dev.91";
|
|
6
6
|
}
|
|
7
7
|
//#endregion
|
|
8
8
|
export { getVersion as t };
|
|
9
9
|
|
|
10
|
-
//# sourceMappingURL=get-version-
|
|
11
|
-
//# debugId=
|
|
10
|
+
//# sourceMappingURL=get-version-CxLCsLBV.mjs.map
|
|
11
|
+
//# debugId=ab077922-fa06-595e-a284-4f76cf64b6f4
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get-version-
|
|
1
|
+
{"version":3,"file":"get-version-CxLCsLBV.mjs","sources":["../src/get-version.ts"],"sourcesContent":["declare const CLI_VERSION: string | undefined;\ndeclare const CLI_GIT_SHA: string | undefined;\n\nexport function getVersion() {\n if (typeof CLI_VERSION !== \"undefined\") return CLI_VERSION;\n return (\n process.env.WORKSPACE_VERSION ||\n process.env.npm_package_version ||\n \"unknown\"\n );\n}\n\nexport function getGitHash() {\n if (typeof CLI_GIT_SHA !== \"undefined\") return CLI_GIT_SHA;\n return process.env.WORKSPACE_GIT_SHA || \"unknown\";\n}\n"],"names":[],"mappings":";;;AAGA,SAAgB,aAAa;CACa,OAAA;AAM1C","debug_id":"ab077922-fa06-595e-a284-4f76cf64b6f4"}
|
|
@@ -4275,7 +4275,7 @@ declare namespace external_d_exports {
|
|
|
4275
4275
|
export { $brand, $input, $output, BRAND, CompileOptions, GlobalMeta, INVALID, Infer, IssueData, JSONType, NEVER, $RefinementCtx as RefinementCtx, SafeExtendShape, Schema, TimePrecision, TypeOf, ZodAny, ZodArray, ZodBase64, ZodBase64URL, ZodBigInt, ZodBigIntFormat, ZodBoolean, ZodCIDRv4, ZodCIDRv6, ZodCUID, ZodCUID2, ZodCatch, ZodCodec, ZodCoercedBigInt, ZodCoercedBoolean, ZodCoercedDate, ZodCoercedNumber, ZodCoercedString, ZodCompileAsyncError, ZodCompileUnsupportedError, ZodCreditCard, ZodCustom, ZodCustomStringFormat, ZodDate, ZodDefault, ZodDiscriminatedUnion, ZodE164, ZodEmail, ZodEmoji, ZodEnum, ZodError, ZodErrorMap, ZodExactOptional, ZodFile, ZodFirstPartySchemaTypes, ZodFirstPartyTypeKind, ZodFlattenedError, ZodFloat32, ZodFloat64, ZodFormattedError, ZodFunction, ZodGUID, ZodIBAN, ZodIPv4, ZodIPv6, ZodISODate, ZodISODateTime, ZodISODuration, ZodISOTime, ZodInstanceOf, ZodInt, ZodInt32, ZodInt64, ZodIntersection, ZodIssue, ZodIssueCode, ZodJSONSchema, ZodJSONSchemaInternals, ZodJWT, ZodKSUID, ZodLazy, ZodLiteral, ZodMAC, ZodMap, ZodNaN, ZodNanoID, ZodNever, ZodNonOptional, ZodNull, ZodNullable, ZodNumber, ZodNumberFormat, ZodObject, ZodOptional, ZodPipe, ZodPrefault, ZodPreprocess, ZodPromise, ZodRawShape, ZodReadonly, ZodRealError, ZodRecord, ZodSafeParseError, ZodSafeParseResult, ZodSafeParseSuccess, ZodSchema, ZodSet, ZodStandardSchemaWithJSON, ZodString, ZodStringFormat, ZodSuccess, ZodSymbol, ZodTemplateLiteral, ZodTransform, ZodTuple, ZodType, ZodTypeAny, ZodUInt32, ZodUInt64, ZodULID, ZodURL, ZodUUID, ZodUndefined, ZodUnion, ZodUnknown, ZodVoid, ZodXID, ZodXor, _ZodBigInt, _ZodBoolean, _ZodDate, _ZodNumber, _ZodString, _ZodType, _default, _function, any, array, base64, base64url, bigint$1 as bigint, boolean$1 as boolean, _catch as catch, check, cidrv4, cidrv6, clone, codec, coerce_d_exports as coerce, compile, config, index_d_exports as core, creditCard, cuid, cuid2, currencyCode, custom, date$2 as date, decode, decodeAsync, deepPartial, describe, discriminatedUnion, e164, email, emoji, encode, encodeAsync, _endsWith as endsWith, _enum as enum, exactOptional, file, flattenError, float32, float64, formatError, fromJSONSchema, _function as function, getDiscriminatedOption, getErrorMap, globalRegistry, _gt as gt, _gte as gte, guid, hash, hex, hostname, httpUrl, iban, _includes as includes, output$1 as infer, inferFlattenedErrors, inferFormattedError, input, _instanceof as instanceof, int, int32, int64, intersection, invertCodec, ipv4, ipv6, iso_d_exports as iso, json, jwt, keyof, ksuid, lazy, _length as length, literal, index_d_exports$1 as locales, looseObject, looseRecord, _lowercase as lowercase, _lt as lt, _lte as lte, mac, map, _maxLength as maxLength, _maxSize as maxSize, memoizer, meta, _mime as mime, _minLength as minLength, _minSize as minSize, _multipleOf as multipleOf, nan, nanoid, nativeEnum, _negative as negative, never, _nonnegative as nonnegative, nonoptional, _nonpositive as nonpositive, _normalize as normalize, _null as null, nullable, nullish, number$1 as number, object, optional, output, _overwrite as overwrite, parse, parseAsync, partialRecord, pipe, _positive as positive, prefault, preprocess, prettifyError, promise, _properties as properties, _property as property, readonly, record, refine, _regex as regex, regexes_d_exports as regexes, registry, safeDecode, safeDecodeAsync, safeEncode, safeEncodeAsync, safeParse, safeParseAsync, set, setErrorMap, _size as size, _slugify as slugify, _startsWith as startsWith, strictObject, string$1 as string, stringFormat, stringbool, success, superRefine, symbol, templateLiteral, toJSONSchema, _toLowerCase as toLowerCase, _toUpperCase as toUpperCase, toZod, transform, treeifyError, _trim as trim, tuple, uint32, uint64, ulid, _undefined as undefined, union, unknown, _uppercase as uppercase, url, util_d_exports as util, uuid, uuidv4, uuidv6, uuidv7, validate, validateAsync, _void as void, withParser, xid, xor };
|
|
4276
4276
|
}
|
|
4277
4277
|
//#endregion
|
|
4278
|
-
//#region ../../packages/host-core/dist/compound-
|
|
4278
|
+
//#region ../../packages/host-core/dist/compound-eW-6nGxK.d.mts
|
|
4279
4279
|
declare const declaredGenericCompoundHostSchema: ZodObject<{
|
|
4280
4280
|
name: ZodString;
|
|
4281
4281
|
runner: ZodObject<{
|
|
@@ -4355,6 +4355,7 @@ declare const declaredGenericCompoundHostSchema: ZodObject<{
|
|
|
4355
4355
|
authEnforcement: ZodOptional<ZodBoolean>;
|
|
4356
4356
|
authGroups: ZodOptional<ZodBoolean>;
|
|
4357
4357
|
authConditions: ZodOptional<ZodBoolean>;
|
|
4358
|
+
undoV3: ZodOptional<ZodBoolean>;
|
|
4358
4359
|
}, $strict>>;
|
|
4359
4360
|
createSignaturePolicy: ZodOptional<ZodEnum<{
|
|
4360
4361
|
legacy: "legacy";
|
|
@@ -4457,4 +4458,4 @@ declare global {
|
|
|
4457
4458
|
//#endregion
|
|
4458
4459
|
export { RunnerHandle as n, RunnerContext as t };
|
|
4459
4460
|
export {};
|
|
4460
|
-
//# sourceMappingURL=index-
|
|
4461
|
+
//# sourceMappingURL=index-CuWHsoBB.d.mts.map
|