$(document).on('click','.data-open-details', function (e) { e.preventDefault(); $(this).next().toggleClass('is-active'); $(this).toggleClass('is-active'); }); code example
Example: toggle class
<div class="tumble">Some text.</div>
<div class="tumble">Some text.</div>