괄호 안의 항을 2, 3, 4 항으로 설정하는 기능 추가
This commit is contained in:
@@ -8,6 +8,10 @@ export default function NumberParenthesesClient() {
|
||||
(state) => state.selectedProblemCount,
|
||||
);
|
||||
const setProblemCount = useGameStore((state) => state.setProblemCount);
|
||||
const selectedMaxTermCount = useGameStore(
|
||||
(state) => state.selectedMaxTermCount,
|
||||
);
|
||||
const setMaxTermCount = useGameStore((state) => state.setMaxTermCount);
|
||||
const initSession = useGameStore((state) => state.initSession);
|
||||
|
||||
return (
|
||||
@@ -16,10 +20,12 @@ export default function NumberParenthesesClient() {
|
||||
title="숫자 괄호 풀기"
|
||||
description="정수로 이루어진 괄호식을 풀며 음수 분배와 부호 변화를 연습합니다."
|
||||
notice="현재는 소괄호 숫자 문제만 선택할 수 있습니다."
|
||||
playHref={`/number-parentheses/play?count=${selectedProblemCount}`}
|
||||
playHref={`/number-parentheses/play?count=${selectedProblemCount}&terms=${selectedMaxTermCount}`}
|
||||
selectedProblemCount={selectedProblemCount}
|
||||
selectedMaxTermCount={selectedMaxTermCount}
|
||||
onProblemCountChange={setProblemCount}
|
||||
onStart={() => initSession(selectedProblemCount)}
|
||||
onMaxTermCountChange={setMaxTermCount}
|
||||
onStart={() => initSession(selectedProblemCount, selectedMaxTermCount)}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user