inuyaksa / jquery.nicescroll

nicescroll plugin for jquery - scrollbars like iphone/ipad
https://nicescroll.areaaperta.com/
3.6k stars 1.67k forks source link

Nicescroll overlap issue in bootstrap tab #700

Open Arvn41 opened 7 years ago

Arvn41 commented 7 years ago

hello , I have tried elvismdev's code http://stackoverflow.com/a/26643506/2209086 and its work like charm, same code am trying to modify but scrollbar still overlap. In my structure there is panel under tab pane, and table responsive div under panel, i want to apply scrollbar to table-responsive class my html is

issue1

same structure for each tab with different table ID my js code is

$('body').on('click', '[data-toggle="tab"]', function () { $(".tab-pane .panel .table-responsive").getNiceScroll().hide(); $($(this).attr('href')).find(".tab-pane .panel .table-responsive").niceScroll({ cursorcolor: "#2f6098", cursorwidth: 10, cursoropacitymin: 0.7, autohidemode:"false" }); $($(this).attr('href')).find(".tab-pane .panel .table-responsive").getNiceScroll().show(); })

for first tab its working but for others its not working properly, when i inspect all scrolls are created by plugin but not showing proper tab scroll, if I resize window after tab click its work like charm. Please help me where am going wrong