Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ELK layout quite messy inside a container. #2255

Open
andergnet opened this issue Dec 17, 2024 · 0 comments
Open

ELK layout quite messy inside a container. #2255

andergnet opened this issue Dec 17, 2024 · 0 comments

Comments

@andergnet
Copy link

I defining a diagram and I wanted to but it inside a container with the idea to generate a diagram with two different subdiagrams.
I noticed that using the ELK layout the same diagram inside and outside a container looks totally different being the one inside the container quite a mess.

d2 versions: v0.6.5 & v0.6.8

This is an example of such behavior:


AA -> AV
AB -> A4
AB -> AH
AC -> AO
AD -> AL
AE -> AN
AF -> AO
AG -> A5
AG -> A6
AH -> AG
AI -> AG
AJ -> AO
AK -> AB
AL -> AH
AM -> AL
AN -> A4
AN -> AH
AO -> A7
AO -> AH
AP -> AB
AQ -> AV
AR -> AL
AS -> AO
AT -> AF
AU -> AV
AV -> AI
AW -> AV
AX -> AL
AY -> AN
AZ -> A3
A0 -> AO
A1 -> AO
A2 -> A3
A3 -> AB

box {
   BA -> BV
   BB -> B4
   BB -> BH
   BC -> BO
   BD -> BL
   BE -> BN
   BF -> BO
   BG -> B5
   BG -> B6
   BH -> BG
   BI -> BG
   BJ -> BO
   BK -> BB
   BL -> BH
   BM -> BL
   BN -> B4
   BN -> BH
   BO -> B7
   BO -> BH
   BP -> BB
   BQ -> BV
   BR -> BL
   BS -> BO
   BT -> BF
   BU -> BV
   BV -> BI
   BW -> BV
   BX -> BL
   BY -> BN
   BZ -> B3
   B0 -> BO
   B1 -> BO
   B2 -> B3
   B3 -> BB
}

The result is the following after running: d2 --layout elk test.d2

test

There is a big difference int the layout between the two subdiagrams that should look the same.

@cyborg-ts cyborg-ts added this to D2 Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: No status
Development

No branches or pull requests

1 participant