-
-
Notifications
You must be signed in to change notification settings - Fork 78.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Restore collapse class when a collapse is shown, and remove dependency on panel class #11191
Conversation
Could you add a unit test for the |
Done. Wasn't sure whether to follow the test format of Let me know if I need to change it. |
Why hasn't this been committed? I'm having to patch this in every time a new version is released. |
@@ -541,7 +541,7 @@ if (typeof jQuery === "undefined") { throw new Error("Bootstrap requires jQuery" | |||
this.$element.trigger(startEvent) | |||
if (startEvent.isDefaultPrevented()) return | |||
|
|||
var actives = this.$parent && this.$parent.find('> .panel > .in') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this can't be merged because this is a breaking change for some folks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we added that because the "collapsed.in" selector was to generic and people were opening a bunch of issues about nesting them etc
Should we update the documentation and state that for collapse to work you MUST use panels? I think it is a shame this bug got closed as WONTFIX because there are times where a user might want to use accordions for non-panel components, like link list-group-item's… The problem I see is that the .panel class carries a lot of visual styling with it, so if I just want to have accordion behavior on a list you will have to override the .panel stylesheet with more styling to remove stuff. |
Fixes #10966