refactor(flow)!: Use watcher to change every prop as a single item

* instead of replacing the whole state on each watch trigger, split into multiple watchers that set a single state
* improve reacitivty and two-way binding for v-models
* remove elements option -> only modelValue (old api) or nodes/edges

Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
Braks
2021-12-20 19:29:52 +01:00
parent cc7cedfda0
commit f8a23c59ec
9 changed files with 284 additions and 91 deletions
+2 -3
View File
@@ -62,13 +62,12 @@ export interface NodeProps<T = any> {
source?: HandleElement[]
target?: HandleElement[]
}
// todo plugin not allowing for nested types currently
parentNode?: any
parentNode?: GraphNode[]
isParent?: boolean
computedPosition: XYZPosition
position: XYPosition
draggable?: boolean
selectable?: boolean
children?: any[]
children?: Node[]
dimensions?: Dimensions
}