Skip to content

Commit 9c9e575

Browse files
committed
fix: 修复 Flexbox 嵌套高度丢失 问题
1 parent 1775c81 commit 9c9e575

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

src/App.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ function App() {
5959

6060
<SerialSettings />
6161

62-
<div style={{ flex: 1, position: "relative", display: "flex", flexDirection: "column" }}>
62+
<div style={{ flex: 1, height: "100%", position: "relative", display: "flex", flexDirection: "column" }}>
6363

6464
{activeView === 'basic' && <BasicView />}
6565

src/views/BasicView.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ export default function BasicView() {
120120
};
121121

122122
return (
123-
<div style={{ flex: 1, display: "flex", flexDirection: "column", padding: "20px", gap: "15px", position: "relative", boxSizing: "border-box" }}>
123+
<div style={{ flex: 1, height: "100%", display: "flex", flexDirection: "column", padding: "20px", gap: "15px", position: "relative", boxSizing: "border-box" }}>
124124
{/* 日志控制工具栏 */}
125125
<div style={{ display: "flex", justifyContent: "space-between", alignItems: "center", backgroundColor: "#fff", padding: "8px 15px", borderRadius: "8px", border: "1px solid #e8e8e8", boxShadow: "0 1px 4px rgba(0,0,0,0.02)" }}>
126126
<div style={{ display: "flex", alignItems: "center", gap: "10px" }}>

0 commit comments

Comments
 (0)