@logicflow/extension 1.1.0-alpha.2 → 1.1.0-alpha.3
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/cjs/materials/group/GroupNode.js +66 -20
- package/cjs/materials/group/index.js +28 -9
- package/cjs/style/index.css +3 -2
- package/es/materials/group/GroupNode.d.ts +24 -9
- package/es/materials/group/GroupNode.js +67 -21
- package/es/materials/group/index.d.ts +3 -1
- package/es/materials/group/index.js +27 -9
- package/es/style/index.css +3 -2
- package/lib/AutoLayout.js +1 -1
- package/lib/BpmnAdapter.js +1 -1
- package/lib/BpmnElement.js +1 -1
- package/lib/ContextMenu.js +1 -1
- package/lib/Control.js +1 -1
- package/lib/CurvedEdge.js +1 -1
- package/lib/DndPanel.js +1 -1
- package/lib/FlowPath.js +1 -1
- package/lib/Group.js +1 -1
- package/lib/InsertNodeInPolyline.js +1 -1
- package/lib/Menu.js +1 -1
- package/lib/MiniMap.js +1 -1
- package/lib/NodeResize.js +1 -1
- package/lib/RectLabelNode.js +1 -1
- package/lib/SelectionSelect.js +1 -1
- package/lib/Snapshot.js +1 -1
- package/lib/TurboAdapter.js +1 -1
- package/lib/lfJson2Xml.js +1 -1
- package/lib/lfXml2Json.js +1 -1
- package/lib/style/index.css +3 -2
- package/package.json +1 -1
- package/types/materials/group/GroupNode.d.ts +24 -9
- package/types/materials/group/index.d.ts +3 -1
|
@@ -1,13 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { h } from '@logicflow/core';
|
|
2
|
+
import { RectResize } from '../../NodeResize';
|
|
3
|
+
declare class GroupNodeModel extends RectResize.model {
|
|
3
4
|
readonly isGroup = true;
|
|
4
|
-
children: Set<
|
|
5
|
+
children: Set<string>;
|
|
5
6
|
isRestrict: boolean;
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
* 设置是否允许子节点被拖动移除分组
|
|
9
|
-
*/
|
|
10
|
-
setIsRestrict(isRestrict: any): void;
|
|
7
|
+
resizable: boolean;
|
|
8
|
+
initNodeData(data: any): void;
|
|
11
9
|
isInRange({ x1, y1, x2, y2 }: {
|
|
12
10
|
x1: any;
|
|
13
11
|
y1: any;
|
|
@@ -15,15 +13,32 @@ declare class GroupNodeModel extends RectNodeModel {
|
|
|
15
13
|
y2: any;
|
|
16
14
|
}): boolean;
|
|
17
15
|
setAllowAppendChild(isAllow: any): void;
|
|
16
|
+
/**
|
|
17
|
+
* 添加分组子节点
|
|
18
|
+
* @param id 节点id
|
|
19
|
+
*/
|
|
18
20
|
addChild(id: any): void;
|
|
21
|
+
/**
|
|
22
|
+
* 删除分组子节点
|
|
23
|
+
* @param id 节点id
|
|
24
|
+
*/
|
|
19
25
|
removeChild(id: any): void;
|
|
26
|
+
getAddableOutlineStyle(): {
|
|
27
|
+
stroke: string;
|
|
28
|
+
strokeWidth: number;
|
|
29
|
+
strokeDasharray: string;
|
|
30
|
+
fill: string;
|
|
31
|
+
};
|
|
20
32
|
getData(): import("@logicflow/core").NodeData;
|
|
21
33
|
}
|
|
22
|
-
declare class GroupNode extends
|
|
34
|
+
declare class GroupNode extends RectResize.view {
|
|
23
35
|
/**
|
|
24
36
|
* 重新toFront,阻止其置顶
|
|
25
37
|
*/
|
|
26
38
|
toFront(): void;
|
|
39
|
+
getControlGroup(): h.JSX.Element;
|
|
40
|
+
getAddedableShape(): import("preact").VNode<any>;
|
|
41
|
+
getResizeShape(): import("preact").VNode<any>;
|
|
27
42
|
}
|
|
28
43
|
declare const _default: {
|
|
29
44
|
type: string;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import LogicFlow, { BaseNodeModel } from '@logicflow/core';
|
|
2
|
+
import GroupNode from './GroupNode';
|
|
2
3
|
declare type BaseNodeId = string;
|
|
3
4
|
declare type GroupId = string;
|
|
4
5
|
declare type Bounds = {
|
|
@@ -15,6 +16,7 @@ declare class Group {
|
|
|
15
16
|
constructor({ lf }: {
|
|
16
17
|
lf: any;
|
|
17
18
|
});
|
|
19
|
+
graphRendered: (data: any) => void;
|
|
18
20
|
appendNodeToGrop: ({ data }: {
|
|
19
21
|
data: any;
|
|
20
22
|
}) => void;
|
|
@@ -27,4 +29,4 @@ declare class Group {
|
|
|
27
29
|
*/
|
|
28
30
|
getGroup(bounds: Bounds): BaseNodeModel | undefined;
|
|
29
31
|
}
|
|
30
|
-
export { Group };
|
|
32
|
+
export { Group, GroupNode, };
|