Committer: dpetrov
LJSUP-8132: Need to change bubbleU trunk/htdocs/js/share.js
Modified: trunk/htdocs/js/share.js =================================================================== --- trunk/htdocs/js/share.js 2011-03-14 02:34:59 UTC (rev 18525) +++ trunk/htdocs/js/share.js 2011-03-14 03:39:04 UTC (rev 18526) @@ -208,6 +208,18 @@ linkH = link.height(), linkW = link.width(), arrPos = ""; + //we check if child elements of the link have bigger dimensions. + link.find( '*' ).each( function() { + var $this = $( this ), + position = $this.css( 'position' ), + height = $( this ).outerHeight(); + + if( $this.is( ':visible' ) && position != 'absolute' + && position != 'fixed' && height > linkH ) { + linkH = height; + } + } ); + dom.css( { left: "0px", top: "0px" } ); var scrollOffset = $( window ).scrollTop(); @@ -223,7 +235,7 @@ linkTop -= domH + 9; arrPos += "b"; } else { - linkTop += linkH + 9; + linkTop += linkH + 7; arrPos += "t"; }