mirror of
https://github.com/Radarr/Radarr
synced 2026-01-08 08:33:55 +01:00
29 lines
No EOL
621 B
JavaScript
29 lines
No EOL
621 B
JavaScript
var $ = require('jquery');
|
|
require('bootstrap');
|
|
|
|
var Tooltip = $.fn.tooltip.Constructor;
|
|
|
|
var origGetOptions = Tooltip.prototype.getOptions;
|
|
Tooltip.prototype.getOptions = function(options) {
|
|
var result = origGetOptions.call(this, options);
|
|
|
|
if (result.container === false) {
|
|
|
|
var container = this.$element.closest('.btn-group,.input-group').parent();
|
|
|
|
if (container.length) {
|
|
result.container = container;
|
|
}
|
|
}
|
|
|
|
return result;
|
|
};
|
|
|
|
module.exports = {
|
|
appInitializer : function() {
|
|
|
|
$('body').tooltip({ selector : '[title]' });
|
|
|
|
return this;
|
|
}
|
|
}; |