+ 1

Animated off canvas push menu

Im working on an agency website, everythings fine but what i want is an off canvas menu which closes on mouse click or touch on any where on body(obviously a close button always works) there are so many plugins available but i want to hand code, a little help would be appreciated.

9th Feb 2017, 4:43 PM
Asad Shaikh
Asad Shaikh - avatar
1 Antwort
+ 1
The document.body onclick event is maybe what you want: html: <body onclick="/* js code */"> js: document.body.onclick = function() { /* js code */ }; or: document.body.addEventListener('click', function() { /* js code */ });
9th Feb 2017, 8:06 PM
visph
visph - avatar