mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-10 15:44:51 +02:00
Dist (#32323)
This commit is contained in:
20
js/dist/popover.js
vendored
20
js/dist/popover.js
vendored
@@ -5,7 +5,7 @@
|
||||
*/
|
||||
(function (global, factory) {
|
||||
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('./dom/data.js'), require('./dom/selector-engine.js'), require('./tooltip.js')) :
|
||||
typeof define === 'function' && define.amd ? define(['./dom/data.js', './dom/selector-engine.js', './tooltip.js'], factory) :
|
||||
typeof define === 'function' && define.amd ? define(['./dom/data', './dom/selector-engine', './tooltip'], factory) :
|
||||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Popover = factory(global.Data, global.SelectorEngine, global.Tooltip));
|
||||
}(this, (function (Data, SelectorEngine, Tooltip) { 'use strict';
|
||||
|
||||
@@ -55,7 +55,6 @@
|
||||
*/
|
||||
|
||||
var NAME = 'popover';
|
||||
var VERSION = '5.0.0-alpha3';
|
||||
var DATA_KEY = 'bs.popover';
|
||||
var EVENT_KEY = "." + DATA_KEY;
|
||||
var CLASS_PREFIX = 'bs-popover';
|
||||
@@ -65,7 +64,7 @@
|
||||
placement: 'right',
|
||||
trigger: 'click',
|
||||
content: '',
|
||||
template: '<div class="popover" role="tooltip">' + '<div class="popover-arrow"></div>' + '<h3 class="popover-header"></h3>' + '<div class="popover-body"></div></div>'
|
||||
template: '<div class="popover" role="tooltip">' + '<div class="popover-arrow"></div>' + '<h3 class="popover-header"></h3>' + '<div class="popover-body"></div>' + '</div>'
|
||||
});
|
||||
|
||||
var DefaultType = _extends({}, Tooltip__default['default'].DefaultType, {
|
||||
@@ -116,7 +115,7 @@
|
||||
var content = this._getContent();
|
||||
|
||||
if (typeof content === 'function') {
|
||||
content = content.call(this.element);
|
||||
content = content.call(this._element);
|
||||
}
|
||||
|
||||
this.setElementContent(SelectorEngine__default['default'].findOne(SELECTOR_CONTENT, tip), content);
|
||||
@@ -129,7 +128,7 @@
|
||||
};
|
||||
|
||||
_proto._getContent = function _getContent() {
|
||||
return this.element.getAttribute('data-bs-content') || this.config.content;
|
||||
return this._element.getAttribute('data-bs-content') || this.config.content;
|
||||
};
|
||||
|
||||
_proto._cleanTipClass = function _cleanTipClass() {
|
||||
@@ -171,18 +170,9 @@
|
||||
});
|
||||
};
|
||||
|
||||
Popover.getInstance = function getInstance(element) {
|
||||
return Data__default['default'].getData(element, DATA_KEY);
|
||||
};
|
||||
|
||||
_createClass(Popover, null, [{
|
||||
key: "VERSION",
|
||||
// Getters
|
||||
get: function get() {
|
||||
return VERSION;
|
||||
}
|
||||
}, {
|
||||
key: "Default",
|
||||
// Getters
|
||||
get: function get() {
|
||||
return Default;
|
||||
}
|
||||
|
Reference in New Issue
Block a user