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

Incorrect overlapping rendering of block digram #5683

Open
michalstrelec opened this issue Aug 2, 2024 · 1 comment
Open

Incorrect overlapping rendering of block digram #5683

michalstrelec opened this issue Aug 2, 2024 · 1 comment
Labels
Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect

Comments

@michalstrelec
Copy link

Description

The rendering of a set of groups with larger number of items in it is overlapping each other. The same behaviour is in current and development version of live editor.

Steps to reproduce

The code to reproduce the error:

block-beta
columns 2
block:group1
columns 5
level1:5 a1 a2 a3 a4 a5 a6 a7 a8 a9 a10 a11
end
block:group2
columns 5
level2:5 b1 b2 b3 b4
end
block:group3
columns 5
level3:5 c1 c2 c3 c4
end
block:group4
columns 5
level4:5 d1 d2 d3 d4
end

Screenshots

image

Code Sample

No response

Setup

  • Mermaid version: 10.9.1 and 11.0.0-alpha.7
  • Browser and Version: Firefox 128.0.3 (64-bit) Linux Ubuntu and Firefox on Windows as well

Suggested Solutions

No response

Additional Context

No response

@michalstrelec michalstrelec added Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect labels Aug 2, 2024
@dcooper-database9
Copy link

dcooper-database9 commented Dec 4, 2024

I think I encountered the same issue. I created two simplified examples to show the issue. The first diagram is laid out horizontally, and outputs as expected. The second diagram is laid out vertically, and it results in block b4 laid on top of rectangle b3 (labeled beta 3).

mermaid horizontall boxes

%%Horizontal
block-beta
  columns 4
  block:rowa:4
    columns 4
    a1["alpha 1"]
    a2["alpha 2"]
    a3["alpha 3"]
    a4["alpha 4"]
  end
  block:rowb:4
    columns 4
    block:b1
        columns 1
        b1a["beta 1-a"]
        b1b["beta 1-b"]
        b1c["beta 1-c"]
    end
    b2["beta 2"]
    b3["beta 3"]
    block:b4
        columns 1
        b4a["beta 4-a"]
        b4b["beta 4-b"]
    end
  end
class rowa Green
class rowb Yellow
class b1 Purple
class b4 Blue

classDef Blue fill:#ccccff,stroke:#0000cc,stroke-width:2px
classDef Green fill:#cce5cc,stroke:#007300,stroke-width:2px
classDef Yellow fill:#ffffb2,stroke:#000000,stroke-width:2px
classDef Purple fill:#e5cce5,stroke:#8c198c,stroke-width:2px

mermaid vertical boxes

%%Vertical
block-beta
  columns 2
  block:columna
    columns 1
    a1["alpha 1"]
    a2["alpha 2"]
    a3["alpha 3"]
    a4["alpha 4"]
  end
  block:columnb
    columns 1
    block:b1
        columns 1
        b1a["beta 1-a"]
        b1b["beta 1-b"]
        b1c["beta 1-c"]
    end
    b2["beta 2"]
    b3["beta 3"]
    block:b4
        columns 1
        b4a["beta 4-a"]
        b4b["beta 4-b"]
    end
  end
class columna Green
class columnb Yellow
class b1 Purple
class b4 Blue

classDef Blue fill:#ccccff,stroke:#0000cc,stroke-width:2px
classDef Green fill:#cce5cc,stroke:#007300,stroke-width:2px
classDef Yellow fill:#ffffb2,stroke:#000000,stroke-width:2px
classDef Purple fill:#e5cce5,stroke:#8c198c,stroke-width:2px


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect
Projects
None yet
Development

No branches or pull requests

2 participants