mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-22 00:13:12 +09:00
Replace deprecated usage of Breadcrumb.Item
This commit is contained in:
1 parent
a67a4a41da
commit
e530bbc83a
1 file changed
+9
-5
@@ -13,11 +13,15 @@ type PageLayoutProps = {
|
|||||||
};
|
};
|
||||||
export default function PageLayout(props: PageLayoutProps) {
|
export default function PageLayout(props: PageLayoutProps) {
|
||||||
return <>
|
return <>
|
||||||
<Breadcrumb className="site-breadcrumb">
|
<Breadcrumb
|
||||||
{props.nav.map((part, index) => <Breadcrumb.Item key={index}>
|
className="site-breadcrumb"
|
||||||
{part.path ? <Link to={part.path}>{part.name}</Link> : part.name}
|
itemRender={(route, params, routes, paths) => (
|
||||||
</Breadcrumb.Item>)}
|
route.href ? <Link to={route.href}>{route.title}</Link> : route.title
|
||||||
</Breadcrumb>
|
)}
|
||||||
|
items={props.nav.map(
|
||||||
|
(part, index) => ({ href: part.path, title: part.name }))
|
||||||
|
}
|
||||||
|
/>
|
||||||
<Content className="site-layout-content" >
|
<Content className="site-layout-content" >
|
||||||
{props.children}
|
{props.children}
|
||||||
</Content>
|
</Content>
|
||||||
|
|||||||
Reference in new issue
Block a user