d2
d2 copied to clipboard
In shape sql_shape foreign key reference hover effect is not working
So the doc claims that if I make a connect between two sql_shape keys, hovering over either of them should highlight the respective connected key in the referenced table shape. (reference)
If you hover over the primary key or foreign key with your cursor, you'll notice that the corresponding key is highlighted.
I tried it out with the following D2 Script. but it doesn't seem to be working.
Am I missing something here?
a: tableA {
shape: "sql_table"
id: int {constraint: primary_key}
columnA: string
columnB: jsonB
}
b: tableB {
shape: "sql_table"
id: int {constraint:primary_key}
columnD: string
columnE: timestamp
}
mab: map_tableA_tableB {
shape: "sql_table"
id: int {constraint: primary_key}
fk_tableA_id: int {constraint: foreign_key}
fk_tableB_id: int {constraint: foreign_key}
}
mab.fk_tableA_id -> a.id
mab.fk_tableB_id -> b.id
If it is relevant here, my d2 version is v0.0.13.
Same for me 👍
closing in favor of https://github.com/terrastruct/d2/issues/795