Braks
54dfd8498b
feat: add zoom-pane slot
...
* if the user wants to pass a slot into zoom pane
* props are the current width/height and transform values
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-18 13:40:51 +01:00
Braks
b918eb6b89
fix: event propagation from zoom
...
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-18 03:23:36 +01:00
Braks
812a7da2fe
fix: move slots outside of zoom pane
...
* avoids zoom gesture events bubbling to zoom pane and causing elements over flow to trigger zoom when they shouldn't
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-18 03:06:21 +01:00
Braks
43ce52347c
update: invoke until func in zoom pane
...
* instead of using .then cb we use the invoke func to call the async await and wait for the zoomPaneEl
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-17 10:04:28 +01:00
Braks
954722aac2
feat(zoom): Add suspension to zoom pane
...
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-17 09:44:26 +01:00
Braks
10215b4631
update: create vue.d.ts files
...
* add vue-tsc to emit d.ts files from vue components
* use absolute paths in components
* avoids conflicts with ts custom paths in vue-tsc generated vue.d.ts files
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-17 01:39:50 +01:00
Braks
6b4cb9e937
update(docs): README.md
...
* minor updates in zoompane and interaction example
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-17 00:35:21 +01:00
Braks
9b604e7628
fix: pass props to store state
...
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-16 20:04:00 +01:00
Braks
7c66cf5d9b
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 >
2021-11-16 12:58:16 +01:00
Braks
d1dab4cda8
feat: Extend options to pass custom nodes / edges
...
* Accept either a Record<string, Component | boolean> or string[] as nodetypes option
* If bool / string is used a slot will be expected, otherwise no node/edge will be rendered
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-16 09:43:17 +01:00
Braks
ffdadda051
update!: Rename Flow container to VueFlow
...
* Export renamed to VueFlow
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-15 20:34:02 +01:00
Braks
3705a39fa8
refactor: perfomance optimisations through less dependency tracking
...
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-15 11:22:56 +01:00
Braks
066155b9f7
feat: copy default theme css file separately to dist
...
* to enable overwriting the default theme export it separately
* add rollup plugin copy for copying the css file
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-06 15:42:05 +01:00
Braks
aaf5f608f5
feat: add path alias for src
...
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-06 09:38:02 +01:00
Braks
5437d48325
fix: custom node example not fitting view
...
* fit view can't work (for the onLoad event) for elements assigned after the host has mounted (onMounted hook) as we can't calculate a rect of elements that don't exist at flow creation
* in this case just trigger fit view __after__ elements have been created/passed to the flow
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-06 08:54:35 +01:00
Braks
a8f7cc2389
fix: zoom pane not scaling
...
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-06 08:54:35 +01:00
Braks
3931a59524
fix(docs): dedupe and add alias for vue
...
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-11-06 08:54:35 +01:00
Braks
e99dfc3dd2
update(docs): Add all examples
2021-11-06 08:54:35 +01:00
Braks
61779638ac
update(dist): Remove rollup and use vite to build lib
...
* Remove custom tsconfig paths to avoid resolving issues on published package
2021-11-06 08:54:35 +01:00
Braks
64df75d405
feat(docs): Initial commit for docs in nuxt 3
2021-11-06 08:54:35 +01:00
Braks
6ec8258f33
fix: typings
2021-10-22 14:29:27 +02:00
Braks
babcbd0e1f
update: Flow instance provides update node internals func
...
* Rename onLoadParams to FlowInstance
* Pass update node internals to instance
2021-10-22 12:39:55 +02:00
Braks
0a45e09c32
feat: Add node/edge types id
...
* ID can be used to switch between different types of nodes/edges
* Add example
2021-10-22 08:49:53 +02:00
Braks
26b3901bd5
fix: node not updating handlebounds when handle pos changes
...
* watch source & target pos and update node dimensions on next tick
2021-10-22 08:16:32 +02:00
Braks
20e9d1d396
update: fix names
2021-10-21 17:42:33 +02:00
Braks
cd02dd0444
fix: node type change not triggering recalculation of node dimensions
2021-10-21 16:23:23 +02:00
Braks
6d197d7f2a
update: remove nodes selection props
2021-10-21 14:38:27 +02:00
Braks
0e79718720
update: Add validConnectFunc as prop to handle
2021-10-21 14:28:11 +02:00
Braks
ca2901bc01
fix: zoom pan helper not being initialized timely
2021-10-21 13:46:15 +02:00
Braks
77d2e01fc0
update: types
...
* Add elements to flowoptions type
* add window interface to custom shims
2021-10-21 00:24:59 +02:00
Braks
5f500bca18
fix: store actions blocking main thread
...
* map function overwriting nodes causes main thread to be blocked
* instead use splice
2021-10-20 23:46:47 +02:00
Braks
ff7ee5c7fe
fix: label type in edges
2021-10-20 23:09:36 +02:00
Braks
2bfecf7148
update: change name to vue flow
...
* Add gif to readme
Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com >
2021-10-20 22:39:54 +02:00
Braks
64a4b8c418
fix: nodes as fragments
...
feat: accept vnode as edge text
2021-10-20 22:39:54 +02:00
Braks
b2b1fe822f
feat: add useStore and useHooks composables that provide default store/hooks
2021-10-20 22:39:54 +02:00
Braks
61dc9dea33
fix: edges and edge anchors not re-calculating correctly
2021-10-20 22:39:54 +02:00
Braks
7ecbcba7eb
fix: edge anchor
2021-10-20 22:39:54 +02:00
Braks
8c54daedc0
feat: scope edge and node slots by name
...
* node, edge names slots scoped as `edge/node-${edge/node-type}`
2021-10-20 22:39:54 +02:00
Braks
9d9a90e9a7
update: Add slots to CustomConnectionLine.vue, Edge.vue, Node.vue
2021-10-20 22:39:54 +02:00
Braks
cfc8f7782f
update: remove render tracking hooks
2021-10-20 22:39:54 +02:00
Braks
17f2517ab4
fix: too many re-render on edges and nodes
2021-10-20 22:39:54 +02:00
Braks
fede792a37
fix: correct event listeners in examples
2021-10-20 22:39:54 +02:00
Braks
c3fb3cd10a
fix: zoom pan helper
2021-10-20 22:39:54 +02:00
Braks
a895853b64
update: Add injection keys
2021-10-20 22:39:54 +02:00
Braks
6b4e7ab3ce
fix: Minimap
2021-10-20 22:39:54 +02:00
Braks
29c6df1755
update(examples): Fix examples
2021-10-20 22:39:54 +02:00
Braks
a5ae6a4e48
update(deps): Add unplugin-components
...
fix: Excessive rerender of edge texts
update(script-setup): Update some examples
* Remove more jsx files
2021-10-20 22:39:54 +02:00
Braks
1ff3a8dc9c
update(script-setup): Refactor additional-components
...
* Remove jsx files
fix: ConnectionLine.vue not recalculating properly
2021-10-20 22:39:54 +02:00
Braks
560bdc203b
update(script-setup): Refactor remaining files to script setup style
2021-10-20 22:39:54 +02:00
Braks
9b2f4b7406
fix: return transform from useZoom
2021-10-20 22:39:54 +02:00