From 10493327e1c8c1000c59a02ec8e4a5969ab4f62e Mon Sep 17 00:00:00 2001 From: Max Schmidt Date: Sun, 17 Nov 2024 11:21:24 +0100 Subject: [PATCH 1/2] close mobile nav after clicking on link Signed-off-by: Max Schmidt --- src/components/MobileMenu.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/MobileMenu.tsx b/src/components/MobileMenu.tsx index 12033f06..07389664 100644 --- a/src/components/MobileMenu.tsx +++ b/src/components/MobileMenu.tsx @@ -1,8 +1,8 @@ 'use client'; -import { createPortal } from 'react-dom'; +import { Button, Icon, Icons } from '@umami/react-zen'; import classNames from 'classnames'; import Link from 'next/link'; -import { Button, Icon, Icons } from '@umami/react-zen'; +import { createPortal } from 'react-dom'; import styles from './MobileMenu.module.css'; interface Props { @@ -23,7 +23,7 @@ export default function MobileMenu({ items = [], onClose }: Props) {
{items.map(({ label, value }) => ( - + {label} ))} From bb313990464491e02253c657c7eedb71f24ba615 Mon Sep 17 00:00:00 2001 From: Max Schmidt Date: Sun, 17 Nov 2024 11:29:20 +0100 Subject: [PATCH 2/2] order dependencies Signed-off-by: Max Schmidt --- src/components/MobileMenu.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/MobileMenu.tsx b/src/components/MobileMenu.tsx index 07389664..80744a5d 100644 --- a/src/components/MobileMenu.tsx +++ b/src/components/MobileMenu.tsx @@ -1,8 +1,8 @@ 'use client'; -import { Button, Icon, Icons } from '@umami/react-zen'; +import { createPortal } from 'react-dom'; import classNames from 'classnames'; import Link from 'next/link'; -import { createPortal } from 'react-dom'; +import { Button, Icon, Icons } from '@umami/react-zen'; import styles from './MobileMenu.module.css'; interface Props {