When using the SideNav feature on a mobile device opening the menu using the panEventHandler function ( dragging x-axis from the left-most corner of your device ) the disableScrolling method is call which stops the body from being scrollable.
Opening the menu using the element that the SideNav is initialised with, does not disable scrolling ( which i have found to cause inconsistencies in behaviour with my device, but no longer relevant if proposed solution is implemented. ).
Expected behavior
Opening SideNav, by panEventHandler or by click event on the element the SIdeNav is initialised with should produce the same behaviour on body scroll.
Actual behavior
Element click should disable body scrolling when SideNav is opened.
Your working environment and MDB version information
Havn't been able to find the matching code in the repository, but local installation altering the following lines introduces the expected, consistent behaviour.
19665: _this3.$sidenavOverlay = $('<div id="sidenav-overlay"></div>');
19666: _this3.$body.append(_this3.$sidenavOverlay);
19667: // disable body scrolling utilising same method from panEventHandler.
19668: _this3.disableScrolling();
When using the SideNav feature on a mobile device opening the menu using the panEventHandler function ( dragging x-axis from the left-most corner of your device ) the disableScrolling method is call which stops the body from being scrollable.
Opening the menu using the element that the SideNav is initialised with, does not disable scrolling ( which i have found to cause inconsistencies in behaviour with my device, but no longer relevant if proposed solution is implemented. ).
Expected behavior
Opening SideNav, by panEventHandler or by click event on the element the SIdeNav is initialised with should produce the same behaviour on body scroll.
Actual behavior
Element click should disable body scrolling when SideNav is opened.
Your working environment and MDB version information
Can be reproduced on any of the live demo sites straight from mdb4 website. https://mdbootstrap.com/previews/docs/latest/html/skins/white-skin.html Version MDB PRO 4.5.9
Havn't been able to find the matching code in the repository, but local installation altering the following lines introduces the expected, consistent behaviour.