This text is displayed if your browser does not support the Canvas HTML element.
This text is displayed if your browser does not support the Canvas HTML element.
This text is displayed if your browser does not support the Canvas HTML element.

This sample supports the normal kind of drag-and-drop from a Palette to a Diagram. The Data Inspector allows you to edit the properties of a selected node in the diagram.

This sample also supports dynamically adding a copy of a selected node in the diagram to the palette by the "Add To Palette" button. See the current state of the palette's model in the top textarea. The palette is Diagram.isReadOnly, so the user cannot delete selected nodes from the palette. But the "Delete From Palette" button removes any selected nodes from the palette.

Palette model:
Diagram model:

GoJS version 2.3.3. Copyright 1998-2023 by Northwoods Software.

View this sample page's source on GitHub