d2 icon indicating copy to clipboard operation
d2 copied to clipboard

outside-x label position on elk causes slanted lines

Open VictorPato opened this issue 1 year ago • 2 comments

On the current version of D2 (0.6.3) we're finding a problem that wasn't an issue on 0.6.1

When attaching a label to a container on the outside (example: outside-left-center), lines to and from that container render slanted

For example:

b: {
  label.near: outside-left-center
  label: Some Label
  c
}
d
a -> b.c
b.c -> d

image

D2 Playground

This also holds when using direction: right

direction: right
b: {
  label.near: outside-top-left
  label: Some Label
  c
}
d
a->b.c
b.c->d

image D2 Playground

VictorPato avatar Jan 30 '24 18:01 VictorPato

@VictorPato Why was this closed?

alixander avatar Feb 19 '25 19:02 alixander

@alixander I was just closing old issues, AFAIK this is still a problem as I can still reproduce it on the playground. I'll reopen the issue.

VictorPato avatar Feb 19 '25 19:02 VictorPato