Click here to Skip to main content
15,888,590 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I want to use nanoscroller in a bootstrap modal. I have an inner div which wraps up the body of my modal and an outer div which encloses the inner div.
HTML
<div class="nano modal-body ">
        <div class=" content">
            <p>.....My content here...</p>
        </div>
</div>

As you can can see below, I've set the height of the outer div to 100px. But somehow it doesn't work.
CSS
.nano {
    height: 100px!important;
}
.nano .pane {
    background: #888;
}
.nano .slider {
    background: #111;
}

And heres how i've called it.
JavaScript
$(".nano").nanoScroller();


i.e.,
i want this:


http://s12.postimg.org/upg1i8qct/image.png


in place of

http://s16.postimg.org/58wbl6c05/image.png


Heres the nanoscroller documentation
Check it out on jsfiddle
Posted
Updated 11-Sep-13 2:09am
v6
Comments
ZurdoDev 11-Sep-13 7:26am    
I looked at your jsfiddle. What's the problem?
Devasish Panda 11-Sep-13 7:43am    
You must have noticed that the default browser scroller is getting shown beside the modal, which instead should have been replaced by the nanoscroller.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900