From a451449766d581978068a5b8f8c1e27f50386ea7 Mon Sep 17 00:00:00 2001 From: Mario Date: Thu, 23 Sep 2021 08:33:36 +0000 Subject: Revert "composer update bootstrap to version 5.1.1" This reverts commit 89e4006b2d84d398e34d407a019854823b1dd37d. --- vendor/twbs/bootstrap/js/src/util/backdrop.js | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'vendor/twbs/bootstrap/js/src/util/backdrop.js') diff --git a/vendor/twbs/bootstrap/js/src/util/backdrop.js b/vendor/twbs/bootstrap/js/src/util/backdrop.js index e98d80707..7ba7b4c43 100644 --- a/vendor/twbs/bootstrap/js/src/util/backdrop.js +++ b/vendor/twbs/bootstrap/js/src/util/backdrop.js @@ -1,6 +1,6 @@ /** * -------------------------------------------------------------------------- - * Bootstrap (v5.1.1): util/backdrop.js + * Bootstrap (v5.0.2): util/backdrop.js * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) * -------------------------------------------------------------------------- */ @@ -9,7 +9,6 @@ import EventHandler from '../dom/event-handler' import { execute, executeAfterTransition, getElement, reflow, typeCheckConfig } from './index' const Default = { - className: 'modal-backdrop', isVisible: true, // if false, we use the backdrop helper without adding any element to the dom isAnimated: false, rootElement: 'body', // give the choice to place backdrop under different elements @@ -17,13 +16,13 @@ const Default = { } const DefaultType = { - className: 'string', isVisible: 'boolean', isAnimated: 'boolean', rootElement: '(element|string)', clickCallback: '(function|null)' } const NAME = 'backdrop' +const CLASS_NAME_BACKDROP = 'modal-backdrop' const CLASS_NAME_FADE = 'fade' const CLASS_NAME_SHOW = 'show' @@ -74,7 +73,7 @@ class Backdrop { _getElement() { if (!this._element) { const backdrop = document.createElement('div') - backdrop.className = this._config.className + backdrop.className = CLASS_NAME_BACKDROP if (this._config.isAnimated) { backdrop.classList.add(CLASS_NAME_FADE) } @@ -102,7 +101,7 @@ class Backdrop { return } - this._config.rootElement.append(this._getElement()) + this._config.rootElement.appendChild(this._getElement()) EventHandler.on(this._getElement(), EVENT_MOUSEDOWN, () => { execute(this._config.clickCallback) -- cgit v1.2.3