Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed header with overlay collapse and fixed nav #61

Open
Krishnanandkg opened this issue Sep 29, 2017 · 0 comments
Open

Fixed header with overlay collapse and fixed nav #61

Krishnanandkg opened this issue Sep 29, 2017 · 0 comments

Comments

@Krishnanandkg
Copy link

Hi, am a newbie, is there anyway i could implement a fixed header with items in the offcanvas fixed [on page scroll.]. Also the offcanvas should collapse when clicked anywhere outside.

  • tried to combine the fixes mentioned in other posts, but couldnt make it work.

Heres something I've tried:

$(function() {

$('#scotch-panel').scotchPanel({
    containerSelector: '#site-wrapper',
    direction: 'right',
    duration: 300,
    transition: 'ease',
    clickSelector: '.toggle-panel',
    distanceX: '460px',
    enableEscapeKey: true
});



$('.toggle-panel').click(function() {
    scotchPanel.toggle();
    return false;
});

$('.overlay').click(function() {
  // CLOSE ONLY 
   #fixed-nav.close();
});

});

Couldnt make it work tho.

Appreciate any help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant