fancytree icon indicating copy to clipboard operation
fancytree copied to clipboard

Animation bug when expanding/collapsing nodes

Open romant-1 opened this issue 9 years ago • 5 comments

Hi guys, There is an animation bug when expanding/collapsing tree nodes. The container of the node that's being expanded/collapsed seems to be by approx. 15px wider than the parent tree container. This is happening only during the animation phase. Please see the attached images to see the issue.

animation-bug-chrome animation-bug-firefox

To reproduce the issue just load the following URL in Chrome and expand/collapse any node. The issue will be visible on the right hand side of the element which contains the tree.

This happened to me in In Chrome (Version 59.0.3071.115) and Firefox (Version 54.0), I haven't tried other browsers.

Regarding the version of JQuery , Fancytree, etc. it's all obviously available on the test page.

This is pretty annoying in cases when there is another element(s) next to the tree as every time when the node expanding/collapsing animation is happening all the elements next to the tree are pushed to the right a bit. This issue seems to be happening only if the tree container doesn't have any fixed width specified - giving it a fixed width possibly doesn't fix the issue but just hides it.

Hopefully this won't be too difficult to fix.

romant-1 avatar Jul 01 '17 06:07 romant-1

Hi.

I had the same problem, and came up with a quick, hacky workaround that might help you while you're waiting for this issue to be addressed properly. In my case, the tree's container width was actually being pushed a bit each time a folder was animating its expand or collapse.

So I just added the following CSS class to my page, after the FancyTree styles are included, and now it works just fine...

ul.ui-effects-placeholder { width:10px !important; }

NB: The order of inclusion might not matter, !important is probably not necessary, and 10px was just a random pick which worked for me with the expand/collapse folder animations. (I didn't spend too much time investigating the why's and wherefore's, just wanted a quick fix and this seems to do the job.)

Good luck!

CookieJon avatar Jul 16 '17 23:07 CookieJon

Thanks heaps @CookieJon, much appreciated. I ended up with a similar hack, a proper solution would be definitely better.

romant-1 avatar Jul 16 '17 23:07 romant-1

FYI, I just ran into this same issue with folder open/close animation - so still not addressed. @CookieJon's hack seems to work.

dvstans avatar May 09 '18 17:05 dvstans

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Oct 22 '19 16:10 stale[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Mar 14 '20 19:03 stale[bot]