feat: change to center and clean code

This commit is contained in:
2025-02-16 02:09:14 +08:00
parent 73de223d56
commit 1363b87f36
97 changed files with 882 additions and 6775 deletions

View File

@@ -1,4 +1,3 @@
import { AiMoudle, useAiStore } from '@/pages/ai-chat';
import { MenuOutlined, SwapOutlined } from '@ant-design/icons';
import { Button, Tooltip } from 'antd';
import { Outlet } from 'react-router-dom';
@@ -39,11 +38,7 @@ export const LayoutMain = (props: LayoutMainProps) => {
}),
);
const { isMac, mount, isElectron } = platformStore;
const aiStore = useAiStore(
useShallow((state) => {
return { open: state.open };
}),
);
useLayoutEffect(() => {
platformStore.init();
}, []);
@@ -106,12 +101,10 @@ export const LayoutMain = (props: LayoutMainProps) => {
</div>
</Panel>
<PanelResizeHandle />
<Panel style={{ height: '100%' }} defaultSize={25} className={clsx(!aiStore.open && 'hidden')}>
<div className='w-full h-full'>
<AiMoudle />
</div>
</Panel>
{/* <PanelResizeHandle />
<Panel style={{ height: '100%' }} defaultSize={25} className={clsx('bg-gray-100')}>
侧边栏
</Panel> */}
</PanelGroup>
</div>
<LayoutUser />