mirror of
https://github.com/NovaOSS/nova-betterchat.git
synced 2024-11-25 17:13:58 +01:00
hide sidemenu for mobile
This commit is contained in:
parent
d4e72532a8
commit
0302c5301d
|
@ -14,6 +14,7 @@ const Menu = () => {
|
|||
const setHideSideMenu = useStore((state) => state.setHideSideMenu);
|
||||
|
||||
useEffect(() => {
|
||||
if (window.innerWidth < 768) setHideSideMenu(true);
|
||||
window.addEventListener('resize', () => {
|
||||
if (window.innerWidth < 768) setHideSideMenu(true);
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue