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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix(mermaid): circumvents mermaid edge naming ambiguities #709

Merged
merged 1 commit into from Dec 24, 2022

Conversation

sverweij
Copy link
Owner

Description

  • makes the 'minified' node names in generated mermaid uppercase

Motivation and Context

There's some interesting edge cases in the mermaid flowchart language. These two seemingly equal flowcharts render differently. Reason is that o--> is an arrow shape. Two ways to fix it

  • use spaces (o --> a) -> this would make the generated .mmd larger, so we'll bump into mermaid's maximum input limit faster
  • don't use the characters that manifest the ambiguity (o and x). Easiest way to accomplish that is to uppercase the 'minified' node names.
flowchart LR
o
a
o-->a
flowchart LR
o
a
o-->a
flowchart LR
O
A
O-->A
flowchart LR
O
A
O-->A

How Has This Been Tested?

  • green ci
  • updated automated tests
  • some manual testing

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • Documentation only change
  • Refactor (non-breaking change which fixes an issue without changing functionality)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • 馃摉

    • My change doesn't require a documentation update, or ...
    • it does and I have updated it
  • 鈿栵笍

    • The contribution will be subject to The MIT license, and I'm OK with that.
    • The contribution is my own original work.
    • I am ok with the stuff in CONTRIBUTING.md.

@sverweij sverweij merged commit 5b08743 into develop Dec 24, 2022
@sverweij sverweij deleted the bugfix/circumvent-mermaid-edge-ambiguities branch December 24, 2022 21:14
@MH4GF
Copy link
Contributor

MH4GF commented Jan 2, 2023

Wow this is an interesting edge cases馃槼 Thanks for fix it!

MH4GF added a commit to MH4GF/dependency-cruiser-report-action that referenced this pull request Jan 2, 2023
MH4GF added a commit to MH4GF/dependency-cruiser-report-action that referenced this pull request Jan 2, 2023
* Bump dependency-cruiser from 11.18.0 to 12.3.0

Bumps [dependency-cruiser](https://github.com/sverweij/dependency-cruiser) from 11.18.0 to 12.3.0.
- [Release notes](https://github.com/sverweij/dependency-cruiser/releases)
- [Changelog](https://github.com/sverweij/dependency-cruiser/blob/develop/CHANGELOG.md)
- [Commits](sverweij/dependency-cruiser@v11.18.0...v12.3.0)

---
updated-dependencies:
- dependency-name: dependency-cruiser
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

* fix(test): update snapshot for dependency-cruiser 12.3.0

ref: sverweij/dependency-cruiser#709

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: MH4GF <h.miyagi.cnw@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants