@logicflow/core
Advanced tools
Comparing version 1.2.15 to 1.2.16
{ | ||
"name": "@logicflow/core", | ||
"version": "1.2.15", | ||
"version": "1.2.16", | ||
"description": "LogicFlow core, to quickly build flowchart editor", | ||
@@ -5,0 +5,0 @@ "main": "dist/entry.js", |
@@ -39,2 +39,3 @@ export declare enum ElementState { | ||
NODE_ADD = "node:add", | ||
NODE_GROUP_COPY = "node:group-copy-add", | ||
NODE_DND_ADD = "node:dnd-add", | ||
@@ -41,0 +42,0 @@ NODE_DND_DRAG = "node:dnd-drag", |
@@ -343,3 +343,3 @@ import GraphModel from './model/GraphModel'; | ||
*/ | ||
addElements({ nodes, edges }: GraphConfigData): GraphConfigModel; | ||
addElements({ nodes, edges }: GraphConfigData, distance?: number): GraphConfigModel; | ||
/** | ||
@@ -401,8 +401,2 @@ * 获取指定区域内的所有元素,此区域必须是DOM层。 | ||
domOverlayPosition: { | ||
/** | ||
* 将图形选中 | ||
* @param id 选择元素ID | ||
* @param multiple 是否允许多选,如果为true,不会将上一个选中的元素重置 | ||
* @param toFront 是否将选中的元素置顶,默认为true | ||
*/ | ||
x: number; | ||
@@ -409,0 +403,0 @@ y: number; |
@@ -66,2 +66,6 @@ import BaseNodeModel from './node/BaseNodeModel'; | ||
/** | ||
* 获取自定义连线轨迹 | ||
*/ | ||
customTrajectory: Definition['customTrajectory']; | ||
/** | ||
* 在图上操作创建边时,默认使用的边类型. | ||
@@ -68,0 +72,0 @@ */ |
@@ -56,4 +56,6 @@ import { OutlineTheme } from '../../constant/DefaultTheme'; | ||
style: ShapeStyleAttribute; | ||
gMatrix: string; | ||
rotate: number; | ||
transform: string; | ||
private _rotate; | ||
set rotate(value: number); | ||
get rotate(): number; | ||
readonly BaseType = ElementType.NODE; | ||
@@ -60,0 +62,0 @@ modelType: ModelType; |
@@ -0,4 +1,5 @@ | ||
import { VNode } from 'preact'; | ||
import { GridOptions } from './view/overlay/Grid'; | ||
import { BackgroundConfig } from './view/overlay/BackgroundOverlay'; | ||
import { NodeData, EdgeData, Extension, GraphConfigData } from './type'; | ||
import { NodeData, EdgeData, Extension, GraphConfigData, Point } from './type'; | ||
import { KeyboardDef } from './keyboard'; | ||
@@ -115,4 +116,10 @@ import { EditConfigInterface } from './model/EditConfigModel'; | ||
edgeGenerator?: (sourceNode: any, targetNode: any, currentEdge?: any) => string | any | undefined; | ||
customTrajectory?: (props: CustomAnchorLineProps) => VNode; | ||
[key: string]: any; | ||
} & EditConfigInterface; | ||
export interface CustomAnchorLineProps { | ||
sourcePoint: Point; | ||
targetPoint: Point; | ||
[key: string]: any; | ||
} | ||
export interface GuardsTypes { | ||
@@ -226,2 +233,3 @@ beforeClone?: (data: NodeData | GraphConfigData) => boolean; | ||
edgeGenerator?: (sourceNode: any, targetNode: any, currentEdge?: any) => any; | ||
customTrajectory?: (props: CustomAnchorLineProps) => VNode<{}>; | ||
} & EditConfigInterface; | ||
@@ -228,0 +236,0 @@ export declare const defaults: { |
@@ -86,2 +86,3 @@ import { h } from 'preact'; | ||
properties?: Record<string, unknown>; | ||
[key: string]: any; | ||
}; | ||
@@ -88,0 +89,0 @@ export declare type NodeData = { |
@@ -7,2 +7,3 @@ import { h, Component } from 'preact'; | ||
import { BaseNode } from './node'; | ||
import { BaseEdgeModel } from '../model'; | ||
declare type TargetNodeId = string; | ||
@@ -44,3 +45,4 @@ interface IProps { | ||
}) => void; | ||
checkEnd: (event: any) => void; | ||
get customTrajectory(): (props: import("..").CustomAnchorLineProps) => import("preact").VNode<{}>; | ||
checkEnd: (event: MouseEvent) => BaseEdgeModel | null; | ||
moveAnchorEnd(endX: number, endY: number): void; | ||
@@ -47,0 +49,0 @@ isShowLine(): boolean; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1343580
5662