701 lines
20 KiB
JSON
Generated
701 lines
20 KiB
JSON
Generated
{
|
|
"graph": {
|
|
"name": "",
|
|
"isFolderOnly": false,
|
|
"ast": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-3:0:12",
|
|
"nodes": [
|
|
{
|
|
"map_key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"value": [
|
|
{
|
|
"string": "a",
|
|
"raw_string": "a"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"primary": {},
|
|
"value": {}
|
|
}
|
|
},
|
|
{
|
|
"import": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,2:0:3-2:8:11",
|
|
"spread": true,
|
|
"pre": "",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,2:4:7-2:8:11",
|
|
"value": [
|
|
{
|
|
"string": "test",
|
|
"raw_string": "test"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"root": {
|
|
"id": "",
|
|
"id_val": "",
|
|
"attributes": {
|
|
"label": {
|
|
"value": ""
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": ""
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
},
|
|
"edges": null,
|
|
"objects": [
|
|
{
|
|
"id": "a",
|
|
"id_val": "a",
|
|
"references": [
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"value": [
|
|
{
|
|
"string": "a",
|
|
"raw_string": "a"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
}
|
|
],
|
|
"attributes": {
|
|
"label": {
|
|
"value": "a"
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": "rectangle"
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
},
|
|
{
|
|
"id": "x",
|
|
"id_val": "x",
|
|
"references": [
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
}
|
|
],
|
|
"attributes": {
|
|
"label": {
|
|
"value": "x"
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": "rectangle"
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
}
|
|
],
|
|
"steps": [
|
|
{
|
|
"name": "1",
|
|
"isFolderOnly": false,
|
|
"ast": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,0:0:0-1:0:0",
|
|
"nodes": [
|
|
{
|
|
"map_key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"value": [
|
|
{
|
|
"string": "a",
|
|
"raw_string": "a"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"primary": {},
|
|
"value": {}
|
|
}
|
|
},
|
|
{
|
|
"map_key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"primary": {},
|
|
"value": {
|
|
"map": {
|
|
"range": ",1:0:0-2:0:0",
|
|
"nodes": [
|
|
{
|
|
"map_key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:6:26-5:13:33",
|
|
"value": [
|
|
{
|
|
"string": "tooltip",
|
|
"raw_string": "tooltip"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"primary": {
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:15:35-5:18:38",
|
|
"value": [
|
|
{
|
|
"string": "foo",
|
|
"raw_string": "foo"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"value": {}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"root": {
|
|
"id": "",
|
|
"id_val": "",
|
|
"attributes": {
|
|
"label": {
|
|
"value": ""
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": ""
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
},
|
|
"edges": null,
|
|
"objects": [
|
|
{
|
|
"id": "a",
|
|
"id_val": "a",
|
|
"references": [
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"value": [
|
|
{
|
|
"string": "a",
|
|
"raw_string": "a"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
}
|
|
],
|
|
"attributes": {
|
|
"label": {
|
|
"value": "a"
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": "rectangle"
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
},
|
|
{
|
|
"id": "x",
|
|
"id_val": "x",
|
|
"references": [
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
},
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:4:24-5:13:33",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:4:24-5:5:25",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:6:26-5:13:33",
|
|
"value": [
|
|
{
|
|
"string": "tooltip",
|
|
"raw_string": "tooltip"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
}
|
|
],
|
|
"attributes": {
|
|
"label": {
|
|
"value": "x"
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"tooltip": {
|
|
"value": "foo"
|
|
},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": "rectangle"
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"name": "2",
|
|
"isFolderOnly": false,
|
|
"ast": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,0:0:0-1:0:0",
|
|
"nodes": [
|
|
{
|
|
"map_key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"value": [
|
|
{
|
|
"string": "a",
|
|
"raw_string": "a"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"primary": {},
|
|
"value": {}
|
|
}
|
|
},
|
|
{
|
|
"map_key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"primary": {},
|
|
"value": {
|
|
"map": {
|
|
"range": ",1:0:0-2:0:0",
|
|
"nodes": [
|
|
{
|
|
"map_key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"key": {
|
|
"range": ",0:0:0-0:0:0",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:6:26-5:13:33",
|
|
"value": [
|
|
{
|
|
"string": "tooltip",
|
|
"raw_string": "tooltip"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"primary": {
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,8:15:65-8:17:67",
|
|
"value": [
|
|
{
|
|
"string": "do",
|
|
"raw_string": "do"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"value": {}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"root": {
|
|
"id": "",
|
|
"id_val": "",
|
|
"attributes": {
|
|
"label": {
|
|
"value": ""
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": ""
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
},
|
|
"edges": null,
|
|
"objects": [
|
|
{
|
|
"id": "a",
|
|
"id_val": "a",
|
|
"references": [
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/import-steps.d2,0:0:0-0:1:1",
|
|
"value": [
|
|
{
|
|
"string": "a",
|
|
"raw_string": "a"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
}
|
|
],
|
|
"attributes": {
|
|
"label": {
|
|
"value": "a"
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": "rectangle"
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
},
|
|
{
|
|
"id": "x",
|
|
"id_val": "x",
|
|
"references": [
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,1:0:1-1:1:2",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
},
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:4:24-5:13:33",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:4:24-5:5:25",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,5:6:26-5:13:33",
|
|
"value": [
|
|
{
|
|
"string": "tooltip",
|
|
"raw_string": "tooltip"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
},
|
|
{
|
|
"key": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,8:4:54-8:13:63",
|
|
"path": [
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,8:4:54-8:5:55",
|
|
"value": [
|
|
{
|
|
"string": "x",
|
|
"raw_string": "x"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
{
|
|
"unquoted_string": {
|
|
"range": "d2/testdata/d2compiler/TestCompile/test.d2,8:6:56-8:13:63",
|
|
"value": [
|
|
{
|
|
"string": "tooltip",
|
|
"raw_string": "tooltip"
|
|
}
|
|
]
|
|
}
|
|
}
|
|
]
|
|
},
|
|
"key_path_index": 0,
|
|
"map_key_edge_index": -1
|
|
}
|
|
],
|
|
"attributes": {
|
|
"label": {
|
|
"value": "x"
|
|
},
|
|
"labelDimensions": {
|
|
"width": 0,
|
|
"height": 0
|
|
},
|
|
"style": {},
|
|
"iconStyle": {},
|
|
"tooltip": {
|
|
"value": "do"
|
|
},
|
|
"near_key": null,
|
|
"shape": {
|
|
"value": "rectangle"
|
|
},
|
|
"direction": {
|
|
"value": ""
|
|
},
|
|
"constraint": null
|
|
},
|
|
"zIndex": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"err": null
|
|
}
|