retrieves current values of Diagram Editor
object | object with values |
const data = $$("editor").getValues();
$$("diagram").parse(data);
The method returns an object with the following fields:
Data sample
{
data:[
{ id: "start", type: "circle", value: "start", x: 0, y: 80 },
// other blocks
],
links: [
{ source: "start", target: "search", id: 132 },
// other links
],
shapes: [
{
backgroundColor: "#65C0B7", fontColor: "#fff",
group: "block", id: "circle",
lineColor: "#65C0B7", name: "Circle",
svg: /*svg_code*/
},
// other shapes
],
item: {
height: 50, width: 100
},
linkItem: {
arrowSize: 6, arrow: false,
mode: "edges", backgroundColor: "magenta"
}
}