Search code examples
twitter-bootstraptooltipangular-ui-bootstrap

Change amount of time Bootstrap tooltips display / fade in and out


I'm adding tooltips using Twitter Bootstrap, is there an attribute I can add which determines how long a tooltip displays for / how long it takes to fade in and out?

<span class="myClass" data-tooltip="{{myData}}" data-tooltip-placement="right"></span>

Cheers


Solution

  • Bootstrap uses the class .fade for the opacity change of the tooltips. It looks like this in the CSS file:

    .fade {
        opacity:0;
        -webkit-transition: opacity .15s linear;
        -o-transition: opacity .15s linear;
        transition: opacity .15s linear;
    }
    

    Just change the .15s of the transition properties to your desired duration.