fix: 简化右列布局,使用flex column

This commit is contained in:
12451 2026-07-02 20:00:57 +08:00
parent 0de202d87c
commit da9296a407

View File

@ -341,8 +341,8 @@ export default function Devices() {
</div> </div>
{/* 右列:柜子列表 */} {/* 右列:柜子列表 */}
<div style={{ flex: 1, minWidth: 0, overflow: 'hidden' }}> <div style={{ flex: 1, minWidth: 0, display: 'flex', flexDirection: 'column', overflow: 'hidden' }}>
<div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between', marginBottom: 16 }}> <div style={{ display: 'flex', alignItems: 'center', justifyContent: 'space-between', marginBottom: 16, flexShrink: 0 }}>
<Typography.Title heading={5} style={{ margin: 0 }}> <Typography.Title heading={5} style={{ margin: 0 }}>
({cabinets.length}) ({cabinets.length})
</Typography.Title> </Typography.Title>
@ -350,7 +350,7 @@ export default function Devices() {
</Button> </Button>
</div> </div>
<div style={{ overflow: 'auto', height: 'calc(100% - 50px)' }}> <div style={{ flex: 1, overflow: 'auto' }}>
<CabinetGrid cabinets={cabinets} loading={loading} /> <CabinetGrid cabinets={cabinets} loading={loading} />
</div> </div>
</div> </div>