Skip to content

Commit

Permalink
Issue #2925 feat : Add header for the workspace - resolve comments - …
Browse files Browse the repository at this point in the history
…issue fixes
  • Loading branch information
suvarnakale committed Jan 7, 2025
1 parent b064ae8 commit e889036
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
3 changes: 0 additions & 3 deletions src/components/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import Sidebar from "./SideBar";
import { Toaster, toast } from "react-hot-toast";
import CloseIcon from "@mui/icons-material/Close";
import PersonalVideoIcon from "@mui/icons-material/PersonalVideo";
import { useRouter } from "next/router";

interface LayoutProps {
children: React.ReactNode;
Expand All @@ -14,8 +13,6 @@ interface LayoutProps {

const Layout: React.FC<LayoutProps> = ({ children, selectedKey, onSelect }) => {
const [toastShown, setToastShown] = useState(false);
const router = useRouter();
const isCreatePath = router.pathname === "/content/create";

useEffect(() => {
// Check localStorage to see if the toast has been dismissed
Expand Down
2 changes: 1 addition & 1 deletion src/components/SideBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ const Sidebar: React.FC<SidebarProps> = ({ selectedKey, onSelect }) => {
const handleNavigation = (key: string) => {
console.log(key);
router.push(`/workspace/content/${key}`);
localStorage.setItem("selectedFilters", JSON.stringify([]))
localStorage.setItem("selectedFilters", JSON.stringify([]));
onSelect(key);
if (isMobile) {
setDrawerOpen(false); // Close drawer after selecting in mobile view
Expand Down

0 comments on commit e889036

Please sign in to comment.