New to Kendo UI for AngularStart a free 30-day trial

ShapeMapping

Updated on Oct 31, 2025

Configuration for mapping source data to diagram shapes.

Defines how to extract shape data from the input and how to transform each shape from the source format to the required ShapeOptions format. The source specifies where to find the array of shape data, and the map defines the field mappings.

typescript
const shapeMapping: ShapeMapping<NodeData> = {
  source: 'nodes',  // Extract from input.nodes array
  map: {
    id: 'nodeId',
    x: 'position.x',
    y: 'position.y',
    content: (node) => ({ text: node.label })
  }
};
Not finding the help you need?
Contact Support