cl-deck-builder2/templates/tabs-js.html
2024-03-05 22:11:33 -05:00

16 lines
497 B
HTML

<script>
function openTab(evt, tabName) {
var i, x, tablinks;
x = document.getElementsByClassName("content-tab");
for (i = 0; i < x.length; i++) {
x[i].style.display = "none";
}
tablinks = document.getElementsByClassName("tab");
for (i = 0; i < x.length; i++) {
$(tablinks[i]).removeClass("is-active");
}
document.getElementById(tabName).style.display = "block";
$(evt.currentTarget).addClass("is-active");
}
</script>