@flowgram.ai/free-layout-core 0.1.0-alpha.36 → 0.1.0-alpha.38
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/dist/esm/index.js +277 -18
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +277 -18
- package/dist/index.js.map +1 -1
- package/dist/typings/index.d.mts +1 -1
- package/dist/typings/index.d.ts +1 -1
- package/dist/typings/workflow-drag.d.mts +1 -1
- package/dist/typings/workflow-drag.d.ts +1 -1
- package/dist/typings/workflow-json.d.mts +1 -1
- package/dist/typings/workflow-json.d.ts +1 -1
- package/dist/typings/workflow-line.d.mts +1 -1
- package/dist/typings/workflow-line.d.ts +1 -1
- package/dist/typings/workflow-node.d.mts +1 -1
- package/dist/typings/workflow-node.d.ts +1 -1
- package/dist/typings/workflow-operation.d.mts +1 -1
- package/dist/typings/workflow-operation.d.ts +1 -1
- package/dist/typings/workflow-registry.d.mts +1 -1
- package/dist/typings/workflow-registry.d.ts +1 -1
- package/dist/typings/workflow-sub-canvas.d.mts +1 -1
- package/dist/typings/workflow-sub-canvas.d.ts +1 -1
- package/dist/{workflow-node-entity-DcXjib68.d.mts → workflow-node-entity-BQBXdOoa.d.mts} +19 -1
- package/dist/{workflow-node-entity-_7O7-wJE.d.ts → workflow-node-entity-Da9FrkWn.d.ts} +19 -1
- package/package.json +9 -9
package/dist/typings/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { L as LineCenterPoint, y as LineColor, z as LineColors, g as LineEventProps, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory, h as WorkflowNodeJSON, u as WorkflowNodeMeta, B as WorkflowSubCanvas, F as onDragLineEndParams } from '../workflow-node-entity-
|
|
1
|
+
export { L as LineCenterPoint, y as LineColor, z as LineColors, g as LineEventProps, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory, h as WorkflowNodeJSON, u as WorkflowNodeMeta, B as WorkflowSubCanvas, F as onDragLineEndParams } from '../workflow-node-entity-BQBXdOoa.mjs';
|
|
2
2
|
export { WorkflowEdgeJSON } from './workflow-edge.mjs';
|
|
3
3
|
export { WorkflowNodeFormMeta, WorkflowNodeRegistry, WorkflowNodeRenderProps } from './workflow-registry.mjs';
|
|
4
4
|
export { NodePostionUpdateEvent, WorkflowOperationBaseService } from './workflow-operation.mjs';
|
package/dist/typings/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { L as LineCenterPoint, y as LineColor, z as LineColors, g as LineEventProps, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory, h as WorkflowNodeJSON, u as WorkflowNodeMeta, B as WorkflowSubCanvas, F as onDragLineEndParams } from '../workflow-node-entity-
|
|
1
|
+
export { L as LineCenterPoint, y as LineColor, z as LineColors, g as LineEventProps, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory, h as WorkflowNodeJSON, u as WorkflowNodeMeta, B as WorkflowSubCanvas, F as onDragLineEndParams } from '../workflow-node-entity-Da9FrkWn.js';
|
|
2
2
|
export { WorkflowEdgeJSON } from './workflow-edge.js';
|
|
3
3
|
export { WorkflowNodeFormMeta, WorkflowNodeRegistry, WorkflowNodeRenderProps } from './workflow-registry.js';
|
|
4
4
|
export { NodePostionUpdateEvent, WorkflowOperationBaseService } from './workflow-operation.js';
|
|
@@ -2,6 +2,6 @@ import 'react';
|
|
|
2
2
|
import '@flowgram.ai/utils';
|
|
3
3
|
import '@flowgram.ai/document';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
5
|
-
export { g as LineEventProps, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, F as onDragLineEndParams } from '../workflow-node-entity-
|
|
5
|
+
export { g as LineEventProps, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, F as onDragLineEndParams } from '../workflow-node-entity-BQBXdOoa.mjs';
|
|
6
6
|
import '@flowgram.ai/form-core';
|
|
7
7
|
import './workflow-edge.mjs';
|
|
@@ -2,6 +2,6 @@ import 'react';
|
|
|
2
2
|
import '@flowgram.ai/utils';
|
|
3
3
|
import '@flowgram.ai/document';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
5
|
-
export { g as LineEventProps, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, F as onDragLineEndParams } from '../workflow-node-entity-
|
|
5
|
+
export { g as LineEventProps, D as NodesDragEndEvent, N as NodesDragEvent, C as NodesDragStartEvent, E as NodesDraggingEvent, O as OnDragLineEnd, F as onDragLineEndParams } from '../workflow-node-entity-Da9FrkWn.js';
|
|
6
6
|
import '@flowgram.ai/form-core';
|
|
7
7
|
import './workflow-edge.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON } from '../workflow-node-entity-
|
|
1
|
+
export { t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON } from '../workflow-node-entity-BQBXdOoa.mjs';
|
|
2
2
|
import './workflow-edge.mjs';
|
|
3
3
|
import '@flowgram.ai/document';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON } from '../workflow-node-entity-
|
|
1
|
+
export { t as WorkflowContentChangeEvent, s as WorkflowContentChangeType, W as WorkflowJSON } from '../workflow-node-entity-Da9FrkWn.js';
|
|
2
2
|
import './workflow-edge.js';
|
|
3
3
|
import '@flowgram.ai/document';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@flowgram.ai/utils';
|
|
2
|
-
export { L as LineCenterPoint, y as LineColor, z as LineColors, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory } from '../workflow-node-entity-
|
|
2
|
+
export { L as LineCenterPoint, y as LineColor, z as LineColors, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory } from '../workflow-node-entity-BQBXdOoa.mjs';
|
|
3
3
|
import '@flowgram.ai/document';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
5
5
|
import 'react';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import '@flowgram.ai/utils';
|
|
2
|
-
export { L as LineCenterPoint, y as LineColor, z as LineColors, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory } from '../workflow-node-entity-
|
|
2
|
+
export { L as LineCenterPoint, y as LineColor, z as LineColors, x as LinePoint, w as LinePointLocation, m as LinePosition, k as LineRenderType, v as LineType, l as WorkflowLineRenderContribution, A as WorkflowLineRenderContributionFactory } from '../workflow-node-entity-Da9FrkWn.js';
|
|
3
3
|
import '@flowgram.ai/document';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
5
5
|
import 'react';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import '@flowgram.ai/utils';
|
|
2
2
|
import '@flowgram.ai/document';
|
|
3
|
-
export { h as WorkflowNodeJSON, u as WorkflowNodeMeta } from '../workflow-node-entity-
|
|
3
|
+
export { h as WorkflowNodeJSON, u as WorkflowNodeMeta } from '../workflow-node-entity-BQBXdOoa.mjs';
|
|
4
4
|
import './workflow-edge.mjs';
|
|
5
5
|
import '@flowgram.ai/core';
|
|
6
6
|
import 'react';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import '@flowgram.ai/utils';
|
|
2
2
|
import '@flowgram.ai/document';
|
|
3
|
-
export { h as WorkflowNodeJSON, u as WorkflowNodeMeta } from '../workflow-node-entity-
|
|
3
|
+
export { h as WorkflowNodeJSON, u as WorkflowNodeMeta } from '../workflow-node-entity-Da9FrkWn.js';
|
|
4
4
|
import './workflow-edge.js';
|
|
5
5
|
import '@flowgram.ai/core';
|
|
6
6
|
import 'react';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IPoint, Event } from '@flowgram.ai/utils';
|
|
2
2
|
import { FlowNodeEntity, FlowOperationBaseService, FlowNodeEntityOrId } from '@flowgram.ai/document';
|
|
3
|
-
import { W as WorkflowJSON } from '../workflow-node-entity-
|
|
3
|
+
import { W as WorkflowJSON } from '../workflow-node-entity-BQBXdOoa.mjs';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
5
5
|
import 'react';
|
|
6
6
|
import '@flowgram.ai/form-core';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IPoint, Event } from '@flowgram.ai/utils';
|
|
2
2
|
import { FlowNodeEntity, FlowOperationBaseService, FlowNodeEntityOrId } from '@flowgram.ai/document';
|
|
3
|
-
import { W as WorkflowJSON } from '../workflow-node-entity-
|
|
3
|
+
import { W as WorkflowJSON } from '../workflow-node-entity-Da9FrkWn.js';
|
|
4
4
|
import '@flowgram.ai/core';
|
|
5
5
|
import 'react';
|
|
6
6
|
import '@flowgram.ai/form-core';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FormMeta } from '@flowgram.ai/node';
|
|
2
2
|
import { FormMetaOrFormMetaGenerator } from '@flowgram.ai/form-core';
|
|
3
3
|
import { FlowNodeRegistry } from '@flowgram.ai/document';
|
|
4
|
-
import { u as WorkflowNodeMeta, i as WorkflowPortEntity, d as WorkflowLinesManager, b as WorkflowNodeEntity } from '../workflow-node-entity-
|
|
4
|
+
import { u as WorkflowNodeMeta, i as WorkflowPortEntity, d as WorkflowLinesManager, b as WorkflowNodeEntity } from '../workflow-node-entity-BQBXdOoa.mjs';
|
|
5
5
|
import '@flowgram.ai/core';
|
|
6
6
|
import '@flowgram.ai/utils';
|
|
7
7
|
import 'react';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { FormMeta } from '@flowgram.ai/node';
|
|
2
2
|
import { FormMetaOrFormMetaGenerator } from '@flowgram.ai/form-core';
|
|
3
3
|
import { FlowNodeRegistry } from '@flowgram.ai/document';
|
|
4
|
-
import { u as WorkflowNodeMeta, i as WorkflowPortEntity, d as WorkflowLinesManager, b as WorkflowNodeEntity } from '../workflow-node-entity-
|
|
4
|
+
import { u as WorkflowNodeMeta, i as WorkflowPortEntity, d as WorkflowLinesManager, b as WorkflowNodeEntity } from '../workflow-node-entity-Da9FrkWn.js';
|
|
5
5
|
import '@flowgram.ai/core';
|
|
6
6
|
import '@flowgram.ai/utils';
|
|
7
7
|
import 'react';
|
|
@@ -589,6 +589,10 @@ declare class WorkflowLinesManager {
|
|
|
589
589
|
private hoverNodesCache?;
|
|
590
590
|
private hoverNodesCacheVersion?;
|
|
591
591
|
private hoverNodesCacheActivatedID?;
|
|
592
|
+
private sortedNodeSpatialCache?;
|
|
593
|
+
private hoverNodeSpatialCache?;
|
|
594
|
+
private lineSpatialCache?;
|
|
595
|
+
private outsidePortNodesCache?;
|
|
592
596
|
hoverService: WorkflowHoverService;
|
|
593
597
|
selectService: WorkflowSelectService;
|
|
594
598
|
protected readonly entityManager: EntityManager;
|
|
@@ -672,12 +676,26 @@ declare class WorkflowLinesManager {
|
|
|
672
676
|
registerContribution(factory: WorkflowLineRenderContributionFactory): this;
|
|
673
677
|
private registerData;
|
|
674
678
|
private getSortedNodes;
|
|
679
|
+
private invalidateNodeHitCaches;
|
|
680
|
+
private invalidateLineHitCache;
|
|
681
|
+
private invalidateSpatialHitCaches;
|
|
675
682
|
private getHoveredPortFromSortedNodes;
|
|
676
683
|
private getHoveredPortsFromSortedNodes;
|
|
677
|
-
private
|
|
684
|
+
private collectHoveredPorts;
|
|
678
685
|
private filterCoveredPort;
|
|
679
686
|
private getTopNodeFromSortedNodes;
|
|
680
687
|
private getNodeHitInfoFromSortedNodes;
|
|
688
|
+
private getHoverNodeHitCandidates;
|
|
689
|
+
private getSortedNodeHitCandidates;
|
|
690
|
+
private getLineHitCandidates;
|
|
691
|
+
private createSpatialIndex;
|
|
692
|
+
private querySpatialIndex;
|
|
693
|
+
private getSpatialCell;
|
|
694
|
+
private getSpatialCellKey;
|
|
695
|
+
private canIndexBounds;
|
|
696
|
+
private isPointNearNodePorts;
|
|
697
|
+
private hasPortOutsideNodeBounds;
|
|
698
|
+
private getOutsidePortNodes;
|
|
681
699
|
private getHoverNodes;
|
|
682
700
|
private isPointInBounds;
|
|
683
701
|
private getNodeIndex;
|
|
@@ -589,6 +589,10 @@ declare class WorkflowLinesManager {
|
|
|
589
589
|
private hoverNodesCache?;
|
|
590
590
|
private hoverNodesCacheVersion?;
|
|
591
591
|
private hoverNodesCacheActivatedID?;
|
|
592
|
+
private sortedNodeSpatialCache?;
|
|
593
|
+
private hoverNodeSpatialCache?;
|
|
594
|
+
private lineSpatialCache?;
|
|
595
|
+
private outsidePortNodesCache?;
|
|
592
596
|
hoverService: WorkflowHoverService;
|
|
593
597
|
selectService: WorkflowSelectService;
|
|
594
598
|
protected readonly entityManager: EntityManager;
|
|
@@ -672,12 +676,26 @@ declare class WorkflowLinesManager {
|
|
|
672
676
|
registerContribution(factory: WorkflowLineRenderContributionFactory): this;
|
|
673
677
|
private registerData;
|
|
674
678
|
private getSortedNodes;
|
|
679
|
+
private invalidateNodeHitCaches;
|
|
680
|
+
private invalidateLineHitCache;
|
|
681
|
+
private invalidateSpatialHitCaches;
|
|
675
682
|
private getHoveredPortFromSortedNodes;
|
|
676
683
|
private getHoveredPortsFromSortedNodes;
|
|
677
|
-
private
|
|
684
|
+
private collectHoveredPorts;
|
|
678
685
|
private filterCoveredPort;
|
|
679
686
|
private getTopNodeFromSortedNodes;
|
|
680
687
|
private getNodeHitInfoFromSortedNodes;
|
|
688
|
+
private getHoverNodeHitCandidates;
|
|
689
|
+
private getSortedNodeHitCandidates;
|
|
690
|
+
private getLineHitCandidates;
|
|
691
|
+
private createSpatialIndex;
|
|
692
|
+
private querySpatialIndex;
|
|
693
|
+
private getSpatialCell;
|
|
694
|
+
private getSpatialCellKey;
|
|
695
|
+
private canIndexBounds;
|
|
696
|
+
private isPointNearNodePorts;
|
|
697
|
+
private hasPortOutsideNodeBounds;
|
|
698
|
+
private getOutsidePortNodes;
|
|
681
699
|
private getHoverNodes;
|
|
682
700
|
private isPointInBounds;
|
|
683
701
|
private getNodeIndex;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@flowgram.ai/free-layout-core",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.38",
|
|
4
4
|
"homepage": "https://flowgram.ai/",
|
|
5
5
|
"repository": "https://github.com/bytedance/flowgram.ai",
|
|
6
6
|
"license": "MIT",
|
|
@@ -34,12 +34,12 @@
|
|
|
34
34
|
"reflect-metadata": "~0.2.2",
|
|
35
35
|
"lodash-es": "^4.17.21",
|
|
36
36
|
"nanoid": "^5.0.9",
|
|
37
|
-
"@flowgram.ai/core": "0.1.0-alpha.
|
|
38
|
-
"@flowgram.ai/
|
|
39
|
-
"@flowgram.ai/form-core": "0.1.0-alpha.
|
|
40
|
-
"@flowgram.ai/
|
|
41
|
-
"@flowgram.ai/
|
|
42
|
-
"@flowgram.ai/utils": "0.1.0-alpha.
|
|
37
|
+
"@flowgram.ai/core": "0.1.0-alpha.38",
|
|
38
|
+
"@flowgram.ai/node": "0.1.0-alpha.38",
|
|
39
|
+
"@flowgram.ai/form-core": "0.1.0-alpha.38",
|
|
40
|
+
"@flowgram.ai/reactive": "0.1.0-alpha.38",
|
|
41
|
+
"@flowgram.ai/document": "0.1.0-alpha.38",
|
|
42
|
+
"@flowgram.ai/utils": "0.1.0-alpha.38"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
45
|
"@testing-library/react": "^12",
|
|
@@ -53,8 +53,8 @@
|
|
|
53
53
|
"tsup": "^8.0.1",
|
|
54
54
|
"typescript": "^5.8.3",
|
|
55
55
|
"vitest": "^3.2.4",
|
|
56
|
-
"@flowgram.ai/eslint-config": "0.1.0-alpha.
|
|
57
|
-
"@flowgram.ai/ts-config": "0.1.0-alpha.
|
|
56
|
+
"@flowgram.ai/eslint-config": "0.1.0-alpha.38",
|
|
57
|
+
"@flowgram.ai/ts-config": "0.1.0-alpha.38"
|
|
58
58
|
},
|
|
59
59
|
"peerDependencies": {
|
|
60
60
|
"react": ">=16.8",
|