diff --git a/awx/ui_next/src/components/Breadcrumbs/Breadcrumbs.jsx b/awx/ui_next/src/components/Breadcrumbs/Breadcrumbs.jsx index 915118cba8..fade4ce046 100644 --- a/awx/ui_next/src/components/Breadcrumbs/Breadcrumbs.jsx +++ b/awx/ui_next/src/components/Breadcrumbs/Breadcrumbs.jsx @@ -7,7 +7,8 @@ import { BreadcrumbItem, BreadcrumbHeading, } from '@patternfly/react-core'; -import { Link, Route, withRouter } from 'react-router-dom'; +import { Link, Route, withRouter, useRouteMatch } from 'react-router-dom'; + import styled from 'styled-components'; const PageSection = styled(PFPageSection)` @@ -15,18 +16,15 @@ const PageSection = styled(PFPageSection)` padding-bottom: 10px; `; -const Breadcrumbs = ({ breadcrumbConfig }) => { +const Breadcrumbs = ({ breadcrumbConfig, match }) => { const { light } = PageSectionVariants; return ( - ( - - )} - /> + + + ); @@ -51,15 +49,17 @@ const Crumb = ({ breadcrumbConfig, match }) => { crumbElement = null; } + function NextCrumb() { + const routeMatch = useRouteMatch(); + return ; + } + return ( {crumbElement} - ( - - )} - /> + + + ); };