@inf-monkeys-tech/monkeys 1.0.68 → 1.0.70
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/lib/contracts/declarative-control-http.d.ts +1681 -369
- package/lib/contracts/declarative-control-http.d.ts.map +1 -1
- package/lib/contracts/declarative-control.d.ts +740 -23
- package/lib/contracts/declarative-control.d.ts.map +1 -1
- package/lib/contracts/declarative-control.js +22 -3
- package/lib/contracts/declarative-control.js.map +1 -1
- package/lib/contracts/index.d.ts +1 -0
- package/lib/contracts/index.d.ts.map +1 -1
- package/lib/contracts/index.js +1 -0
- package/lib/contracts/index.js.map +1 -1
- package/lib/contracts/workflow-column.d.ts +130 -0
- package/lib/contracts/workflow-column.d.ts.map +1 -0
- package/lib/contracts/workflow-column.js +72 -0
- package/lib/contracts/workflow-column.js.map +1 -0
- package/lib/esm/contracts/index.mjs +103 -25
- package/lib/esm/contracts/index.mjs.map +1 -1
- package/lib/esm/index.mjs +225 -25
- package/lib/esm/index.mjs.map +1 -1
- package/lib/esm/runtime/index.mjs +207 -15
- package/lib/esm/runtime/index.mjs.map +1 -1
- package/lib/esm/schemas/index.mjs +81 -3
- package/lib/esm/schemas/index.mjs.map +1 -1
- package/lib/json-schema/index.json +1 -0
- package/lib/json-schema/navigation-release.schema.json +582 -0
- package/lib/json-schema/navigation-runtime-bundle.schema.json +579 -0
- package/lib/json-schema/workflow-column-binding.schema.json +386 -0
- package/lib/runtime/declarative-control-compiler.d.ts.map +1 -1
- package/lib/runtime/declarative-control-compiler.js +26 -0
- package/lib/runtime/declarative-control-compiler.js.map +1 -1
- package/lib/runtime/index.d.ts +2 -0
- package/lib/runtime/index.d.ts.map +1 -1
- package/lib/runtime/index.js +2 -0
- package/lib/runtime/index.js.map +1 -1
- package/lib/runtime/menu-compiler.d.ts +19 -1
- package/lib/runtime/menu-compiler.d.ts.map +1 -1
- package/lib/runtime/menu-compiler.js +34 -0
- package/lib/runtime/menu-compiler.js.map +1 -1
- package/lib/runtime/navigation-availability.d.ts +6 -0
- package/lib/runtime/navigation-availability.d.ts.map +1 -0
- package/lib/runtime/navigation-availability.js +17 -0
- package/lib/runtime/navigation-availability.js.map +1 -0
- package/lib/runtime/workflow-column.d.ts +8 -0
- package/lib/runtime/workflow-column.d.ts.map +1 -0
- package/lib/runtime/workflow-column.js +57 -0
- package/lib/runtime/workflow-column.js.map +1 -0
- package/lib/schemas/index.d.ts +310 -1
- package/lib/schemas/index.d.ts.map +1 -1
- package/lib/schemas/index.js +13 -4
- package/lib/schemas/index.js.map +1 -1
- package/package.json +1 -1
- package/test/fixtures/navigation-three-roots-topology.json +275 -0
|
@@ -9122,6 +9122,12 @@ var ResolvedNavigationTargetSchema = z10.object({
|
|
|
9122
9122
|
targetRevisionRef: RevisionRefSchema,
|
|
9123
9123
|
releaseRevisionRef: RevisionRefSchema.optional()
|
|
9124
9124
|
}).strict();
|
|
9125
|
+
var UnavailableNavigationTargetSchema = z10.object({
|
|
9126
|
+
nodeId: ContractIdentifierSchema,
|
|
9127
|
+
stableTargetRef: StableRefSchema.refine((reference) => reference.kind === "page", "Only missing Pages can be isolated."),
|
|
9128
|
+
reason: z10.literal("page-missing"),
|
|
9129
|
+
accessPolicy: AccessPolicySchema.nullable()
|
|
9130
|
+
}).strict();
|
|
9125
9131
|
var NavigationReleaseSchema = z10.object({
|
|
9126
9132
|
contract: z10.literal("NavigationRelease"),
|
|
9127
9133
|
...ReleaseBaseShape,
|
|
@@ -9131,13 +9137,17 @@ var NavigationReleaseSchema = z10.object({
|
|
|
9131
9137
|
surface: ProductSurfaceSchema,
|
|
9132
9138
|
placement: ContractIdentifierSchema
|
|
9133
9139
|
}).strict(),
|
|
9134
|
-
resolvedTargets: z10.array(ResolvedNavigationTargetSchema)
|
|
9140
|
+
resolvedTargets: z10.array(ResolvedNavigationTargetSchema),
|
|
9141
|
+
unavailableTargets: z10.array(UnavailableNavigationTargetSchema).optional()
|
|
9135
9142
|
}).strict().superRefine((value, context) => {
|
|
9136
9143
|
validateDependencySnapshot(value.dependencySnapshot, context);
|
|
9137
9144
|
validateReleaseExpectedHead(value, "navigation-release", context);
|
|
9138
9145
|
if (value.navigationRevisionRef.kind !== "navigation") context.addIssue({ code: "custom", path: ["navigationRevisionRef", "kind"], message: "Expected a navigation revision." });
|
|
9139
9146
|
if (value.target.environmentRef.kind !== "environment") context.addIssue({ code: "custom", path: ["target", "environmentRef", "kind"], message: "Navigation release target requires an environment reference." });
|
|
9140
9147
|
if (uniqueArray(value.resolvedTargets, (target) => target.nodeId)) context.addIssue({ code: "custom", path: ["resolvedTargets"], message: "Resolved Navigation node IDs must be unique." });
|
|
9148
|
+
if (uniqueArray([...value.resolvedTargets, ...value.unavailableTargets ?? []], (target) => target.nodeId)) {
|
|
9149
|
+
context.addIssue({ code: "custom", path: ["unavailableTargets"], message: "Navigation target resolutions must have unique node IDs." });
|
|
9150
|
+
}
|
|
9141
9151
|
});
|
|
9142
9152
|
var RuntimeDiagnosticSchema = z10.object({
|
|
9143
9153
|
code: ContractIdentifierSchema,
|
|
@@ -9225,7 +9235,8 @@ var CompiledNavigationDomainCommandTargetSchema = ResolvedNavigationTargetSchema
|
|
|
9225
9235
|
var CompiledNavigationResolvedTargetSchema = z10.discriminatedUnion("kind", [
|
|
9226
9236
|
CompiledNavigationTargetSchema,
|
|
9227
9237
|
CompiledNavigationRegisteredMenuActionTargetSchema,
|
|
9228
|
-
CompiledNavigationDomainCommandTargetSchema
|
|
9238
|
+
CompiledNavigationDomainCommandTargetSchema,
|
|
9239
|
+
UnavailableNavigationTargetSchema.omit({ reason: true }).extend({ kind: z10.literal("unavailable") }).strict()
|
|
9229
9240
|
]);
|
|
9230
9241
|
var CompiledNavigationGroupNodeSchema = NavigationGroupNodeSchema.extend({
|
|
9231
9242
|
ancestorAccessPolicies: z10.array(AccessPolicySchema)
|
|
@@ -9233,7 +9244,14 @@ var CompiledNavigationGroupNodeSchema = NavigationGroupNodeSchema.extend({
|
|
|
9233
9244
|
var CompiledNavigationTargetNodeSchema = NavigationTargetNodeSchema.extend({
|
|
9234
9245
|
ancestorAccessPolicies: z10.array(AccessPolicySchema),
|
|
9235
9246
|
resolvedTarget: CompiledNavigationResolvedTargetSchema
|
|
9236
|
-
}).strict()
|
|
9247
|
+
}).strict().superRefine((node, context) => {
|
|
9248
|
+
if (node.resolvedTarget.nodeId !== node.nodeId || stableRefIdentity(node.resolvedTarget.stableTargetRef) !== stableRefIdentity(node.targetRef)) {
|
|
9249
|
+
context.addIssue({ code: "custom", path: ["resolvedTarget"], message: "Resolved target identity must match the source node." });
|
|
9250
|
+
}
|
|
9251
|
+
if (node.resolvedTarget.kind === "unavailable" && (node.disabled !== true || Object.keys(node.parameterMapping).length > 0)) {
|
|
9252
|
+
context.addIssue({ code: "custom", path: ["resolvedTarget"], message: "Unavailable targets must be disabled and contain no executable input." });
|
|
9253
|
+
}
|
|
9254
|
+
});
|
|
9237
9255
|
var CompiledNavigationSeparatorNodeSchema = NavigationSeparatorNodeSchema.extend({
|
|
9238
9256
|
ancestorAccessPolicies: z10.array(AccessPolicySchema)
|
|
9239
9257
|
}).strict();
|
|
@@ -13900,8 +13918,62 @@ var WorkflowCompletionReceiptSchema = z18.object({
|
|
|
13900
13918
|
});
|
|
13901
13919
|
});
|
|
13902
13920
|
|
|
13921
|
+
// src/contracts/workflow-column.ts
|
|
13922
|
+
import { z as z19 } from "zod";
|
|
13923
|
+
var WorkflowColumnFieldRefSchema = z19.object({
|
|
13924
|
+
ontologyId: ContractIdentifierSchema,
|
|
13925
|
+
fieldKey: ContractIdentifierSchema
|
|
13926
|
+
}).strict();
|
|
13927
|
+
var WorkflowColumnInputSchema = z19.discriminatedUnion("kind", [
|
|
13928
|
+
z19.object({ kind: z19.literal("default") }).strict(),
|
|
13929
|
+
z19.object({ kind: z19.literal("constant"), value: JsonValueSchema }).strict(),
|
|
13930
|
+
z19.object({ kind: z19.literal("field"), field: WorkflowColumnFieldRefSchema }).strict(),
|
|
13931
|
+
z19.object({
|
|
13932
|
+
kind: z19.literal("context"),
|
|
13933
|
+
field: z19.enum(["assetId", "teamId", "ontologyId", "columnId"])
|
|
13934
|
+
}).strict()
|
|
13935
|
+
]);
|
|
13936
|
+
var WorkflowColumnDependencySchema = z19.discriminatedUnion("kind", [
|
|
13937
|
+
z19.object({ kind: z19.literal("field"), field: WorkflowColumnFieldRefSchema }).strict(),
|
|
13938
|
+
z19.object({
|
|
13939
|
+
kind: z19.literal("relation"),
|
|
13940
|
+
relation: WorkflowColumnFieldRefSchema,
|
|
13941
|
+
direction: z19.enum(["incoming", "outgoing"]),
|
|
13942
|
+
fields: z19.array(WorkflowColumnFieldRefSchema).max(100)
|
|
13943
|
+
}).strict()
|
|
13944
|
+
]);
|
|
13945
|
+
var WorkflowColumnOutputPathSchema = z19.array(z19.string().min(1).max(256)).max(20);
|
|
13946
|
+
var WorkflowColumnOutputSchema = z19.object({
|
|
13947
|
+
type: z19.enum(["number", "text", "json"]),
|
|
13948
|
+
path: WorkflowColumnOutputPathSchema,
|
|
13949
|
+
nullable: z19.boolean().default(false)
|
|
13950
|
+
}).strict();
|
|
13951
|
+
var WorkflowColumnBindingSchema = z19.object({
|
|
13952
|
+
contract: z19.literal("WorkflowColumnBinding"),
|
|
13953
|
+
version: z19.literal(1),
|
|
13954
|
+
enabled: z19.boolean(),
|
|
13955
|
+
paused: z19.boolean().default(false),
|
|
13956
|
+
workflow: z19.object({
|
|
13957
|
+
id: ContractIdentifierSchema,
|
|
13958
|
+
version: z19.number().int().positive(),
|
|
13959
|
+
inputSchemaHash: Sha256Schema
|
|
13960
|
+
}).strict(),
|
|
13961
|
+
inputs: z19.record(z19.string().min(1).max(128), WorkflowColumnInputSchema),
|
|
13962
|
+
dependencies: z19.array(WorkflowColumnDependencySchema).max(100).default([]),
|
|
13963
|
+
output: WorkflowColumnOutputSchema,
|
|
13964
|
+
policy: z19.object({
|
|
13965
|
+
debounceMs: z19.number().int().min(0).max(3e4).default(5e3),
|
|
13966
|
+
maxDelayMs: z19.number().int().min(0).max(3e4).default(3e4),
|
|
13967
|
+
concurrency: z19.number().int().min(1).max(32).default(2)
|
|
13968
|
+
}).strict().default({ debounceMs: 5e3, maxDelayMs: 3e4, concurrency: 2 }),
|
|
13969
|
+
// The workflow supplies an ISO datetime with offset for one future expiry.
|
|
13970
|
+
// Scheduling infrastructure needs no knowledge of months or business periods.
|
|
13971
|
+
expiry: z19.object({ path: WorkflowColumnOutputPathSchema }).strict().optional()
|
|
13972
|
+
}).strict();
|
|
13973
|
+
|
|
13903
13974
|
// src/schemas/index.ts
|
|
13904
13975
|
var canonicalContractSchemas = {
|
|
13976
|
+
"workflow-column-binding": WorkflowColumnBindingSchema,
|
|
13905
13977
|
"agent-session-command": AgentSessionCommandSchema,
|
|
13906
13978
|
"agent-session-targeted-command": AgentSessionTargetedCommandSchema,
|
|
13907
13979
|
"agent-session-command-result": AgentSessionCommandResultSchema,
|
|
@@ -14249,6 +14321,7 @@ export {
|
|
|
14249
14321
|
TrendRadarCollectionSubjectRefSchema,
|
|
14250
14322
|
TrendSourceRecordSchema,
|
|
14251
14323
|
TrendSourceSchema,
|
|
14324
|
+
UnavailableNavigationTargetSchema,
|
|
14252
14325
|
ViewProviderDescriptorSchema,
|
|
14253
14326
|
WorkbenchAppInstanceSchema,
|
|
14254
14327
|
WorkbenchGroupSchema,
|
|
@@ -14256,6 +14329,11 @@ export {
|
|
|
14256
14329
|
WorkbenchRuntimeBundleSchema,
|
|
14257
14330
|
WorkbenchSchema,
|
|
14258
14331
|
WorkflowCatalogEntrySchema,
|
|
14332
|
+
WorkflowColumnBindingSchema,
|
|
14333
|
+
WorkflowColumnDependencySchema,
|
|
14334
|
+
WorkflowColumnFieldRefSchema,
|
|
14335
|
+
WorkflowColumnInputSchema,
|
|
14336
|
+
WorkflowColumnOutputSchema,
|
|
14259
14337
|
WorkflowCompletionCommitSchema,
|
|
14260
14338
|
WorkflowCompletionReceiptSchema,
|
|
14261
14339
|
WorkflowDefinitionSchema,
|