@process-analytics/bpmn-visualization-addons 0.8.0 → 0.9.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.
@@ -3,12 +3,12 @@ import { ShapeBpmnElementKind, ShapeUtil as BaseShapeUtil } from 'bpmn-visualiza
3
3
  /**
4
4
  * Options to deduplicate elements when several names match.
5
5
  */
6
- export type DeduplicateNamesOptions = {
6
+ export interface DeduplicateNamesOptions {
7
7
  /** If not set, use all `BpmnElementKind` values. */
8
8
  kinds?: BpmnElementKind[];
9
9
  /** Apply custom function to filter duplicates. */
10
10
  filter?: (bpmnSemantic: BpmnSemantic) => boolean;
11
- };
11
+ }
12
12
  /**
13
13
  * Provides workarounds for {@link https://github.com/process-analytics/bpmn-visualization-js/issues/2453}.
14
14
  */
@@ -56,4 +56,5 @@ export declare class BpmnElementsIdentifier {
56
56
  }
57
57
  export declare class ShapeUtil extends BaseShapeUtil {
58
58
  static isBpmnArtifact(kind: ShapeBpmnElementKind | string): boolean;
59
+ static isFlowNode(kind: ShapeBpmnElementKind | string): boolean;
59
60
  }
@@ -119,4 +119,8 @@ export class ShapeUtil extends BaseShapeUtil {
119
119
  static isBpmnArtifact(kind) {
120
120
  return kind === ShapeBpmnElementKind.GROUP || kind === ShapeBpmnElementKind.TEXT_ANNOTATION;
121
121
  }
122
+ static isFlowNode(kind) {
123
+ // there is currently a bug in bpmn-visualization (at least in version 0.44.0). It includes artifacts in flowNodeKinds.
124
+ return ShapeUtil.flowNodeKinds().includes(kind) && !ShapeUtil.isBpmnArtifact(kind);
125
+ }
122
126
  }
package/lib/paths.d.ts CHANGED
@@ -26,7 +26,7 @@ export declare class CasePathResolver {
26
26
  constructor(elementsRegistry: ElementsRegistry);
27
27
  compute(input: CasePathResolverInput): CasePathResolverOutput;
28
28
  }
29
- export type CasePathResolverInput = {
29
+ export interface CasePathResolverInput {
30
30
  /**
31
31
  * The IDs of elements (flowNodes/shapes and flows/edges) that are already completed. Non-existing ids will be silently ignored.
32
32
  *
@@ -34,8 +34,8 @@ export type CasePathResolverInput = {
34
34
  * No further user action or automation will update the element.
35
35
  */
36
36
  completedIds: string[];
37
- };
38
- export type CasePathResolverOutput = {
37
+ }
38
+ export interface CasePathResolverOutput {
39
39
  /**
40
40
  * The `BpmnSemantic` objects retrieved from the model that relate to the ids passed in {@link CasePathResolverInput}.
41
41
  */
@@ -51,4 +51,4 @@ export type CasePathResolverOutput = {
51
51
  edges: EdgeBpmnSemantic[];
52
52
  };
53
53
  };
54
- };
54
+ }
@@ -31,9 +31,9 @@ export interface Plugin {
31
31
  *
32
32
  * If you don't extend `GlobalOptions`, use {@link GlobalOptions} directly.
33
33
  */
34
- export type PluginOptionExtension = {
34
+ export interface PluginOptionExtension {
35
35
  plugins?: PluginConstructor[];
36
- };
36
+ }
37
37
  export type GlobalOptions = BaseGlobalOptions & PluginOptionExtension;
38
38
  /**
39
39
  * The identifiers of the plugins provided by `bpmn-visualization-addons`.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@process-analytics/bpmn-visualization-addons",
3
- "version": "0.8.0",
3
+ "version": "0.9.0",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "sideEffects": false,
@@ -49,15 +49,15 @@
49
49
  "bpmn-visualization": ">=0.42.0"
50
50
  },
51
51
  "devDependencies": {
52
- "@jest/globals": "~29.7.0",
53
- "@swc/core": "~1.7.28",
54
- "@swc/jest": "~0.2.36",
55
- "@testing-library/jest-dom": "~6.5.0",
52
+ "@jest/globals": "~30.0.1",
53
+ "@swc/core": "~1.12.3",
54
+ "@swc/jest": "~0.2.38",
55
+ "@testing-library/jest-dom": "~6.6.3",
56
56
  "cross-env": "~7.0.3",
57
- "eslint-plugin-jest": "~28.8.3",
58
- "eslint-plugin-jest-dom": "~5.4.0",
59
- "jest": "~29.7.0",
60
- "jest-environment-jsdom": "~29.7.0",
57
+ "eslint-plugin-jest": "~29.0.1",
58
+ "eslint-plugin-jest-dom": "~5.5.0",
59
+ "jest": "~30.0.1",
60
+ "jest-environment-jsdom": "~30.0.1",
61
61
  "npm-run-all": "~4.1.5",
62
62
  "rimraf": "~6.0.1"
63
63
  }