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

GANTT Chart failing to render once the second section is added #5260

Closed
petruut opened this issue Feb 4, 2024 · 3 comments
Closed

GANTT Chart failing to render once the second section is added #5260

petruut opened this issue Feb 4, 2024 · 3 comments
Labels
Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect

Comments

@petruut
Copy link

petruut commented Feb 4, 2024

Description

When attempting the following configuration, the chart glitches once the second section is added.

gantt
dateFormat MM-YY
axisFormat %b %Y
tickInterval 1month

section Project Gov

Kick off: 06-23, 1m
Governance: 18m
Closure: 2m

section Deployment

Activity 5: 06-23, 1m
Activity 6: 08-23, 3m

Steps to reproduce

  1. Render the code as described:

When attempting the following configuration, the chart glitches once the second section is added.

gantt
dateFormat MM-YY
axisFormat %b %Y
tickInterval 1month

section Project Gov

Kick off: 06-23, 1m
Governance: 18m
Closure: 2m

section Deployment

Activity 5: 06-23, 1m
Activity 6: 08-23, 3m
  1. The chart glitches (try to render just the first section to see)

Screenshots

With the second section, it glitches:
image
Without the second section, it renders:
image

Code Sample

No response

Setup

  • Mermaid version:
  • Browser and Version: [Chrome, Edge, Firefox]

Suggested Solutions

No response

Additional Context

No response

@petruut petruut added Status: Triage Needs to be verified, categorized, etc Type: Bug / Error Something isn't working or is incorrect labels Feb 4, 2024
@petruut
Copy link
Author

petruut commented Feb 4, 2024

new update: the bug only seems to happen when i put the second section PLUS the durations of all activities in m (months). If i switch everything to d (days), the bug disappears.

i really need this to work with months (m), so hopefully will be able to fix this.

@NourS-d
Copy link

NourS-d commented Feb 7, 2024

image
gantt title A Gantt Diagram dateFormat YYYY-MM-DD section Project Gov Kick off: 06-23, 1M Governance: 18M Closure: 2M section Deployment Activity 5: 06-23, 1M Activity 6: 08-23, 3M

Is this want you need?
with months is should probably be "M". the small "m" is reserved for minutes.

@petruut
Copy link
Author

petruut commented Feb 7, 2024

I love you @NourS-d - I didn't immediately pick this up from the documentation, but it now makes sense!!

@petruut petruut closed this as completed Feb 7, 2024
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