Defines the stroke style of a path
string
Sets the fill color of a shape/path
Defaults to ‘transparent’
GradientModel
| LinearGradientModel
| RadialGradientModel
| DiagramGradientModel
Defines the gradient of a shape/path
Defaults to null
number
Sets the opacity of a shape/path
Defaults to 1
string
Sets the stroke color of a shape/path
Defaults to ‘black’
string
Defines the pattern of dashes and spaces to stroke the path/shape
<div id='diagram'></div>
let nodes: NodeModel[] = [{ id: 'node', width: 100, height: 100, offsetX: 100, offsetY: 100,
style: { fill: 'red', strokeColor: 'blue', strokeWidth: 5,
strokeDashArray: '2 2', opacity: 0.6 } as ShapeStyleModel,
}];
let diagram: Diagram = new Diagram({
...
nodes: nodes,
...
});
diagram.appendTo('#diagram');
Defaults to ”
number
Defines the stroke width of the path/shape
Defaults to 1