diff --git a/src/client/pages/Layout.tsx b/src/client/pages/Layout.tsx index 53155b1..09db1a0 100644 --- a/src/client/pages/Layout.tsx +++ b/src/client/pages/Layout.tsx @@ -1,11 +1,12 @@ import React from 'react'; -import { Outlet } from 'react-router-dom'; +import { Outlet, useSearchParams } from 'react-router-dom'; import { NavItem } from '../components/NavItem'; import { UserOutlined } from '@ant-design/icons'; import { Button, Dropdown } from 'antd'; import { useUserStore } from '../store/user'; export const Layout: React.FC = React.memo(() => { + const [params] = useSearchParams(); const workspaces = useUserStore((state) => { const userInfo = state.info; if (userInfo) { @@ -19,46 +20,49 @@ export const Layout: React.FC = React.memo(() => { return []; }); + const showHeader = !params.has('hideHeader'); return (