Demo: ngResponsiveNavigation
This jQuery script creates navigation used for the mobile phones and tablets. When collapsing, navigation is animating from left to right, calculating current window width minus button width (very similar like on youtube mobile app).
Default options:
$(function(){
responsiveNavigation.init({
navPrefix: 'ng',
mainWrapper: '.content-wrapper',
navigationWrapper: '#ng-navigation',
navigationInner: '.ng-nav',
buttonMargin: 30
});
});
- navPrefix - prefix used for all selectors in this script
- mainWrapper - main content area. Put here all the content of your web site
- buttonMargin - margin used to separate button from collapsable navigation
- If you add section name in ul, it will automatically create h2 tag out of it
If you are changing prefix and classes in html file, do not forget to change your CSS file!
Tomislav Matijević