From c14bdafcb6c816424b0b396a919b609986570f2f Mon Sep 17 00:00:00 2001 From: Arif-tekdi-technologies Date: Tue, 15 Oct 2024 15:46:31 +0530 Subject: [PATCH] Back button update --- src/components/SideBar.tsx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/components/SideBar.tsx b/src/components/SideBar.tsx index f64bf20..03b2316 100644 --- a/src/components/SideBar.tsx +++ b/src/components/SideBar.tsx @@ -17,7 +17,6 @@ import DatabaseIcon from "@mui/icons-material/Storage"; import CloseIcon from "@mui/icons-material/Close"; import ArrowBackIcon from "@mui/icons-material/ArrowBack"; - const menuItems = [ { text: "Create", key: "create" }, { text: "All My Contents", key: "allContents" }, @@ -51,10 +50,9 @@ const Sidebar: React.FC = ({ selectedKey, onSelect }) => { }; const goBack = () => { - window.history.back(); + router.push("/"); }; - const drawerContent = ( = ({ selectedKey, onSelect }) => { > - +