diff --git a/.gitignore b/.gitignore index 23771aa..7fdac4a 100644 --- a/.gitignore +++ b/.gitignore @@ -23,4 +23,5 @@ dist-ssr *.sln *.sw? -houhou.db \ No newline at end of file +houhou.db +src/data/kanadata.json \ No newline at end of file diff --git a/src/panes/SrsReviewPane.tsx b/src/panes/SrsReviewPane.tsx index 43e3fe3..e012be2 100644 --- a/src/panes/SrsReviewPane.tsx +++ b/src/panes/SrsReviewPane.tsx @@ -83,6 +83,9 @@ export function Component() { // Check the answer if (!possibleAnswers.has(currentAnswer)) { setIsIncorrect(true); + + const lastItem = reviewQueue[reviewQueue.length - 1]; + if (!_.isEqual(lastItem, nextItem)) setReviewQueue([...reviewQueue, nextItem]); return; } @@ -90,7 +93,7 @@ export function Component() { setAnyProgress(true); setIsIncorrect(false); setCurrentAnswer(""); - const [_, ...rest] = reviewQueue; + const [_currentItem, ...rest] = reviewQueue; setReviewQueue(rest); };