Animation not disabled, weird effect

3 posts, 0 answers
  1. Tayger
    Tayger avatar
    191 posts
    Member since:
    Jan 2015

    Posted 22 Apr 2017 Link to this post


    By disabling animation on kendoTabStrip it is still active if you switch tabs programmatically. I have created a demo with two buttons, which switch between tabs programmatically. If you click directly on Tab1 or Tab2 there is no animation and the tabs are displayed right away.
    If you use the switch buttons you see a slide up/down animation effect. Example based on your document code:

    <!DOCTYPE html>
        <meta charset="utf-8"/>
        <title>Kendo UI Snippet</title>
        <script src=""></script>
    <div id="tabstrip">
            <li id="tab1">Tab 1</li>
            <li id="tab2">Tab 2</li>
        <div>Content 1</div>
        <div>Content 2</div>
      <button id= "switch1" type="button">Switch to Tab1</button>
      <button id= "switch2" type="button">Switch to Tab2</button>
           animation: false
        $(document).on("click", "#switch1", function(e) {
         var tabToActivate = $("#tab1");
        $(document).on("click", "#switch2", function(e) {
         var tabToActivate = $("#tab2");


    Shouldn't the animation also be disabled on using activateTab() function?

    Weird behaviour: On disabled animation (animation: false) there is a case where tabstrip content wont be displayed anymore. You can use the demo above to reproduce this:

    1. Start the demo
    2. Click on tab "Tab 1"
    3. Click on button "Switch to Tab2"
    4. Click again on "Tab 1" -> content is not displayed (grey)

    It also works the other way around so Tab2 is not showing content. This weird effect is only reproducible on "animation: false". So I guess its a problem with the animation itself.





  2. Ivan Danchev
    Ivan Danchev avatar
    2184 posts

    Posted 25 Apr 2017 Link to this post


    In both cases (improper animation disable and tab content not being loaded) the reason for the unexpected behavior is that you reinitialize the TabStrip in the click handlers instead of getting a proper reference:

    This reinitializes the TabStrip:

    This gets a reference without reinitializing the widget:

    Modified dojo.

    Ivan Danchev
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
  3. Tayger
    Tayger avatar
    191 posts
    Member since:
    Jan 2015

    Posted 26 Apr 2017 in reply to Ivan Danchev Link to this post

    Thank you Ivan, that was my mistake! Now it runs flawless as it should!
Back to Top