1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-09-28 06:20:15 +02:00

remove old references to jquery and some fixes

This commit is contained in:
Johann-S
2018-03-11 16:18:56 +01:00
committed by XhmikosR
parent 0263d1742c
commit 7eddee286e
14 changed files with 44 additions and 56 deletions

View File

@@ -141,12 +141,11 @@ class Collapse {
}
}
const container = SelectorEngine.findOne(this._selector)
if (actives) {
const tempActiveData = actives.filter((elem) => {
const container = SelectorEngine.findOne(this._selector)
return !container.contains(elem)
})
const tempActiveData = actives.filter((elem) => container !== elem)
activesData = tempActiveData[0] ? Data.getData(tempActiveData[0], DATA_KEY) : null
if (activesData && activesData._isTransitioning) {
return
}
@@ -159,14 +158,14 @@ class Collapse {
if (actives) {
actives.forEach((elemActive) => {
const container = SelectorEngine.findOne(this._selector)
if (!container.contains(elemActive)) {
if (container !== elemActive) {
Collapse._collapseInterface(elemActive, 'hide')
}
if (!activesData) {
Data.setData(elemActive, DATA_KEY, null)
}
})
if (!activesData) {
Data.setData(actives[0], DATA_KEY, null)
}
}
const dimension = this._getDimension()