-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
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: flowchart image without text #5063
fix: flowchart image without text #5063
Conversation
✅ Deploy Preview for mermaid-js ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## develop #5063 +/- ##
============================================
+ Coverage 42.91% 79.29% +36.38%
============================================
Files 23 164 +141
Lines 5029 13884 +8855
Branches 21 700 +679
============================================
+ Hits 2158 11009 +8851
+ Misses 2870 2725 -145
- Partials 1 150 +149
Flags with carried forward coverage won't be shown. Click here to find out more.
|
9cf21b5
to
9b4e4ae
Compare
9b4e4ae
to
1ff7218
Compare
@bonyuta0204 it doesn't seem to be working for me. Link Can you post an example that's working in https://deploy-preview-5063--mermaid-js.netlify.app ? |
@sidharthv96 In my environment, everything seems to be functioning correctly.
Here are the details of my environment:
Could you please share the details of your environment? I would like to investigate further. |
Ok, so this might be a Firefox bug then? I'm using FF 118.0.1 on MacOS 13.3.1 (a) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Issue is still present in Firefox, but working in Chrome and Safari. Nice work @bonyuta0204.
Is the maxWidth required?
@sidharthv96
Yes, maxWidth is required. Without it, images could expand to their intrinsic size, which might be much larger than the specified size. |
@bonyuta0204, Thank you for the contribution! |
📑 Summary
Resolved the issue with image size when utilizing only the
<img>
tag in nodes within a flowchart diagram.Resolves #4736
📏 Design Decisions
I have implemented a solution where the size of the
<img>
tag is defined using bothmax-width
andmin-width
properties, specifically in scenarios where a node contains only the<img>
tag. This approach addresses the issue where merely setting the width was insufficient.📋 Tasks
Make sure you
MERMAID_RELEASE_VERSION
is used for all new features.develop
branch