You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
|
|
|
$(document).ready( () => {
|
|
|
|
console.log('Load component - header')
|
|
|
|
|
|
|
|
const components = $('.component-header')
|
|
|
|
|
|
|
|
components.each( (i, e) => {
|
|
|
|
const component = $(e)
|
|
|
|
const hamburger = component.find('.hamburger')
|
|
|
|
const menu = component.find('.sidebar-menu')
|
|
|
|
|
|
|
|
hamburger.on('click', (e) => {
|
|
|
|
const hamburger = $(e.currentTarget)
|
|
|
|
hamburger.toggleClass('is-active')
|
|
|
|
|
|
|
|
if(hamburger.hasClass('is-active')){
|
|
|
|
menu.addClass('active')
|
|
|
|
//items.slideDown()
|
|
|
|
//$('html, body').css({overflow: 'hidden'})
|
|
|
|
} else {
|
|
|
|
menu.removeClass('active')
|
|
|
|
//items.slideUp()
|
|
|
|
//$('html, body').css({overflow: 'auto'})
|
|
|
|
}
|
|
|
|
})
|
|
|
|
})
|
|
|
|
|
|
|
|
})
|