docs: update docs and mention removed edge center functions

This commit is contained in:
braks
2022-10-08 15:19:10 +02:00
committed by Braks
parent b1e56f0403
commit 42219d3640
2 changed files with 15 additions and 11 deletions

View File

@@ -3,7 +3,7 @@
All default edge components are exported and can be used or extended if necessary.
```vue
<script setup>
<script lang="ts" setup>
// CustomEdge.vue
import { EdgeProps, BezierEdge } from '@vue-flow/core'
@@ -29,9 +29,13 @@ regular edge behavior.
- Details:
Returns a bezier path.
Returns a bezier path and center positions.
### [getBezierCenter](/typedocs/functions/getBezierCenter)
### getBezierCenter (removed)
::: warning
This function has been removed. The edge center positions are returned by `getBezierPath` now.
:::
- Details:
@@ -41,9 +45,13 @@ regular edge behavior.
- Details:
Returns a simple bezier path (no curvature at handles).
Returns a simple bezier path (no curvature at handles) and center positions.
### [getSimpleBezierCenter](/typedocs/functions/getSimpleBezierCenter)
### getSimpleBezierCenter (removed)
::: warning
This function has been removed. The edge center positions are returned by `getSimpleBezierPath` now.
:::
- Details:
@@ -55,8 +63,8 @@ regular edge behavior.
Returns a smoothstep path (use border-radius 0 for a step path).
### [getEdgeCenter](/typedocs/functions/getEdgeCenter)
### [getStraightPath](/typedocs/functions/getStraightPath)
- Details:
Returns an edge path's center x and y values.
Returns a straight path.

View File

@@ -1,9 +1,5 @@
# Viewport Functions
::: warning
The old `FlowInstance` has been removed and all it's functionalities merged into `useVueFlow`.
:::
Viewport Functions can be accessed via the [`useVueFlow`](/guide/composables#usevueflow)
utility or with the [`VueFlowStore`](/typedocs/types/VueFlowStore)
instance provided by [`onPaneReady`](/typedocs/interfaces/FlowEvents#paneready).