chore: move BaseEdgeProps to types

This commit is contained in:
bcakmakoglu
2022-06-10 15:54:40 +02:00
committed by Braks
parent 699e252935
commit e54f7b56d0
4 changed files with 19 additions and 27 deletions
@@ -1,20 +1,6 @@
import type { CSSProperties, FunctionalComponent } from 'vue'
import type { FunctionalComponent } from 'vue'
import EdgeText from './EdgeText.vue'
export interface BaseEdgeProps {
centerX: number
centerY: number
path: string
label?: any
style?: CSSProperties
labelStyle?: any
labelShowBg?: boolean
labelBgStyle?: any
labelBgPadding?: [number, number]
labelBgBorderRadius?: number
markerStart?: string
markerEnd?: string
}
import type { BaseEdgeProps } from '~/types'
/**
* The base edge is a simple wrapper for svg path
@@ -1,4 +1,4 @@
export { default as BaseEdge, BaseEdgeProps } from './BaseEdge'
export { default as BaseEdge } from './BaseEdge'
export { default as BezierEdge } from './BezierEdge'
export { default as SimpleBezierEdge } from './SimpleBezierEdge'
export { default as StepEdge } from './StepEdge'
+1 -10
View File
@@ -2,16 +2,7 @@ export { default as VueFlow } from './container/VueFlow/VueFlow.vue'
export { default as Handle } from './components/Handle/Handle.vue'
export {
StraightEdge,
StepEdge,
BezierEdge,
SimpleBezierEdge,
SmoothStepEdge,
BaseEdge,
BaseEdgeProps,
EdgeText,
} from './components/Edges'
export { StraightEdge, StepEdge, BezierEdge, SimpleBezierEdge, SmoothStepEdge, BaseEdge, EdgeText } from './components/Edges'
export {
getBezierPath,
+15
View File
@@ -166,3 +166,18 @@ export interface SmoothStepEdgeProps<Data = ElementData> extends EdgeProps<Data>
markerEnd?: string
borderRadius?: number
}
export interface BaseEdgeProps {
centerX: number
centerY: number
path: string
label?: any
style?: CSSProperties
labelStyle?: any
labelShowBg?: boolean
labelBgStyle?: any
labelBgPadding?: [number, number]
labelBgBorderRadius?: number
markerStart?: string
markerEnd?: string
}