update!: Remove update node internals composable
* It's practically useless as vue doesn't need the trigger to catch a re-render * Remove unused types Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
@@ -1,28 +0,0 @@
|
||||
import { Ref } from 'vue'
|
||||
import { ElementId, FlowTransform } from './types'
|
||||
import { D3Zoom, D3Selection, PanOnScrollMode, KeyCode } from './panel'
|
||||
import { Connection } from './connection'
|
||||
|
||||
export type UpdateNodeInternals = (nodeId: ElementId) => void
|
||||
|
||||
export interface UseZoomOptions {
|
||||
selectionKeyCode?: KeyCode
|
||||
zoomActivationKeyCode?: KeyCode
|
||||
paneMoveable?: boolean
|
||||
defaultZoom?: number
|
||||
defaultPosition?: [number, number]
|
||||
zoomOnScroll?: boolean
|
||||
zoomOnPinch?: boolean
|
||||
panOnScroll?: boolean
|
||||
panOnScrollSpeed?: number
|
||||
panOnScrollMode?: PanOnScrollMode
|
||||
zoomOnDoubleClick?: boolean
|
||||
}
|
||||
|
||||
export interface UseZoom {
|
||||
transform: Ref<FlowTransform>
|
||||
d3Zoom: Ref<D3Zoom>
|
||||
d3Selection: Ref<D3Selection>
|
||||
}
|
||||
|
||||
export type ValidConnectionFunc = (connection: Connection) => boolean
|
||||
@@ -1,6 +1,5 @@
|
||||
import { DefineComponent } from 'vue'
|
||||
import { ArrowHeadType, ElementId, Position } from './types'
|
||||
import { Connection } from './connection'
|
||||
|
||||
export interface Edge<T = any> {
|
||||
id: ElementId
|
||||
@@ -65,8 +64,6 @@ export interface EdgeSmoothStepProps<T = any> extends EdgeProps<T> {
|
||||
|
||||
export type EdgeType = DefineComponent<EdgeSmoothStepProps, any, any, any, any, any> | boolean
|
||||
|
||||
export type OnEdgeUpdateFunc<T = any> = (oldEdge: Edge<T>, newConnection: Connection) => void
|
||||
|
||||
export interface EdgePositions {
|
||||
sourceX: number
|
||||
sourceY: number
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import { Dimensions, ElementId, Position, XYPosition } from './types'
|
||||
import { Connection } from '~/types/connection'
|
||||
|
||||
export type HandleType = 'source' | 'target'
|
||||
|
||||
@@ -6,3 +7,5 @@ export interface HandleElement extends XYPosition, Dimensions {
|
||||
id?: ElementId | null
|
||||
position: Position
|
||||
}
|
||||
|
||||
export type ValidConnectionFunc = (connection: Connection) => boolean
|
||||
|
||||
@@ -7,4 +7,3 @@ export * from './node'
|
||||
export * from './panel'
|
||||
export * from './store'
|
||||
export * from './hooks'
|
||||
export * from './composables'
|
||||
|
||||
@@ -86,11 +86,8 @@ export type FlowInstance<T = any> = {
|
||||
getElements: () => Elements<T>
|
||||
setTransform: (transform: FlowTransform) => void
|
||||
toObject: ToObjectFunc<T>
|
||||
updateNodeInternals: (id: ElementId) => void
|
||||
}
|
||||
|
||||
export type OnLoadFunc<T = any> = (params: FlowInstance<T>) => void
|
||||
|
||||
export interface FlowOptions extends Omit<HTMLAttributes, 'onLoad'> {
|
||||
elements: Elements
|
||||
nodeTypes?: Record<string, NodeType> | string[]
|
||||
|
||||
Reference in New Issue
Block a user