Root node not centered #562
Replies: 15 comments
-
Hi, @christopheSeeka , 2 questions:
It looks like the root node was taller and narrower when it was first loaded, and then became shorter and wider when the style was loaded. |
Beta Was this translation helpful? Give feedback.
-
Hi, thank you for the answer,
Knowing that the issue seem related to white-space: normal!important; in jmnode.root, if i remove it, it is centered from the start even with max-width: 650px for example so it seem that switching white-space to multiline is triggering the problem. |
Beta Was this translation helpful? Give feedback.
-
This is first load with just changing:
to
It center properly right away. |
Beta Was this translation helpful? Give feedback.
-
Yes, by default, how the customized css rules loaded? is it loaded before executing
I guess it will work if you add a new <link...> referencing to this stylesheet, just like how you reference And have you considered to add the styles as a new theme? BTW, If you just want to wrap text, there is an option |
Beta Was this translation helpful? Give feedback.
-
Hello, thank you very much, view.node_overflow do the job so i don't need to overide the white-space in my css anymore :) I have a question, is there a way to identify left node to right nodes? basically i'd like to have text-align left on right nodes and text-align right on left node but i don't see any way to identify left one to right one. |
Beta Was this translation helpful? Give feedback.
-
-1: left, 1: right |
Beta Was this translation helpful? Give feedback.
-
Thank you, so i have to go over each nodes in a js loop and add classes based on direction, is that correct? |
Beta Was this translation helpful? Give feedback.
-
You can leverage |
Beta Was this translation helpful? Give feedback.
-
This is a sample of how to use the option https://github.com/hizzgdev/jsmind-samples/blob/main/jsmind-use-cases/jsmind-mathjax.html |
Beta Was this translation helpful? Give feedback.
-
Thank you very much, will try figure that out :) |
Beta Was this translation helpful? Give feedback.
-
Perfect, it's working, thank you very much :)
then
Thank you very much :) |
Beta Was this translation helpful? Give feedback.
-
I noticed that using hide_scrollbars_when_draggable: true work well on desktop but the drag don't work on mobile with this activated, is it a known issue? |
Beta Was this translation helpful? Give feedback.
-
We didn't do much on mobile compatibility. I guess that on the mobile device, the touch screen is actually a simulated scroll bar, and |
Beta Was this translation helpful? Give feedback.
-
Make sens, i will do that, thank you :) |
Beta Was this translation helpful? Give feedback.
-
will move this topic to Discussion |
Beta Was this translation helpful? Give feedback.
-
Hello,
Implementing jsmind into our project and quite happy with the result but for some reason, i'm running into the following issue:
When i load the mindmap for the the first time, the root node is not centered.
If i clear it and load it again, it is centered.
I did change the css as follow to have the root node multiline and adjust a bit the expander that wasn't well aligned:
and in js (vue3 application) i do the following:
Any idea what i could be missing?
Beta Was this translation helpful? Give feedback.
All reactions