Skip to content

Commit

Permalink
fix hint position with scrolltop
Browse files Browse the repository at this point in the history
  • Loading branch information
olton committed Aug 17, 2014
1 parent d4fd512 commit e4b9664
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/js/metro.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion docs/js/metro/metro-hint.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
//console.log(_hint);

if (o.position == 'top') {
console.log(element.offset().top - $(window).scrollTop() - _hint.outerHeight() - 20);
console.log(element.offset().top - $(window).scrollTop() - 20);
_hint.css({
top: element.offset().top - $(window).scrollTop() - _hint.outerHeight() - 20,
left: o.mode == 2 ? element.offset().left + element.outerWidth()/2 - _hint.outerWidth()/2 - $(window).scrollLeft(): element.offset().left - $(window).scrollLeft()
Expand Down
2 changes: 1 addition & 1 deletion js/metro-hint.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
//console.log(_hint);

if (o.position == 'top') {
console.log(element.offset().top - $(window).scrollTop() - _hint.outerHeight() - 20);
console.log(element.offset().top - $(window).scrollTop() - 20);
_hint.css({
top: element.offset().top - $(window).scrollTop() - _hint.outerHeight() - 20,
left: o.mode == 2 ? element.offset().left + element.outerWidth()/2 - _hint.outerWidth()/2 - $(window).scrollLeft(): element.offset().left - $(window).scrollLeft()
Expand Down
2 changes: 1 addition & 1 deletion min/metro.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit e4b9664

Please sign in to comment.