Alter Position
jQuery UI Tooltip

jQuery UI TooltipAlter Position jQuery UI Tooltip Plugin to alters position according to the situation.
The default position is under the element. It looks best position. But, it is not sometimes.
For example, it overlap pulldown list of select, or it is too lower position under the high textarea.

This plugin alters position by specified conditions. (e.g. height, tag-name)


The position is altered to altPosition.position (alternative option.position Object of Tooltip) when any following conditions.

NOTE: These are joined by OR. (The position is altered if one or more conditions.)


  altPosition: {
    minOuterHeight: 60,
    tagName: 'select',
    callback: function() { return this.element.val().length > 20; },
    position: {my: 'left+15 top', at: 'right top', collision: 'flipfit'} // Right side


Sample 1

Sample 2