mirror of
https://github.com/vercel/commerce.git
synced 2025-05-07 10:17:50 +00:00
remove menusidebarview
This commit is contained in:
parent
9a8d4ab1cc
commit
346ad099af
@ -1,38 +1,38 @@
|
||||
import Link from 'next/link'
|
||||
import s from './MenuSidebarView.module.css'
|
||||
import { useUI } from '@components/ui/context'
|
||||
import SidebarLayout from '@components/common/SidebarLayout'
|
||||
import type { Link as LinkProps } from './index'
|
||||
// import Link from 'next/link'
|
||||
// import s from './MenuSidebarView.module.css'
|
||||
// import { useUI } from '@components/ui/context'
|
||||
// import SidebarLayout from '@components/common/SidebarLayout'
|
||||
// import type { Link as LinkProps } from './index'
|
||||
|
||||
export default function MenuSidebarView({
|
||||
links = [],
|
||||
}: {
|
||||
links?: LinkProps[]
|
||||
}) {
|
||||
const { closeSidebar } = useUI()
|
||||
// export default function MenuSidebarView({
|
||||
// links = [],
|
||||
// }: {
|
||||
// links?: LinkProps[]
|
||||
// }) {
|
||||
// const { closeSidebar } = useUI()
|
||||
|
||||
return (
|
||||
<SidebarLayout handleClose={() => closeSidebar()}>
|
||||
<div className={s.root}>
|
||||
<nav>
|
||||
<ul>
|
||||
<li className={s.item} onClick={() => closeSidebar()}>
|
||||
<Link href="/search">All</Link>
|
||||
</li>
|
||||
{links.map((l: any) => (
|
||||
<li
|
||||
key={l.href}
|
||||
className={s.item}
|
||||
onClick={() => closeSidebar()}
|
||||
>
|
||||
<Link href={l.href}>{l.label}</Link>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</nav>
|
||||
</div>
|
||||
</SidebarLayout>
|
||||
)
|
||||
}
|
||||
// return (
|
||||
// <SidebarLayout handleClose={() => closeSidebar()}>
|
||||
// <div className={s.root}>
|
||||
// <nav>
|
||||
// <ul>
|
||||
// <li className={s.item} onClick={() => closeSidebar()}>
|
||||
// <Link href="/search">All</Link>
|
||||
// </li>
|
||||
// {links.map((l: any) => (
|
||||
// <li
|
||||
// key={l.href}
|
||||
// className={s.item}
|
||||
// onClick={() => closeSidebar()}
|
||||
// >
|
||||
// <Link href={l.href}>{l.label}</Link>
|
||||
// </li>
|
||||
// ))}
|
||||
// </ul>
|
||||
// </nav>
|
||||
// </div>
|
||||
// </SidebarLayout>
|
||||
// )
|
||||
// }
|
||||
|
||||
MenuSidebarView
|
||||
// MenuSidebarView
|
||||
|
@ -1,4 +1,4 @@
|
||||
export { default } from './MenuSidebarView'
|
||||
// export { default } from './MenuSidebarView'
|
||||
export interface Link {
|
||||
href: string
|
||||
label: string
|
||||
|
@ -1,3 +1,3 @@
|
||||
// export { default } from './UserNav'
|
||||
export { default as MenuSidebarView } from './MenuSidebarView'
|
||||
// export { default as MenuSidebarView } from './MenuSidebarView'
|
||||
// export { default as CustomerMenuContent } from './CustomerMenuContent'
|
||||
|
Loading…
x
Reference in New Issue
Block a user