diff --git a/react/src/components/MainLayout/MainLayout.tsx b/react/src/components/MainLayout/MainLayout.tsx
index c161e72b25..a753470614 100644
--- a/react/src/components/MainLayout/MainLayout.tsx
+++ b/react/src/components/MainLayout/MainLayout.tsx
@@ -9,6 +9,7 @@ import ForceTOTPChecker from '../ForceTOTPChecker';
import NetworkStatusBanner from '../NetworkStatusBanner';
import PasswordChangeRequestAlert from '../PasswordChangeRequestAlert';
import { DRAWER_WIDTH } from '../WEBUINotificationDrawer';
+import WebUIBreadcrumb from '../WebUIBreadcrumb';
import WebUIHeader from './WebUIHeader';
import WebUISider from './WebUISider';
import { App, Layout, theme } from 'antd';
@@ -217,6 +218,13 @@ function MainLayout() {
+
{/* To match paddig to 16 (2+14) */}
diff --git a/react/src/components/WebUIBreadcrumb.tsx b/react/src/components/WebUIBreadcrumb.tsx
new file mode 100644
index 0000000000..d85989e6a4
--- /dev/null
+++ b/react/src/components/WebUIBreadcrumb.tsx
@@ -0,0 +1,99 @@
+import { WebUIRouteObject } from '../App';
+import Flex, { FlexProps } from './Flex';
+import WebUILink from './WebUILink';
+import { Breadcrumb, theme } from 'antd';
+import _ from 'lodash';
+import React from 'react';
+import { useTranslation } from 'react-i18next';
+import { Link, useLocation, useMatches } from 'react-router-dom';
+
+interface WebUIBreadcrumbProps extends FlexProps {}
+const WebUIBreadcrumb: React.FC = (props) => {
+ // const location = useLocation();
+ const matches = useMatches();
+ // matches[0].handle.
+
+ const { token } = theme.useToken();
+
+ const { t } = useTranslation();
+ return (
+
+ {
+ return (
+ // @ts-ignore
+ !_.isEmpty(match?.handle?.labelKey) ||
+ // @ts-ignore
+ !_.isEmpty(match?.handle?.title)
+ );
+ })
+ .map((match, index) => {
+ return {
+ key: match.id,
+ href:
+ _.last(matches) === match
+ ? undefined
+ : // @ts-ignore
+ match?.handle?.altPath || match.pathname,
+ //@ts-ignore
+ title: match?.handle?.title || t(match?.handle?.labelKey),
+ // onClick:
+ // _.last(matches) === match
+ // ? undefined
+ // : (e: any) => {
+ // e.preventDefault();
+ // // @ts-ignore
+ // navigate(match?.handle?.altPath || match.pathname);
+ // },
+ };
+ })
+ .value(),
+ {
+ // Add dummy tail to add a `/` at the end of the breadcrumb
+ key: 'dummy_tail',
+ title: ' ',
+ },
+ ]}
+ itemRender={(currentRoute, params, items, paths) => {
+ const isLast =
+ currentRoute?.key === items[items.length - 2]?.key ||
+ currentRoute?.key === 'dummy_tail';
+ return isLast || !currentRoute.href ? (
+ {currentRoute.title}
+ ) : (
+
+ {currentRoute.title}
+
+ );
+ }}
+ />
+
+ );
+};
+
+export default WebUIBreadcrumb;