Sample for representing the relationship between various entities. Try dragging the nodes -- their links will avoid other nodes, by virtue of the Routing.AvoidsNodes property assigned to the custom link template's Link.routing. Also note the use of Panel Expander Buttons to allow for expandable/collapsible node data.

Buttons are defined in Buttons.js.

The dark and light modes are controlled by using a boolean model property representing the current mode of the diagram. See the API page on Models for more information of model data.