diff --git a/src/components/layout/Layout.tsx b/src/components/layout/Layout.tsx
index 0dc9c36..0725ca5 100644
--- a/src/components/layout/Layout.tsx
+++ b/src/components/layout/Layout.tsx
@@ -14,19 +14,19 @@ export function Layout({ children }: LayoutProps) {
return (
-
+
{/* 侧边栏 */}
{/* 主内容区 */}
-
+
{/* 顶部导航 */}
{/* 页面内容 */}
diff --git a/src/pages/ProcessPracticePage.tsx b/src/pages/ProcessPracticePage.tsx
index d7c8107..fd37fd2 100644
--- a/src/pages/ProcessPracticePage.tsx
+++ b/src/pages/ProcessPracticePage.tsx
@@ -9,14 +9,10 @@ import {
import { PracticeMatrix } from '@/components/practice/PracticeMatrix'
import { InputArea } from '@/components/practice/InputArea'
import { HintInfo } from '@/components/practice/HintInfo'
-import { useAppStore } from '@/stores/useAppStore'
-import { clsx } from 'clsx'
type CharStatus = 'pending' | 'correct' | 'error'
export default function ProcessPracticePage() {
- const sidebarOpen = useAppStore((s) => s.sidebarOpen)
-
// 生成格子顺序
const [cellSequence] = useState(() => generateCellSequence())
@@ -64,8 +60,6 @@ export default function ProcessPracticePage() {
} | null>(null)
const [inputLocked, setInputLocked] = useState(false)
const latestInputRef = useRef([])
- const bottomAreaRef = useRef(null)
- const [bottomHeight, setBottomHeight] = useState(0)
// 初始化输入框
useEffect(() => {
@@ -96,19 +90,6 @@ export default function ProcessPracticePage() {
}
}, [answeredCells, currentCellId])
- // 动态计算底部固定区域高度
- useEffect(() => {
- const updateBottomHeight = () => {
- if (bottomAreaRef.current) {
- setBottomHeight(bottomAreaRef.current.offsetHeight)
- }
- }
-
- updateBottomHeight()
- window.addEventListener('resize', updateBottomHeight)
- return () => window.removeEventListener('resize', updateBottomHeight)
- }, [userInput.length]) // 当输入框数量变化时重新计算
-
// 切换到指定格子
const switchToCell = useCallback(
(cell: CellInfo) => {
@@ -371,7 +352,7 @@ export default function ProcessPracticePage() {
}, [cellSequence])
return (
-
+
{/* 顶部进度条 */}
@@ -405,7 +386,7 @@ export default function ProcessPracticePage() {
{/* 主内容区域 */}
-
+
{/* 矩阵区域 */}
- {/* 底部固定区域 */}
-
-
+ {/* 底部固定区域(粘附底部,参与文档流) */}
+