Fix centered content layout widths

This commit is contained in:
ash66
2026-05-26 12:34:12 +08:00
parent 34d72d7ce9
commit fec22a3a2c
16 changed files with 2102 additions and 140 deletions

View File

@@ -1,4 +1,4 @@
import { Outlet, useLocation } from 'react-router-dom';
import { useLocation } from 'react-router-dom';
import { FooterLayout } from './FooterLayout';
import { HeaderLayout } from './HeaderLayout';
@@ -15,7 +15,6 @@ export function AppShell() {
<HeaderLayout activeTab={activeTab} />
<ContentLayout tab={activeTab}>
<KeepAliveViewport activeTab={activeTab} />
<Outlet />
</ContentLayout>
<FooterLayout />
</div>

View File

@@ -22,12 +22,12 @@ export function ContentLayout({ children, tab }: ContentLayoutProps) {
<div
className={[
shellFrameClassName,
'relative flex min-h-0 flex-1 py-8',
'relative flex min-h-0 flex-1 justify-center py-8',
].join(' ')}
>
<div
className={[
'relative flex w-full min-h-0 flex-1',
'relative flex min-h-0 w-full',
widthClass,
tab.fillHeight ? 'overflow-hidden' : '',
].join(' ')}

View File

@@ -44,7 +44,7 @@ export const appTabs: AppTabConfig[] = [
label: '合规分析',
component: CompliancePage,
keepAlive: true,
contentWidth: 'full',
contentWidth: 'wide',
fillHeight: true,
},
{
@@ -61,7 +61,7 @@ export const appTabs: AppTabConfig[] = [
label: '法规对话',
component: RagChatPage,
keepAlive: true,
contentWidth: 'full',
contentWidth: 'wide',
fillHeight: true,
},
];