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

fix: move from objects to Maps #5468

Open
wants to merge 16 commits into
base: develop
Choose a base branch
from
Open

fix: move from objects to Maps #5468

wants to merge 16 commits into from

Conversation

Yash-Singh1
Copy link
Member

@Yash-Singh1 Yash-Singh1 commented Apr 17, 2024

📑 Summary

Switches from objects to Maps in places where the keys accepted are user inputs.

Resolves #5451

📏 Design Decisions

Describe the way your implementation works or what design decisions you made if applicable.

This is a breaking change for v11 since it changes the structure of the databases and as such can break code that relies on the db, e.g.

https://github.com/excalidraw/mermaid-to-excalidraw/blob/d0b00dc63eeabd5e92ca3997650f47bf4901cb2c/src/parser/flowchart.ts#L226

📋 Tasks

Make sure you

@github-actions github-actions bot added the Type: Bug / Error Something isn't working or is incorrect label Apr 17, 2024
Copy link

netlify bot commented Apr 17, 2024

Deploy Preview for mermaid-js ready!

Name Link
🔨 Latest commit 50c9ede
🔍 Latest deploy log https://app.netlify.com/sites/mermaid-js/deploys/663667245484c9000856c67b
😎 Deploy Preview https://deploy-preview-5468--mermaid-js.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

codecov bot commented Apr 17, 2024

Codecov Report

Attention: Patch coverage is 0.52219% with 381 lines in your changes are missing coverage. Please review.

Project coverage is 5.72%. Comparing base (e68125e) to head (50c9ede).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           develop   #5468      +/-   ##
==========================================
- Coverage     5.73%   5.72%   -0.01%     
==========================================
  Files          277     278       +1     
  Lines        41999   42018      +19     
  Branches       515     490      -25     
==========================================
  Hits          2407    2407              
- Misses       39592   39611      +19     
Flag Coverage Δ
unit 5.72% <0.52%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
packages/mermaid/src/diagrams/gantt/ganttDb.js 77.47% <66.66%> (ø)
packages/mermaid/src/diagrams/sequence/svgDraw.js 0.00% <0.00%> (ø)
packages/mermaid/src/diagrams/class/classTypes.ts 0.00% <0.00%> (ø)
...ckages/mermaid/src/diagrams/gantt/ganttRenderer.js 0.00% <0.00%> (ø)
...ages/mermaid-flowchart-elk/src/flowRenderer-elk.js 0.00% <0.00%> (ø)
...ckages/mermaid/src/diagrams/class/classRenderer.js 0.00% <0.00%> (ø)
...ges/mermaid/src/diagrams/flowchart/flowRenderer.js 0.00% <0.00%> (ø)
packages/mermaid/src/diagrams/pie/pieRenderer.ts 0.00% <0.00%> (ø)
packages/mermaid/src/diagrams/er/erRenderer.js 0.00% <0.00%> (ø)
packages/mermaid/src/diagrams/pie/pieDb.ts 0.00% <0.00%> (ø)
... and 17 more

... and 1 file with indirect coverage changes

Copy link
Member

@sidharthv96 sidharthv96 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Appreciate the effort! Can you take a look at the E2E failures?

image

@sidharthv96
Copy link
Member

@Yash-Singh1 were you able to fix the tests?
Keeping this PR open for long will create more conflicts for you.

@Yash-Singh1
Copy link
Member Author

Hi @sidharthv96, sorry for the late reply, I was busy with exams. I just fixed the e2e tests.

@sidharthv96
Copy link
Member

No worries @Yash-Singh1! Hope they went well :)
Let's wait for a review from someone else as well, as the size is big.

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

Successfully merging this pull request may close these issues.

[BUG] Using constructor as node ID results in errors
2 participants