Skip to main content
note

If you're coming from 2.x, you should first checkout the 2.x -> 5.x migration docs, and then the 5.x -> 6.x migration docs.

Migration from 6.x to 7.x

The list of breaking changes between 6.x and 7.x is:

  • The SegmentedConnector has been renamed to StraightConnector. Wherever your app uses SegmentedConnector.type you'll need to update the code. Note, though, that this new StraightConnector is the default connector, so if you currently use SegmentedConnector without any config options you can simply remove that code.

We do not expect any change in functionality for apps that either currently use the default connector or that specify Straight as the connector type, as the new Straight connector is a drop-in replacement for the original Straight connector, when it has only a single segment.

  • Support for the ORTHOGONAL_CONNECTOR_RECALC_STRATEGY_LEGACY recalculation strategy was removed, having been previously deprecated. ORTHOGONAL_CONNECTOR_RECALC_STRATEGY_MODERN and OrthogonalRecalcStrategy were also both removed, being no longer necessary.

  • The original StraightConnector has been renamed to LegacyStraightConnector, and is now deprecated.

  • margin was removed from StateMachine and Bezier connectors. Use the pre-existing gap option instead.

  • The CSS classes added to groups that are a drag target or the current hover target for other groups or nodes being dragged have changed from jtk-drag-active and jtk-drag-hover to jtk-vertex-drag-active and jtk-vertex-drag-hover. This is to distinguish them from the active/hover classes used when dragging edges.

  • The initializeSegmentedConnectorEditors method was renamed to initializeStraightConnectorEditors

  • The CSS classes related to the previous segmented connector editor have been renamed, eg. where we'd have .jtk-segmented-segment-delete, for example, we now have .jtk-straight-segment-delete.

  • The contents of the jsplumbtoolkit-connector-editors.css stylesheet was folded in to jsplumbtoolkit.css and jsplumbtoolkit-connector-editors.css was removed.

  • The contents of the jsplumbtoolkit-edge-type-picker.css stylesheet was folded in to jsplumbtoolkit.css and jsplumbtoolkit-edge-type-picker.css was removed.

  • The contents of the jsplumbtoolkit-dialogs.css stylesheet was folded in to jsplumbtoolkit.css and jsplumbtoolkit-dialogs.css was removed.

  • The contents of the jsplumbtoolkit-browser-ui-plugin-background.css stylesheet was folded in to jsplumbtoolkit.css and jsplumbtoolkit-browser-ui-plugin-background.css was removed.

  • The contents of the jsplumbtoolkit-controls.css stylesheet was folded in to jsplumbtoolkit.css and jsplumbtoolkit-controls.css was removed.

  • The ExportControlsComponent constructor has changed - the third argument is now options instead of a ShapeLibrary. if you need to pass in a shape library you can do it inside the options, but it should not be necessary as the component gets the shape library from the surface you pass in.