mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-11 08:04:59 +02:00
Dist (#32216)
This commit is contained in:
12
js/dist/alert.js
vendored
12
js/dist/alert.js
vendored
@@ -24,7 +24,7 @@
|
||||
var TRANSITION_END = 'transitionend'; // Shoutout AngusCroll (https://goo.gl/pxwQGp)
|
||||
|
||||
var getSelector = function getSelector(element) {
|
||||
var selector = element.getAttribute('data-target');
|
||||
var selector = element.getAttribute('data-bs-target');
|
||||
|
||||
if (!selector || selector === '#') {
|
||||
var hrefAttr = element.getAttribute('href');
|
||||
@@ -49,8 +49,8 @@
|
||||
transitionDuration = _window$getComputedSt.transitionDuration,
|
||||
transitionDelay = _window$getComputedSt.transitionDelay;
|
||||
|
||||
var floatTransitionDuration = parseFloat(transitionDuration);
|
||||
var floatTransitionDelay = parseFloat(transitionDelay); // Return 0 if element or transition duration is not found
|
||||
var floatTransitionDuration = Number.parseFloat(transitionDuration);
|
||||
var floatTransitionDelay = Number.parseFloat(transitionDelay); // Return 0 if element or transition duration is not found
|
||||
|
||||
if (!floatTransitionDuration && !floatTransitionDelay) {
|
||||
return 0;
|
||||
@@ -59,7 +59,7 @@
|
||||
|
||||
transitionDuration = transitionDuration.split(',')[0];
|
||||
transitionDelay = transitionDelay.split(',')[0];
|
||||
return (parseFloat(transitionDuration) + parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER;
|
||||
return (Number.parseFloat(transitionDuration) + Number.parseFloat(transitionDelay)) * MILLISECONDS_MULTIPLIER;
|
||||
};
|
||||
|
||||
var triggerTransitionEnd = function triggerTransitionEnd(element) {
|
||||
@@ -88,7 +88,7 @@
|
||||
var _window = window,
|
||||
jQuery = _window.jQuery;
|
||||
|
||||
if (jQuery && !document.body.hasAttribute('data-no-jquery')) {
|
||||
if (jQuery && !document.body.hasAttribute('data-bs-no-jquery')) {
|
||||
return jQuery;
|
||||
}
|
||||
|
||||
@@ -117,7 +117,7 @@
|
||||
var DATA_KEY = 'bs.alert';
|
||||
var EVENT_KEY = "." + DATA_KEY;
|
||||
var DATA_API_KEY = '.data-api';
|
||||
var SELECTOR_DISMISS = '[data-dismiss="alert"]';
|
||||
var SELECTOR_DISMISS = '[data-bs-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;
|
||||
|
Reference in New Issue
Block a user