Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions js/src/collapse.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ class Collapse extends BaseComponent {
constructor(element, config) {
super(element, config)

this._isShown = element.classList.contains('show')
this._isTransitioning = false
this._triggerArray = []

Expand Down Expand Up @@ -146,6 +147,7 @@ class Collapse extends BaseComponent {
this._isTransitioning = true

const complete = () => {
this._isShown = true
this._isTransitioning = false

this._element.classList.remove(CLASS_NAME_COLLAPSING)
Expand Down Expand Up @@ -193,6 +195,7 @@ class Collapse extends BaseComponent {
this._isTransitioning = true

const complete = () => {
this._isShown = false
this._isTransitioning = false
this._element.classList.remove(CLASS_NAME_COLLAPSING)
this._element.classList.add(CLASS_NAME_COLLAPSE)
Expand Down