mirror of
https://github.com/umami-software/umami.git
synced 2026-02-15 18:15:35 +01:00
Fixed mobile menu being hidden.
This commit is contained in:
parent
9180a7008b
commit
bf8c891c41
1 changed files with 4 additions and 2 deletions
|
|
@ -1,3 +1,4 @@
|
||||||
|
import { createPortal } from 'react-dom';
|
||||||
import classNames from 'classnames';
|
import classNames from 'classnames';
|
||||||
import { useRouter } from 'next/router';
|
import { useRouter } from 'next/router';
|
||||||
import Link from 'next/link';
|
import Link from 'next/link';
|
||||||
|
|
@ -28,10 +29,11 @@ export function MobileMenu({ items = [], onClose }) {
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
||||||
return (
|
return createPortal(
|
||||||
<div className={classNames(styles.menu)}>
|
<div className={classNames(styles.menu)}>
|
||||||
<Items items={items} />
|
<Items items={items} />
|
||||||
</div>
|
</div>,
|
||||||
|
document.body,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue