correct typo, add script for toggle menu, remove forgotten console log

This commit is contained in:
Lukas Juhas 2017-06-06 15:46:03 +01:00
parent a5988e146a
commit cd05907c04
2 changed files with 12 additions and 2 deletions

View File

@ -73,7 +73,7 @@ This will execute all the Gulp tasks on the gulpfile.babel.js.
### Images
Drop all your images into assets/imagess. When running gulp tasks, they will be automatically
Drop all your images into assets/images. When running gulp tasks, they will be automatically
optimised and output files will available in img folder in the root of the theme.
## WordPress Support

View File

@ -1,3 +1,13 @@
import $ from 'jquery';
console.log($);
/**
* Mobile navigation toggle
* @param {mixed} event
*/
const toggleMenu = (event) => {
event.preventDefault();
$('.js-menu-toggle, .nav--header').toggleClass('open');
$('.header').toggleClass('menu-open');
};
$('.js-menu-toggle').on('click', toggleMenu);