Reputation: 738
I've created a tooltip (using JQuery UI) with a connector for an image. Fiddle is here
$(document).tooltip({
position: { my: "left bottom-5", at: "left top",
using: function( position, feedback ) {
$( this ).css( position );
$( "<div>" )
.addClass( "arrow" )
.addClass( feedback.vertical )
.addClass( feedback.horizontal )
.appendTo( this );
}
},
show: false,
hide: false
});
The tooltip on the bottom image, when a collision is not detected, looks great. But when a collision is detected (top image), the tooltip flips to the bottom, but the positioning of the arrow is wrong.
I'm new to the Positioning element. How would I ensure that when the tooltip flips, it stays together and lines up with the image's bottom as it lines up with the top?
Thanks!
Upvotes: 1
Views: 3041