Cyberlacs
Cyberlacs

Reputation: 201

How to make jquery scroll functions ui-touch-punch work with responsive div class from bootstrap?

Table without table-responsive class div works perfectly with the sortable options of api jquery ui,

$(document).ready (function () {
    $("#sortable").sortable ({
        scroll: true,
        scrollSensitivity: 20,
        scrollSpeed: 40,
    });
    $("#sortable").disableSelection ();
});

<table class = "table-hover table-striped">
    <tr> <td> many, many lines <td> </tr>
</table>

But when we put the responsiveness option in the table the options described above do not work

<div class = "table-responsive">
     <table class = "table-hover table-striped">
              <tr> <td> many, many lines <td> </tr>
    </table>
</div>

The scroll: true, scrollSensitivity: 20, scrollSpeed: 40 options stop working.

How do these options work together with the div class of resposivity?

Upvotes: 1

Views: 334

Answers (1)

JakeCigar
JakeCigar

Reputation: 603

$("# sortable").sortable ({

is invalid. Use

$("#sortable").sortable ({

Upvotes: 2

Related Questions