Implement learning journey progression system (SP-007)#2
Open
fikriauliya wants to merge 17 commits into
Open
Conversation
Replace GameController with LearningJourney component featuring: - 36 hierarchical levels (operations × difficulties × complements) - Progressive unlock system with visual progress indicators - Local storage persistence for user progress tracking - Medium-sized icons and responsive sidebar design - Seamless integration with existing game mechanics 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Added clarification to use Playwright for capturing screenshots - Ensures consistent screenshot methodology for PR documentation 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Replace GameController with LearningJourney component - Implement 36 structured levels (operations × difficulties × complements) - Add progressive unlocking system requiring 5 questions per level - Include visual progress indicators and completion tracking - Integrate localStorage for session persistence - Update SP-007 story spec with implementation status - Add Playwright screenshot test for UI documentation 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Modified GameContext to support onAnswerChecked callback - Updated checkAnswer to clear currentQuestion for both correct and incorrect answers - Added callback trigger after 2-second feedback display - Integrated LearningJourney component to set up auto-progression - Now automatically generates next question regardless of answer correctness 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Updated learning-journey-screenshot.spec.ts to import TEST_CONFIG - Changed hardcoded localhost:5178 to use TEST_CONFIG.BASE_URL - Now properly reads port from VITE_PORT environment variable - Falls back to port 5173 if env not set 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Auto-reset sempoa board to 0 after each answer submission - Remove delay before showing next question (instant progression) - Add Enter key support for submitting answers - Keep feedback visible for 2 seconds while new question loads - Add tests to verify auto-progression and keyboard functionality 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Remove "Correct\! Well done\!" and error text feedback - Add CSS animations for correct answers (green pulse, shake) - Add CSS animations for wrong answers (red shake, flash) - Progress section pulses green on correct, shakes red on wrong - Progress bars change color and animate based on answer result - Score display changes color temporarily to match result - Update tests to verify no feedback text and animation behavior 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Replace boolean lastAnswerCorrect with timestamped lastAnswerResult - Ensures animations trigger on every answer submission regardless of result - Fixes issue where consecutive correct/wrong answers wouldn't animate - Add comprehensive tests for consecutive submissions and rapid Enter key usage - Maintains proper question progression and score/mistake tracking 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Add questionsCompleted field to LearningLevel type - Track progress per level instead of using global score modulo - Levels now unlock only when previous level is completed (5 correct answers) - Add backward compatibility for existing localStorage data - Remove unused feedback parameter from SempoaBoard - Add comprehensive tests for level progression and unlocking - Ensures proper learning journey flow with sequential unlocking 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Remove console.log statements that could cause production issues - Add comprehensive input validation to selectLevel function - Add silent error handling to prevent crashes during question generation - Strengthen onClick handler with proper event prevention - Add multiple test cases to reproduce and verify Big Friend level behavior Tests show the level is properly disabled and should not crash, but defensive programming added as extra protection. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Mark SP-006 and SP-007 as completed in TODOS.md - Merge PR command specifications from main branch - Maintain consistency between branches 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Key Features Implemented
Technical Changes
src/components/LearningJourney.tsx(261 lines)LearningLevelandLearningJourneyStateinterfacesApp.tsxto use LearningJourney instead of GameControllerScreenshots
!Learning Journey UI
The new learning journey interface provides:
Test Plan
🤖 Generated with Claude Code