Skip to Content
author's profile photo Former Member
Former Member

Remove treeNode expand/collapse animation

Hello experts,

I have a sap.ui.commons.Tree inside a HBox container and I would like to know if there is any way to remove the expand/collapse animation as it is moving all the content of the page. (when animation ends things are back at its normal place but this effect is not good looking from my point of view). I guess its a CSS3 animation, maybe I can reescribe the css style class and dismiss the animation but I have no clue of how to do that.

Thanks in advance,

Alex.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    Posted on Nov 08, 2015 at 06:07 AM

    Hi Alex,


    For your application responsiveness, you could set the tree height dynamically depending on the data it consists of. In result, you can avoid animation of tree rendering.

    Check this sample: JS Bin - Collaborative JavaScript Debugging

    Regards,

    Sai Vellanki.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 06, 2015 at 05:56 PM

    Did you try setting the height to a fixed number vs auto? If this doesn't help can you provide an example?

    Regards,

    Jamie

    SAP - Technology RIG

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Nov 06, 2015 at 06:31 PM

    Alex, the animation is due to the height: auto as Jamie mentioned. I also had that issue and once I set the height to a specific value, my issue was fixed. This not only affects the tree node, but also any control that may have a dynamic height - further, the behavior is different from different browsers, I believe Chrome is fine, but IE shows the animation hope this helps

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.