@lssm/lib.workflow-composer 0.3.1 → 1.41.0

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/README.md CHANGED
@@ -25,4 +25,9 @@ Refer to `docs/tech/personalization/workflow-composition.md` for more.
25
25
 
26
26
 
27
27
 
28
+
29
+
30
+
31
+
32
+
28
33
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lssm/lib.workflow-composer",
3
- "version": "0.3.1",
3
+ "version": "1.41.0",
4
4
  "description": "Tenant-aware workflow composition helpers for ContractSpec.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -23,19 +23,23 @@
23
23
  "test": "bun run"
24
24
  },
25
25
  "dependencies": {
26
- "@lssm/lib.contracts": "1.11.1"
26
+ "@lssm/lib.contracts": "workspace:*"
27
27
  },
28
28
  "devDependencies": {
29
- "@lssm/tool.tsdown": "0.12.1",
30
- "@lssm/tool.typescript": "0.11.1",
31
- "tsdown": "^0.16.6",
29
+ "@lssm/tool.tsdown": "workspace:*",
30
+ "@lssm/tool.typescript": "workspace:*",
31
+ "tsdown": "^0.17.4",
32
32
  "typescript": "^5.9.3"
33
33
  },
34
34
  "exports": {
35
- ".": "./dist/index.js",
35
+ ".": "./src/index.ts",
36
36
  "./*": "./*"
37
37
  },
38
38
  "publishConfig": {
39
- "access": "public"
39
+ "access": "public",
40
+ "exports": {
41
+ ".": "./dist/index.js",
42
+ "./*": "./*"
43
+ }
40
44
  }
41
45
  }
@@ -1,12 +0,0 @@
1
- import { ComposeParams, WorkflowExtension } from "./types.js";
2
- import { WorkflowSpec } from "@lssm/lib.contracts/workflow/spec";
3
-
4
- //#region src/composer.d.ts
5
- declare class WorkflowComposer {
6
- private readonly extensions;
7
- register(extension: WorkflowExtension): this;
8
- registerMany(extensions: WorkflowExtension[]): this;
9
- compose(params: ComposeParams): WorkflowSpec;
10
- }
11
- //#endregion
12
- export { WorkflowComposer };
package/dist/index.d.ts DELETED
@@ -1,7 +0,0 @@
1
- import { ComposeParams, StepInjection, WorkflowExtension, WorkflowExtensionScope } from "./types.js";
2
- import { StepTemplateOptions, approvalStepTemplate } from "./templates.js";
3
- import { applyWorkflowExtension } from "./injector.js";
4
- import { WorkflowComposer } from "./composer.js";
5
- import { WorkflowExtensionValidationIssue, validateExtension } from "./validator.js";
6
- import { mergeExtensions } from "./merger.js";
7
- export { ComposeParams, StepInjection, StepTemplateOptions, WorkflowComposer, WorkflowExtension, WorkflowExtensionScope, WorkflowExtensionValidationIssue, applyWorkflowExtension, approvalStepTemplate, mergeExtensions, validateExtension };
@@ -1,7 +0,0 @@
1
- import { WorkflowExtension } from "./types.js";
2
- import { WorkflowSpec } from "@lssm/lib.contracts/workflow/spec";
3
-
4
- //#region src/injector.d.ts
5
- declare function applyWorkflowExtension(base: WorkflowSpec, extension: WorkflowExtension): WorkflowSpec;
6
- //#endregion
7
- export { applyWorkflowExtension };
package/dist/merger.d.ts DELETED
@@ -1,6 +0,0 @@
1
- import { WorkflowExtension } from "./types.js";
2
-
3
- //#region src/merger.d.ts
4
- declare function mergeExtensions(extensions: WorkflowExtension[]): WorkflowExtension[];
5
- //#endregion
6
- export { mergeExtensions };
@@ -1,14 +0,0 @@
1
- import { Step, StepAction, StepType } from "@lssm/lib.contracts/workflow/spec";
2
-
3
- //#region src/templates.d.ts
4
- interface StepTemplateOptions {
5
- id: string;
6
- label: string;
7
- type?: StepType;
8
- description?: string;
9
- action?: StepAction;
10
- guardExpression?: string;
11
- }
12
- declare function approvalStepTemplate(options: StepTemplateOptions): Step;
13
- //#endregion
14
- export { StepTemplateOptions, approvalStepTemplate };
package/dist/types.d.ts DELETED
@@ -1,31 +0,0 @@
1
- import { Step, WorkflowSpec } from "@lssm/lib.contracts/workflow/spec";
2
-
3
- //#region src/types.d.ts
4
- interface WorkflowExtensionScope {
5
- tenantId?: string;
6
- role?: string;
7
- device?: string;
8
- }
9
- interface StepInjection {
10
- id?: string;
11
- after?: string;
12
- before?: string;
13
- inject: Step;
14
- when?: string;
15
- transitionTo?: string;
16
- transitionFrom?: string;
17
- }
18
- interface WorkflowExtension extends WorkflowExtensionScope {
19
- workflow: string;
20
- baseVersion?: number;
21
- priority?: number;
22
- customSteps?: StepInjection[];
23
- hiddenSteps?: string[];
24
- metadata?: Record<string, unknown>;
25
- annotations?: Record<string, unknown>;
26
- }
27
- interface ComposeParams extends WorkflowExtensionScope {
28
- base: WorkflowSpec;
29
- }
30
- //#endregion
31
- export { ComposeParams, StepInjection, WorkflowExtension, WorkflowExtensionScope };
@@ -1,11 +0,0 @@
1
- import { WorkflowExtension } from "./types.js";
2
- import { WorkflowSpec } from "@lssm/lib.contracts/workflow/spec";
3
-
4
- //#region src/validator.d.ts
5
- interface WorkflowExtensionValidationIssue {
6
- code: string;
7
- message: string;
8
- }
9
- declare function validateExtension(extension: WorkflowExtension, base: WorkflowSpec): void;
10
- //#endregion
11
- export { WorkflowExtensionValidationIssue, validateExtension };