forked from dsjoerg/ggtracker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathggtipper2.js
More file actions
30 lines (25 loc) · 729 Bytes
/
ggtipper2.js
File metadata and controls
30 lines (25 loc) · 729 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
gg.directive('ggtipper2', function() {
return {
restrict: 'C',
link: function(scope, elm, attrs) {
// hack for wcs
if (window.dontggtipper) {
return;
}
if($(elm).data('gravity')) {
gravity = $(elm).data('gravity');
} else {
gravity = $.fn.tipsy.autoBounds(10, 'sw');
}
// console.log("dada", $(elm), $(elm).data('content'));
// title: $(elm).data('content'),
$(elm).tipsy({
className: 'htmltip',
html: true,
opacity: 1.0,
offset: 10,
gravity: gravity
});
}
};
});