embeddingMode
- when set to true
, the paper is set to embedding mode. In this mode,
when you drag an element and drop into another element, the element below becomes a parent
of the dropped element (the dropped element gets automatically embedded into the parent element). Similarly, when you drag an
element out of its parent, the element gets automatically unembedded from its parent. The embedding mode
also makes sure all the connected links and child elements have proper z
index set so that they stay visible.
To control what elements can be embedded into what other elements, use the validateEmbedding()
function
on the paper (see below).
This is useful for hierarchical diagrams. See the DEVS demo on how this can be used.