fix(webui): Correct edge renderer for sigma.js v3
The `curvedNoArrow` edge type was incorrectly configured, causing a `TypeError` during graph rendering. This commit updates the `edgeProgramClasses` in `GraphViewer.tsx` to use the `createEdgeCurveProgram()` factory function as required by `@sigma/edge-curve` v3, resolving the crash.
This commit is contained in:
parent
10b55dbdc7
commit
2c4f621ded
1 changed files with 2 additions and 2 deletions
|
|
@ -5,7 +5,7 @@ import { Settings as SigmaSettings } from 'sigma/settings'
|
|||
import { GraphSearchOption, OptionItem } from '@react-sigma/graph-search'
|
||||
import { EdgeArrowProgram, NodePointProgram, NodeCircleProgram } from 'sigma/rendering'
|
||||
import { NodeBorderProgram } from '@sigma/node-border'
|
||||
import EdgeCurveProgram, { EdgeCurvedArrowProgram } from '@sigma/edge-curve'
|
||||
import { EdgeCurvedArrowProgram, createEdgeCurveProgram } from '@sigma/edge-curve'
|
||||
|
||||
import FocusOnNode from '@/components/graph/FocusOnNode'
|
||||
import LayoutsControl from '@/components/graph/LayoutsControl'
|
||||
|
|
@ -36,7 +36,7 @@ const defaultSigmaSettings: Partial<SigmaSettings> = {
|
|||
edgeProgramClasses: {
|
||||
arrow: EdgeArrowProgram,
|
||||
curvedArrow: EdgeCurvedArrowProgram,
|
||||
curvedNoArrow: EdgeCurveProgram
|
||||
curvedNoArrow: createEdgeCurveProgram()
|
||||
},
|
||||
nodeProgramClasses: {
|
||||
default: NodeBorderProgram,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue