diff options
author | Mario <mario@mariovavti.com> | 2020-11-05 08:46:42 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2020-11-05 08:46:42 +0000 |
commit | bafbf0416462c6f18c3fb6c8c06a063c8d6fdae6 (patch) | |
tree | 8929845be585b09d0f420621281c5531e1efad3e /vendor/twbs/bootstrap/js/dist/alert.js | |
parent | 6f93d9848c43019d43ea76c27d42d657ba031cd7 (diff) | |
parent | fdefa101d84dc2a9424eaedbdb003a4c30ec5d01 (diff) | |
download | volse-hubzilla-5.0.tar.gz volse-hubzilla-5.0.tar.bz2 volse-hubzilla-5.0.zip |
Merge branch '5.0RC'5.0
Diffstat (limited to 'vendor/twbs/bootstrap/js/dist/alert.js')
-rw-r--r-- | vendor/twbs/bootstrap/js/dist/alert.js | 86 |
1 files changed, 32 insertions, 54 deletions
diff --git a/vendor/twbs/bootstrap/js/dist/alert.js b/vendor/twbs/bootstrap/js/dist/alert.js index 2a2e157ed..7a443da46 100644 --- a/vendor/twbs/bootstrap/js/dist/alert.js +++ b/vendor/twbs/bootstrap/js/dist/alert.js @@ -1,33 +1,20 @@ /*! - * Bootstrap alert.js v4.3.1 (https://getbootstrap.com/) - * Copyright 2011-2019 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) - * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) + * Bootstrap alert.js v4.5.2 (https://getbootstrap.com/) + * Copyright 2011-2020 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) + * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE) */ (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('jquery'), require('./util.js')) : typeof define === 'function' && define.amd ? define(['jquery', './util.js'], factory) : - (global = global || self, global.Alert = factory(global.jQuery, global.Util)); -}(this, function ($, Util) { 'use strict'; - - $ = $ && $.hasOwnProperty('default') ? $['default'] : $; - Util = Util && Util.hasOwnProperty('default') ? Util['default'] : Util; - - function _defineProperties(target, props) { - for (var i = 0; i < props.length; i++) { - var descriptor = props[i]; - descriptor.enumerable = descriptor.enumerable || false; - descriptor.configurable = true; - if ("value" in descriptor) descriptor.writable = true; - Object.defineProperty(target, descriptor.key, descriptor); - } - } - - function _createClass(Constructor, protoProps, staticProps) { - if (protoProps) _defineProperties(Constructor.prototype, protoProps); - if (staticProps) _defineProperties(Constructor, staticProps); - return Constructor; - } + (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.Alert = factory(global.jQuery, global.Util)); +}(this, (function ($, Util) { 'use strict'; + $ = $ && Object.prototype.hasOwnProperty.call($, 'default') ? $['default'] : $; + Util = Util && Object.prototype.hasOwnProperty.call(Util, 'default') ? Util['default'] : Util; + + function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; } /** * ------------------------------------------------------------------------ * Constants @@ -35,34 +22,25 @@ */ var NAME = 'alert'; - var VERSION = '4.3.1'; + var VERSION = '4.5.2'; var DATA_KEY = 'bs.alert'; var EVENT_KEY = "." + DATA_KEY; var DATA_API_KEY = '.data-api'; var JQUERY_NO_CONFLICT = $.fn[NAME]; - var Selector = { - DISMISS: '[data-dismiss="alert"]' - }; - var Event = { - CLOSE: "close" + EVENT_KEY, - CLOSED: "closed" + EVENT_KEY, - CLICK_DATA_API: "click" + EVENT_KEY + DATA_API_KEY - }; - var ClassName = { - ALERT: 'alert', - FADE: 'fade', - SHOW: 'show' - /** - * ------------------------------------------------------------------------ - * Class Definition - * ------------------------------------------------------------------------ - */ - - }; + var SELECTOR_DISMISS = '[data-dismiss="alert"]'; + var EVENT_CLOSE = "close" + EVENT_KEY; + var EVENT_CLOSED = "closed" + EVENT_KEY; + var EVENT_CLICK_DATA_API = "click" + EVENT_KEY + DATA_API_KEY; + var CLASS_NAME_ALERT = 'alert'; + var CLASS_NAME_FADE = 'fade'; + var CLASS_NAME_SHOW = 'show'; + /** + * ------------------------------------------------------------------------ + * Class Definition + * ------------------------------------------------------------------------ + */ - var Alert = - /*#__PURE__*/ - function () { + var Alert = /*#__PURE__*/function () { function Alert(element) { this._element = element; } // Getters @@ -102,14 +80,14 @@ } if (!parent) { - parent = $(element).closest("." + ClassName.ALERT)[0]; + parent = $(element).closest("." + CLASS_NAME_ALERT)[0]; } return parent; }; _proto._triggerCloseEvent = function _triggerCloseEvent(element) { - var closeEvent = $.Event(Event.CLOSE); + var closeEvent = $.Event(EVENT_CLOSE); $(element).trigger(closeEvent); return closeEvent; }; @@ -117,9 +95,9 @@ _proto._removeElement = function _removeElement(element) { var _this = this; - $(element).removeClass(ClassName.SHOW); + $(element).removeClass(CLASS_NAME_SHOW); - if (!$(element).hasClass(ClassName.FADE)) { + if (!$(element).hasClass(CLASS_NAME_FADE)) { this._destroyElement(element); return; @@ -132,7 +110,7 @@ }; _proto._destroyElement = function _destroyElement(element) { - $(element).detach().trigger(Event.CLOSED).remove(); + $(element).detach().trigger(EVENT_CLOSED).remove(); } // Static ; @@ -178,7 +156,7 @@ */ - $(document).on(Event.CLICK_DATA_API, Selector.DISMISS, Alert._handleDismiss(new Alert())); + $(document).on(EVENT_CLICK_DATA_API, SELECTOR_DISMISS, Alert._handleDismiss(new Alert())); /** * ------------------------------------------------------------------------ * jQuery @@ -195,5 +173,5 @@ return Alert; -})); +}))); //# sourceMappingURL=alert.js.map |