Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Request: Add TABLE and UL foldable in Panel foldable #12963

vdeapps opened this Issue Mar 7, 2014 · 4 comments


None yet
3 participants

vdeapps commented Mar 7, 2014

I need to have panel foldable.
It run correctly with panel-body but not with table or ul element.

For now I fixed it with this code:

setBsPanelFoldable: function(context) {
if (typeof context == 'undefined') {
context = document;

    // ajout de l'icone
    var dataFoldable = $('[data-bs-foldable]', context);
    if (dataFoldable.length > 0) {
                    //Add icon to differency panel to foldable panel
        if (dataFoldable.data('bsFoldable') != 'noicon') {
            dataFoldable.prepend('<div class="pull-right" data-bs-tooltip="true" title="show/hide"><i class="fa fa-caret-down fa-fw"></i></div>');

    $(document).on('click', '.panel-heading[data-bs-foldable]', function() {
        $('.panel-body, .table', $(this).parent('.panel')).first().slideToggle();

cvrebert commented Mar 7, 2014

Please create a live example (e.g. JS Fiddle) demonstrating the problem.


cvrebert commented Mar 7, 2014

Ah, okay, I guess you mean using the Collapse/Accordion plugin with these sorts of panels?:

vdeapps commented Mar 7, 2014


It woks fine with panel-body and now with my javascript it works fine with


mdo commented Mar 7, 2014

We'll pass on this for now. The HTML and CSS is already quite gnarly to support what we have today.

@mdo mdo closed this Mar 7, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment