NodeModel

23 Sep 20255 minutes to read

Interface for a class Node

Properties

addInfo Object

Allows the user to save custom information/data about a node/connector

annotations ShapeAnnotationModel[]

Defines the collection of textual annotations of nodes/connectors

backgroundColor string

Sets the background color of the shape

borderColor string

Sets the border color of the node

borderWidth number

Sets the border width of the node

branch BranchTypes

Set the branch for the mind map

children string[]

Defines the children of group element

collapseIcon IconShapeModel

Defines the collapsed state of a node

columnIndex number

Used to define a index of column in the grid

columnSpan number

Merge the column use the property in the grid container

columns ColumnDefinition[]

Used to define the column for the grid container

constraints NodeConstraints

Enables/Disables certain features of nodes

  • None - Disable all node Constraints
  • Select - Enables node to be selected
  • Drag - Enables node to be Dragged
  • Rotate - Enables node to be Rotate
  • Shadow - Enables node to display shadow
  • PointerEvents - Enables node to provide pointer option
  • Delete - Enables node to delete
  • InConnect - Enables node to provide in connect option
  • OutConnect - Enables node to provide out connect option
  • Individual - Enables node to provide individual resize option
  • Expandable - Enables node to provide Expandable option
  • AllowDrop - Enables node to provide allow to drop option
  • Inherit - Enables node to inherit the interaction option
  • ResizeNorthEast - Enable ResizeNorthEast of the node
  • ResizeEast - Enable ResizeEast of the node
  • ResizeSouthEast - Enable ResizeSouthEast of the node
  • ResizeSouth - Enable ResizeSouthWest of the node
  • ResizeSouthWest - Enable ResizeSouthWest of the node
  • ResizeSouth - Enable ResizeSouth of the node
  • ResizeSouthWest - Enable ResizeSouthWest of the node
  • ResizeWest - Enable ResizeWest of the node
  • ResizeNorth - Enable ResizeNorth of the node
  • Resize - Enables the Aspect ratio fo the node
  • AspectRatio - Enables the Aspect ratio fo the node
  • Tooltip - Enables or disables tool tip for the Nodes
  • InheritTooltip - Enables or disables tool tip for the Nodes
  • ReadOnly - Enables the ReadOnly support for Annotation

container ChildContainerModel

Defines the type of the container

data Object

Sets the data source of the node

dragSize SymbolSizeModel

Defines the size of a drop symbol

excludeFromLayout boolean

Defines whether the node should be automatically positioned or not. Applicable, if layout option is enabled.

expandIcon IconShapeModel

Defines the expanded state of a node

fixedUserHandles NodeFixedUserHandleModel[]

Specifies the collection of the fixed user handle

flip FlipDirection

Flip the element in Horizontal/Vertical directions

flipMode FlipMode

Allows you to flip only the node or along with port and label.
This functionality is applicable only for nodes.

height number

Sets the height of the node

horizontalAlignment HorizontalAlignment

Sets the horizontalAlignment of the node

id string

Represents the unique id of nodes/connectors

isExpanded boolean

Defines whether the node is expanded or not

layoutInfo LayoutInfo

Sets the layout properties using node property

margin MarginModel

Defines the space to be left between the node and its immediate parent

maxHeight number

Sets the maximum height of the node

maxWidth number

Sets the maximum width of the node

minHeight number

Sets the minimum height of the node

minWidth number

Sets the minimum width of the node

offsetX number

Sets the x-coordinate of the position of the node

offsetY number

Sets the y-coordinate of the position of the node

padding MarginModel

Defines the space between the group node edges and its children

pivot PointModel

Sets the reference point, that will act as the offset values(offsetX, offsetY) of a node

ports PointPortModel[]

Defines the collection of connection points of nodes/connectors

previewSize SymbolSizeModel

Defines the size of the symbol preview

rotateAngle number

Sets the rotate angle of the node

rowIndex number

Used to define a index of row in the grid

rowSpan number

Merge the row use the property in the grid container

rows RowDefinition[]

Used to define the rows for the grid container

shadow ShadowModel

Defines the shadow of a shape/path

shape ShapeModel|FlowShapeModel|BasicShapeModel|ImageModel|PathModel|TextModel|BpmnShapeModel|NativeModel|HtmlModel|UmlActivityShapeModel|UmlClassifierShapeModel|SwimLaneModel|DiagramShapeModel|ContainerModel

Defines the shape of a node

style ShapeStyleModel|TextStyleModel

Sets the shape style of the node

symbolInfo SymbolPaletteInfoModel

Defines the symbol info of a connector

tooltip DiagramTooltipModel

defines the tooltip for the node

verticalAlignment VerticalAlignment

Sets the verticalAlignment of the node

visible boolean

Sets the visibility of the node/connector

width number

Sets the width of the node

wrapper GroupableView

Sets or gets the UI of a node

zIndex number

Defines the visual order of the node/connector in DOM