Skip to content

Commit

Permalink
Merge pull request #451 from rashidkpc/master
Browse files Browse the repository at this point in the history
added tip directive for defining question mark tooltips
  • Loading branch information
Rashid Khan committed Aug 30, 2013
2 parents 838d78c + c0a5b0a commit cd8009e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions js/directives.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,15 @@ angular.module('kibana.directives', [])
}
};
})
.directive('tip', function($compile) {
return {
restrict: 'E',
link: function(scope, elem, attrs) {
var _t = '<i class="icon-question-sign" bs-tooltip="\''+elem.text()+'\'"></i>';
elem.replaceWith($compile(angular.element(_t))(scope));
}
};
})
.directive('addPanel', function($compile) {
return {
restrict: 'A',
Expand Down

0 comments on commit cd8009e

Please sign in to comment.