This is an automated email from the ASF dual-hosted git repository. ppawar pushed a commit to branch ATLAS-5185 in repository https://gitbox.apache.org/repos/asf/atlas.git
commit 8733e69450b2f51cc5e7660b09dd9f6ea88022e5 Author: Prasad Pawar <[email protected]> AuthorDate: Wed Jan 14 15:19:34 2026 +0530 ATLAS-5185: [REACT UI] Fix logout localStorage key mismatch and add Apache Atlas logo in header when sidebar is collapsed --- dashboard/src/styles/header.scss | 1 + dashboard/src/views/Layout/Header.tsx | 2 +- dashboard/src/views/Layout/Layout.tsx | 2 +- dashboard/src/views/SideBar/SideBarBody.tsx | 38 +++++++++++++++++++++++++++++ 4 files changed, 41 insertions(+), 2 deletions(-) diff --git a/dashboard/src/styles/header.scss b/dashboard/src/styles/header.scss index b58637c4e..3dfc8d3af 100644 --- a/dashboard/src/styles/header.scss +++ b/dashboard/src/styles/header.scss @@ -19,6 +19,7 @@ .header-logo { width: 180px; + padding-left: 12px; } .header-menu { diff --git a/dashboard/src/views/Layout/Header.tsx b/dashboard/src/views/Layout/Header.tsx index 11f919cc4..ead1780e6 100644 --- a/dashboard/src/views/Layout/Header.tsx +++ b/dashboard/src/views/Layout/Header.tsx @@ -144,7 +144,7 @@ const Header: React.FC<Header> = ({ }; const handleLogout = () => { - localStorage.setItem("atlas_ui", "v3"); + localStorage.setItem("last_ui_load", "v3"); let path = getBaseUrl(window.location.pathname); window.location.href = path + "/logout.html"; handleClose(); diff --git a/dashboard/src/views/Layout/Layout.tsx b/dashboard/src/views/Layout/Layout.tsx index 98dcc4e88..d9af526a7 100644 --- a/dashboard/src/views/Layout/Layout.tsx +++ b/dashboard/src/views/Layout/Layout.tsx @@ -89,7 +89,7 @@ const Layout: React.FC = () => { }, [getRemainingTime, isPrompted]); const handleLogout = () => { - localStorage.setItem("atlas_ui", "v3"); + localStorage.setItem("last_ui_load", "v3"); let path = getBaseUrl(window.location.pathname); window.location.href = path + "/logout.html"; handleCloseSessionModal(); diff --git a/dashboard/src/views/SideBar/SideBarBody.tsx b/dashboard/src/views/SideBar/SideBarBody.tsx index f5de41a1c..9f250ffa1 100644 --- a/dashboard/src/views/SideBar/SideBarBody.tsx +++ b/dashboard/src/views/SideBar/SideBarBody.tsx @@ -25,6 +25,7 @@ import { useRef, } from "react"; import atlasLogo from "/img/atlas_logo.svg"; +import apacheAtlasLogo from "/img/apache-atlas-logo.svg"; import { matchRoutes, Outlet, @@ -221,6 +222,43 @@ const SideBarBody = (props: { backgroundColor: "#034858", }} > + {/* Collapsed sidebar logo */} + {!open && ( + <div + style={{ + width: "100%", + textAlign: "center", + "padding-left": "12px", + display: "flex", + alignItems: "center", + justifyContent: "center", + minHeight: "64px", + cursor: "pointer", + boxSizing: "border-box", + }} + onClick={() => { + navigate( + { + pathname: "/search", + }, + { replace: true } + ); + }} + data-cy="apache-atlas-logo-collapsed" + > + <img + src={apacheAtlasLogo} + alt="Apache Atlas logo" + style={{ + width: "29px", + height: "auto", + maxWidth: "100%", + display: "block", + }} + /> + </div> + )} + {open && ( <DrawerHeader ref={headerRef}
