diff options
Diffstat (limited to 'core/js')
-rw-r--r-- | core/js/singleselect.js | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/core/js/singleselect.js b/core/js/singleselect.js index 1a018b74148..0b7fc20a8f0 100644 --- a/core/js/singleselect.js +++ b/core/js/singleselect.js @@ -1,8 +1,15 @@ (function ($) { $.fn.singleSelect = function () { return this.each(function (i, select) { - var input = $('<input/>'); + var input = $('<input/>'), + inputTooltip = $(select).attr('data-inputtitle'); + if (inputTooltip){ + input.attr('title', inputTooltip); + } select = $(select); + if ($.fn.tipsy){ + input.tipsy({gravity: 'n', trigger: 'manual'}); + } input.css('position', 'absolute'); input.css(select.offset()); input.css({ @@ -29,6 +36,9 @@ } else { event.stopImmediatePropagation(); input.show(); + if ($.fn.tipsy){ + input.tipsy('show'); + } select.css('background-color', 'white'); input.focus(); } @@ -70,6 +80,9 @@ input.on('blur', function () { $(this).change(); + if ($.fn.tipsy){ + $(this).tipsy('hide'); + } }); }); } |