Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

Commit

Permalink
fix(tooltip): set visibility: hidden to avoid flicker
Browse files Browse the repository at this point in the history
- Set `visibility: hidden` and then to `visible` to avoid flicker from positional movement

Closes #4342
  • Loading branch information
DiHuang1986 authored and wesleycho committed Sep 4, 2015
1 parent 5482db2 commit f7cb8bc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/tooltip/tooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,8 @@ angular.module('ui.bootstrap.tooltip', ['ui.bootstrap.position'])

ttCss.width = ttBox.width + 'px';
ttCss.height = ttBox.height + 'px';

ttCss.visibility = 'visible';

// Now set the calculated positioning and size.
tooltip.css(ttCss);
Expand Down Expand Up @@ -225,7 +227,7 @@ angular.module('ui.bootstrap.tooltip', ['ui.bootstrap.position'])
ttScope.$apply(); // digest required as $apply is not called
}

tooltip.css({ display: 'block' });
tooltip.css({ display: 'block', visibility: 'hidden' });

positionTooltip();
}
Expand Down

0 comments on commit f7cb8bc

Please sign in to comment.