Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dist/js/bootstrap.bundle.js')
-rw-r--r--dist/js/bootstrap.bundle.js23
1 files changed, 8 insertions, 15 deletions
diff --git a/dist/js/bootstrap.bundle.js b/dist/js/bootstrap.bundle.js
index 4767e2f826..ec2a964888 100644
--- a/dist/js/bootstrap.bundle.js
+++ b/dist/js/bootstrap.bundle.js
@@ -975,17 +975,6 @@
top: element.offsetTop,
left: element.offsetLeft
};
- },
- toggleClass: function toggleClass(element, className) {
- if (!element) {
- return;
- }
-
- if (element.classList.contains(className)) {
- element.classList.remove(className);
- } else {
- element.classList.add(className);
- }
}
};
@@ -4844,8 +4833,10 @@
this._element.setAttribute('aria-expanded', true);
- Manipulator.toggleClass(this._menu, CLASS_NAME_SHOW$1);
- Manipulator.toggleClass(this._element, CLASS_NAME_SHOW$1);
+ this._menu.classList.toggle(CLASS_NAME_SHOW$1);
+
+ this._element.classList.toggle(CLASS_NAME_SHOW$1);
+
EventHandler.trigger(parent, EVENT_SHOWN$1, relatedTarget);
};
@@ -4868,8 +4859,10 @@
this._popper.destroy();
}
- Manipulator.toggleClass(this._menu, CLASS_NAME_SHOW$1);
- Manipulator.toggleClass(this._element, CLASS_NAME_SHOW$1);
+ this._menu.classList.toggle(CLASS_NAME_SHOW$1);
+
+ this._element.classList.toggle(CLASS_NAME_SHOW$1);
+
EventHandler.trigger(parent, EVENT_HIDDEN$1, relatedTarget);
};