mirror of
https://github.com/vercel/commerce.git
synced 2025-06-20 06:01:21 +00:00
Fixed category normalizer in shopify
This commit is contained in:
parent
9f6dd278d7
commit
c4d30113d9
@ -27,13 +27,11 @@ const Navbar: FC<NavbarProps> = ({ links }) => (
|
|||||||
<Link href="/search">
|
<Link href="/search">
|
||||||
<a className={s.link}>All</a>
|
<a className={s.link}>All</a>
|
||||||
</Link>
|
</Link>
|
||||||
{links
|
{links?.map((l) => (
|
||||||
? links.map((l) => (
|
<Link href={l.href} key={l.href}>
|
||||||
<Link href={l.href}>
|
|
||||||
<a className={s.link}>{l.label}</a>
|
<a className={s.link}>{l.label}</a>
|
||||||
</Link>
|
</Link>
|
||||||
))
|
))}
|
||||||
: null}
|
|
||||||
</nav>
|
</nav>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -185,8 +185,7 @@ export const normalizePages = (edges: PageEdge[], locale: string): Page[] =>
|
|||||||
|
|
||||||
export const normalizeCategory = (category: any): Category => ({
|
export const normalizeCategory = (category: any): Category => ({
|
||||||
id: category.id,
|
id: category.id,
|
||||||
name: category.name,
|
name: category.title,
|
||||||
slug: category.handle,
|
slug: category.handle,
|
||||||
path: `/${category.handle}`,
|
path: `/${category.handle}`,
|
||||||
})
|
})
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user