Type: Function

How to get addDragAndDropOperation?


import addDragAndDropOperation from 'fontoxml-structure/src/addDragAndDropOperation.js'

Add an operation to the list of operations to try when dragging and dropping a structure view item.

Call this in the install.js of the package providing the operation to be added. Operations are evaluated in order of decreasing priority.

By default the platform adds the following operations:

  • { name: move-hierarchy-node-in-dom, priority: 0 }, added by this package, useful for single document editors

  • { name: move-hierarchy-node-in-dita-map, priority: 10 }, added by fontoxml-dita, useful for dita editors

Please refer to our guide for help in configuring custom drag and drop operations.

Also note that the isDraggable property of configureAsStructureViewItem can be used to disable drag and drop for a specific item.


  1. dragAndDropOperationConfig