@g1cloud/bpmn-modeler-next 5.0.0-alpha.1 → 5.0.0-alpha.100

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.
@@ -0,0 +1,36 @@
1
+ import { ModdleElement, ParseWarning } from '../adapter/xml';
2
+ /** 시블링 `IssueSeverity` 와 같은 3단계 — 패널이 필터 토글로 쓰고, 정렬 우선순위이기도 하다. */
3
+ export type IssueSeverity = 'error' | 'warning' | 'info';
4
+ /**
5
+ * 이슈가 가리키는 대상의 종류. 지금 쓰는 둘만 둔다 — union 확장은 additive 라 규칙이 늘 때
6
+ * 함께 넓히면 된다(미리 넣으면 어느 규칙도 쓰지 않는 값이 계약에 남는다).
7
+ */
8
+ export type SemanticTargetKind = 'flowNode' | 'participant';
9
+ export interface SemanticIssue {
10
+ /**
11
+ * 규칙 식별자 겸 **메시지 코드**. 소비측이 이 값(+`params`)으로 표시 문자열을 해석한다.
12
+ * 시블링 `CHK-*` 형식을 따르되 카테고리는 BPMN 고유라 충돌하지 않는다(`FLOW` · `POOL`).
13
+ */
14
+ ruleId: string;
15
+ severity: IssueSeverity;
16
+ targetKind: SemanticTargetKind;
17
+ /**
18
+ * 문제 요소 id 목록. 🔴 **시블링의 단수 `targetRef` 와 의도적으로 다르다** — 이 모듈에는
19
+ * 문서당 1건으로 **집약하는 규칙**이 있다(`CHK-POOL-1`: 실무 문서에서 문서당 5~18건이
20
+ * 전부 참이라, 개별로 내면 패널이 한 규칙으로 덮인다). 단일 대상 규칙은 길이 1 이다.
21
+ */
22
+ targetRefs: string[];
23
+ /** 표시 보간 데이터 — 번역 대상이 아닌 값(타입 리터럴·건수)만. */
24
+ params?: Record<string, string | number>;
25
+ }
26
+ /**
27
+ * 저장 진실 기준 의미론 판정 — 그 문서에 있는 **전부**(선재 포함). `auditBpmnGeometry` 와 같은
28
+ * 지위이고, 입력도 같은 moddle `definitions` 라 서버에서 돈다(A-6 과 같은 근거 — DOM 불요).
29
+ */
30
+ export declare function auditBpmnSemantics(definitions: ModdleElement): SemanticIssue[];
31
+ export interface AuditBpmnSemanticsXmlResult {
32
+ issues: SemanticIssue[];
33
+ warnings: ParseWarning[];
34
+ }
35
+ /** XML 문자열 입력 래퍼 (`describeProcessXml`·`auditBpmnGeometryXml` 대칭). */
36
+ export declare function auditBpmnSemanticsXml(xml: string): Promise<AuditBpmnSemanticsXmlResult>;
@@ -1,5 +1,5 @@
1
- import { BwlBand, BwlPlacement, BwlPoolOrder } from '../core/hints';
2
- import { IrAssociation, IrDataAssociation, IrDataStore, IrFlowCondition, IrFlowNodeType, IrGroup, IrLane, IrMessageFlow, IrNode, IrParticipant, IrSequenceFlow, IrTextAnnotation } from '../core/ir';
1
+ import { BwlAfterColumn, BwlBand, BwlPlacement, BwlPoolOrder } from '../core/hints';
2
+ import { IrAssociation, IrDataAssociation, IrDataStore, AddableFlowNodeType, IrFlowCondition, IrGroup, IrLane, IrMessageFlow, IrNode, IrParticipant, IrSequenceFlow, IrTextAnnotation } from '../core/ir';
3
3
  /** LLM 이 산출하는 단일 심볼릭 op. `kind` 로 판별한다. */
4
4
  export type SymbolicOp =
5
5
  /** 풀 추가. `order` = 풀 세로 순서 힌트(생략 시 op 순서가 곧 배치 순서). */
@@ -8,11 +8,15 @@ export type SymbolicOp =
8
8
  participant: IrParticipant;
9
9
  order?: BwlPoolOrder;
10
10
  }
11
- /** 플로우 노드 추가. `node.lane` 은 좌표 결정에만 쓰인다(A-3 — flowNodeRef 는 bpmn-js 지오메트리 자동 유지). `band` = 프로세스 내부 가로 밴드 힌트. */
11
+ /**
12
+ * 플로우 노드 추가. `node.lane` 은 좌표 결정에만 쓰인다(A-3 — flowNodeRef 는 bpmn-js 지오메트리 자동 유지).
13
+ * `band` = 프로세스 내부 가로 밴드(행) 힌트 · `afterColumn` = **열** 지목 힌트(그 노드보다 뒤 열 · 표본 73).
14
+ */
12
15
  | {
13
16
  kind: 'node.add';
14
17
  node: IrNode;
15
18
  band?: BwlBand;
19
+ afterColumn?: BwlAfterColumn;
16
20
  } | {
17
21
  kind: 'sequenceFlow.add';
18
22
  flow: IrSequenceFlow;
@@ -56,17 +60,32 @@ export type SymbolicOp =
56
60
  lanes?: IrLane[];
57
61
  }
58
62
  /** `lane` = 레인 재배정(이동). `type` = 태스크/이벤트 타입 전환(bpmn-js replace 하강 — 외래 확장 속성 유실 가능성은 불변식 2 가 완충). */
63
+ /** 노드 갱신. `band` = 기존 노드의 행 재지정(B-72 ⓐ 승격) — 기존 컨테이너에서 band 는 **행 identity** 다. */
64
+ /** ⚠ `type` 은 **만들 수 있는 집합**으로 좁다 — read 집합(11)이 아니다(B-87 ⓐ). 타입이 0차 방어다. */
59
65
  | {
60
66
  kind: 'node.update';
61
67
  id: string;
62
68
  name?: string | null;
63
69
  lane?: string;
64
- type?: IrFlowNodeType;
65
- } | {
70
+ type?: AddableFlowNodeType;
71
+ band?: BwlBand;
72
+ }
73
+ /**
74
+ * `source`/`target` = 끝점 재배선(B-6 승격). 한쪽만 줘도 되고(나머지 보존) 새 끝점은
75
+ * **같은 배치에서 추가한 노드여도 된다** — 중간 삽입("A 다음에 X 를 넣어라")이 이것 하나로
76
+ * 표현되어 `element.remove` + 재연결 배치를 강요하지 않는다. resolver 는 `modeling.reconnect`
77
+ * 로 하강하고 경로는 라우터가 재산출한다(기존 벤드포인트는 버린다).
78
+ *
79
+ * ⚠ `messageFlow.update` 에는 아직 없다 — 끝점 이동 수요가 sequenceFlow 로만 관측됐고
80
+ * 어휘는 additive-only(불변식 5)라 나중에 붙이는 비용이 같다.
81
+ */
82
+ | {
66
83
  kind: 'sequenceFlow.update';
67
84
  id: string;
68
85
  name?: string | null;
69
86
  condition?: IrFlowCondition | null;
87
+ source?: string;
88
+ target?: string;
70
89
  } | {
71
90
  kind: 'messageFlow.update';
72
91
  id: string;