aboutsummaryrefslogtreecommitdiff
path: root/js/dist/tooltip.js
diff options
context:
space:
mode:
authorThomas McDonald <[email protected]>2015-08-12 21:09:44 -0700
committerThomas McDonald <[email protected]>2015-08-12 21:09:44 -0700
commit35f064f96ccbadfbb830ae05e2f00d60ec215e68 (patch)
treede8cf38186002d5d7c1a5231c65106e7c899111f /js/dist/tooltip.js
parenta8023edf16975d5ec34a6e4056df3c6404de8c8d (diff)
parentf2ae3ea04309cabedabf8160c771b6b465c912e6 (diff)
downloadbootstrap-35f064f96ccbadfbb830ae05e2f00d60ec215e68.tar.xz
bootstrap-35f064f96ccbadfbb830ae05e2f00d60ec215e68.zip
Merge branch 'v4' of github.com:twbs/derpstrap into v4
Diffstat (limited to 'js/dist/tooltip.js')
-rw-r--r--js/dist/tooltip.js87
1 files changed, 43 insertions, 44 deletions
diff --git a/js/dist/tooltip.js b/js/dist/tooltip.js
index 864e0bb76..9f08af16b 100644
--- a/js/dist/tooltip.js
+++ b/js/dist/tooltip.js
@@ -125,6 +125,14 @@ var Tooltip = (function ($) {
this._setListeners();
}
+ /**
+ * ------------------------------------------------------------------------
+ * jQuery
+ * ------------------------------------------------------------------------
+ */
+
+ // getters
+
_createClass(Tooltip, [{
key: 'enable',
@@ -296,11 +304,11 @@ var Tooltip = (function ($) {
this._hoverState = '';
}
- }, {
- key: 'isWithContent',
// protected
+ }, {
+ key: 'isWithContent',
value: function isWithContent() {
return !!this.getTitle();
}
@@ -346,11 +354,11 @@ var Tooltip = (function ($) {
$(this.tip).removeClass(this._removeTetherClasses);
}
}
- }, {
- key: '_getAttachment',
// private
+ }, {
+ key: '_getAttachment',
value: function _getAttachment(placement) {
return AttachmentMap[placement.toUpperCase()];
}
@@ -509,79 +517,70 @@ var Tooltip = (function ($) {
return config;
}
+
+ // static
+
}], [{
- key: 'VERSION',
+ key: '_jQueryInterface',
+ value: function _jQueryInterface(config) {
+ return this.each(function () {
+ var data = $(this).data(DATA_KEY);
+ var _config = typeof config === 'object' ? config : null;
+
+ if (!data && /destroy|hide/.test(config)) {
+ return;
+ }
- // getters
+ if (!data) {
+ data = new Tooltip(this, _config);
+ $(this).data(DATA_KEY, data);
+ }
- get: function () {
+ if (typeof config === 'string') {
+ data[config]();
+ }
+ });
+ }
+ }, {
+ key: 'VERSION',
+ get: function get() {
return VERSION;
}
}, {
key: 'Default',
- get: function () {
+ get: function get() {
return Default;
}
}, {
key: 'NAME',
- get: function () {
+ get: function get() {
return NAME;
}
}, {
key: 'DATA_KEY',
- get: function () {
+ get: function get() {
return DATA_KEY;
}
}, {
key: 'Event',
- get: function () {
+ get: function get() {
return Event;
}
}, {
key: 'EVENT_KEY',
- get: function () {
+ get: function get() {
return EVENT_KEY;
}
}, {
key: 'DefaultType',
- get: function () {
+ get: function get() {
return DefaultType;
}
- }, {
- key: '_jQueryInterface',
-
- // static
-
- value: function _jQueryInterface(config) {
- return this.each(function () {
- var data = $(this).data(DATA_KEY);
- var _config = typeof config === 'object' ? config : null;
-
- if (!data && /destroy|hide/.test(config)) {
- return;
- }
-
- if (!data) {
- data = new Tooltip(this, _config);
- $(this).data(DATA_KEY, data);
- }
-
- if (typeof config === 'string') {
- data[config]();
- }
- });
- }
}]);
return Tooltip;
})();
- /**
- * ------------------------------------------------------------------------
- * jQuery
- * ------------------------------------------------------------------------
- */
-
$.fn[NAME] = Tooltip._jQueryInterface;
$.fn[NAME].Constructor = Tooltip;
$.fn[NAME].noConflict = function () {
@@ -591,4 +590,4 @@ var Tooltip = (function ($) {
return Tooltip;
})(jQuery);
-//# sourceMappingURL=tooltip.js.map \ No newline at end of file
+//# sourceMappingURL=tooltip.js.map