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

Mermaid diagrams are cropped #391

Open
1 of 2 tasks
jcayzac opened this issue Feb 18, 2021 · 4 comments
Open
1 of 2 tasks

Mermaid diagrams are cropped #391

jcayzac opened this issue Feb 18, 2021 · 4 comments

Comments

@jcayzac
Copy link

jcayzac commented Feb 18, 2021

Info

  • Operating System: macOS 11.2
  • Node Version: 15.6.0
  • Browser Name and Version: Chrome 88
  • Fusuma Version: 2.5.0

Type

  • bug
  • feature request

For Bugs

With the default theme, mermaid diagrams that are larger than 320px are cropped.

Screen Shot 2021-02-18 at 18 16 45

Expected Behavior

Diagrams aren't cropped but resized instead.

Actual Behavior

Diagrams are cropped.

How can we reproduce the behavior?

Test diagram:

gitGraph:
options
{
  "nodeSpacing": 150,
  "nodeRadius": 10
}
end
commit
branch newbranch
checkout newbranch
commit
commit
checkout master
commit
commit
merge newbranch
@hiroppy
Copy link
Owner

hiroppy commented Feb 18, 2021

Fixed, thanks. https://hiroppy.github.io/fusuma/advanced/#slide-1

@jcayzac
Copy link
Author

jcayzac commented Feb 18, 2021

@hiroppy thank you. It still looks cropped on my phone tho (the SVG doesn't seem to have CSS to constrain its width to the viewport):

Screenshot_20210218_220438_com android chrome

@hiroppy
Copy link
Owner

hiroppy commented Feb 18, 2021

yeah, I think we should add overflow to the container class. I'll consider it.

@hiroppy hiroppy reopened this Feb 18, 2021
@hiroppy
Copy link
Owner

hiroppy commented Feb 18, 2021

hm, I checked it but mermaid calculates the current client size and yes it doesn' have viewport....

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

No branches or pull requests

2 participants