fix
This commit is contained in:
parent
31f2ca66b8
commit
d2ec7cd19c
3 changed files with 9 additions and 25 deletions
|
|
@ -12,3 +12,4 @@
|
||||||
- Using `shape: circle` for arrowheads no longer removes all arrowheads along path in sketch mode [#1942](https://github.com/terrastruct/d2/pull/1942)
|
- Using `shape: circle` for arrowheads no longer removes all arrowheads along path in sketch mode [#1942](https://github.com/terrastruct/d2/pull/1942)
|
||||||
- Globs to null connections work [#1965](https://github.com/terrastruct/d2/pull/1965)
|
- Globs to null connections work [#1965](https://github.com/terrastruct/d2/pull/1965)
|
||||||
- Edge globs setting styles inherit correctly in child boards [#1967](https://github.com/terrastruct/d2/pull/1967)
|
- Edge globs setting styles inherit correctly in child boards [#1967](https://github.com/terrastruct/d2/pull/1967)
|
||||||
|
- Board links imported with spread imports work [#1972](https://github.com/terrastruct/d2/pull/1972)
|
||||||
|
|
|
||||||
|
|
@ -512,6 +512,7 @@ func (c *compiler) compileMap(dst *Map, ast, scopeAST *d2ast.Map) {
|
||||||
}
|
}
|
||||||
|
|
||||||
OverlayMap(dst, impn.Map())
|
OverlayMap(dst, impn.Map())
|
||||||
|
c.updateLinks(dst)
|
||||||
|
|
||||||
if impnf, ok := impn.(*Field); ok {
|
if impnf, ok := impn.(*Field); ok {
|
||||||
if impnf.Primary_ != nil {
|
if impnf.Primary_ != nil {
|
||||||
|
|
|
||||||
32
testdata/d2compiler/TestCompile/spread-import-link.exp.json
generated
vendored
32
testdata/d2compiler/TestCompile/spread-import-link.exp.json
generated
vendored
|
|
@ -3,7 +3,7 @@
|
||||||
"name": "",
|
"name": "",
|
||||||
"isFolderOnly": false,
|
"isFolderOnly": false,
|
||||||
"ast": {
|
"ast": {
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,0:0:0-4:1:22",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,0:0:0-4:1:27",
|
||||||
"nodes": [
|
"nodes": [
|
||||||
{
|
{
|
||||||
"map_key": {
|
"map_key": {
|
||||||
|
|
@ -30,7 +30,7 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"map_key": {
|
"map_key": {
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,2:0:3-4:1:22",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,2:0:3-4:1:27",
|
||||||
"key": {
|
"key": {
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,2:0:3-2:6:9",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,2:0:3-2:6:9",
|
||||||
"path": [
|
"path": [
|
||||||
|
|
@ -50,11 +50,11 @@
|
||||||
"primary": {},
|
"primary": {},
|
||||||
"value": {
|
"value": {
|
||||||
"map": {
|
"map": {
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,2:8:11-4:1:22",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,2:8:11-4:1:27",
|
||||||
"nodes": [
|
"nodes": [
|
||||||
{
|
{
|
||||||
"map_key": {
|
"map_key": {
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:2:15-3:7:20",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:2:15-3:12:25",
|
||||||
"key": {
|
"key": {
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:2:15-3:3:16",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:2:15-3:3:16",
|
||||||
"path": [
|
"path": [
|
||||||
|
|
@ -74,17 +74,17 @@
|
||||||
"primary": {},
|
"primary": {},
|
||||||
"value": {
|
"value": {
|
||||||
"map": {
|
"map": {
|
||||||
"range": ",1:0:0-1:0:0",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:5:18-3:12:25",
|
||||||
"nodes": [
|
"nodes": [
|
||||||
{
|
{
|
||||||
"import": {
|
"import": {
|
||||||
"range": ",1:0:0-1:0:0",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:6:19-3:11:24",
|
||||||
"spread": true,
|
"spread": true,
|
||||||
"pre": "",
|
"pre": "",
|
||||||
"path": [
|
"path": [
|
||||||
{
|
{
|
||||||
"unquoted_string": {
|
"unquoted_string": {
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:6:19-3:7:20",
|
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:10:23-3:11:24",
|
||||||
"value": [
|
"value": [
|
||||||
{
|
{
|
||||||
"string": "x",
|
"string": "x",
|
||||||
|
|
@ -97,24 +97,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
|
||||||
"import": {
|
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:5:18-3:7:20",
|
|
||||||
"spread": false,
|
|
||||||
"pre": "",
|
|
||||||
"path": [
|
|
||||||
{
|
|
||||||
"unquoted_string": {
|
|
||||||
"range": "d2/testdata/d2compiler/TestCompile/spread-import-link.d2,3:6:19-3:7:20",
|
|
||||||
"value": [
|
|
||||||
{
|
|
||||||
"string": "x",
|
|
||||||
"raw_string": "x"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue