javascript - fakewaffle responsive tab screen issue -
i'm using fakewaffle responsive tab plugin there didn't understand want make responsive on 480px not 768px couldn't how can did ?
html
<ul class="nav nav-tabs responsive" id="mytab"> <li class="active"><a href="#home">home</a> </li> <li><a href="#profile">profile</a> </li> <li><a href="#messages">messages</a> </li> </ul> <div class="tab-content responsive"> <div class="tab-pane active" id="home">...content...</div> <div class="tab-pane" id="profile">...content...</div> <div class="tab-pane" id="messages">...content...</div> </div>
js
$('#mytab a').click(function (e) { e.preventdefault() $(this).tab('show') }); (function ($) { fakewaffle.responsivetabs(['xs', 'sm']); })(jquery);
remove sm
. sm take 768 screen
$('#mytab a').click(function (e) { e.preventdefault() $(this).tab('show') }); (function ($) { var windowsize = $(window).width(); if(windowsize < 480){ fakewaffle.responsivetabs(['xs']); } })(jquery);
Comments
Post a Comment