A beautiful, fully-functional web-based Solitaire game with modern UI and comprehensive testing suite.
- Classic Solitaire Gameplay - All standard Klondike Solitaire rules
- Beautiful Modern UI - Glassmorphism design with smooth animations
- Drag & Drop - Intuitive card movement
- Double-Click Auto-Move - Quick card placement to foundations
- Auto-Move Button - Automatically move available cards to foundations
- Score Tracking - Keep track of your score and moves
- Explosion Effects - Fun visual feedback for invalid moves
- Win Detection - Celebration when you complete the game
- Open
solitaire.htmlin any modern web browser - Drag cards to move them between piles
- Double-click cards to automatically move them to foundations
- Click "Draw Card" to get cards from the stock pile
- Click "Auto Move" to automatically place available cards
- Click "New Game" to start fresh
- Build tableau columns in descending order (King to Ace)
- Alternate red and black cards in tableau
- Build foundations in ascending order (Ace to King) by suit
- Only Kings can be placed in empty tableau columns
- Only Aces can start foundation piles
An automated testing system is included to validate game logic and catch bugs.
- Open
solitaire-test.htmlin your browser - Choose a test mode:
- Run Single Test - Test one game
- Run 10 Tests - Quick validation
- Run 100 Tests - Comprehensive testing
- Stress Test - 1000 games for thorough validation
- ✅ Deck integrity (52 unique cards)
- ✅ Proper card dealing
- ✅ Move validation
- ✅ Card state management
- ✅ Auto-flip mechanics
- ✅ Waste pile operations
- ✅ Duplicate prevention
- ✅ Card count consistency
solitaire.html- Main game filesolitaire-test.html- Automated testing suiteBUG_FIXES.md- Documentation of bug fixes and improvementsREADME.md- This file
- Pure HTML/CSS/JavaScript - No dependencies required
- No build process - Just open and play
- Responsive design - Works on different screen sizes
- Modern browser features - Drag & Drop API, CSS animations
See BUG_FIXES.md for detailed information about bugs that were fixed and the testing improvements made.
- Fixed duplicate cards appearing in waste pile
- Fixed cards not flipping after auto-move
- Enhanced testing suite with 10 comprehensive tests
- Added waste pile support to auto-move
- Improved visual feedback and UI polish
Potential features to add:
- Timer and statistics
- Undo/Redo functionality
- Hint system
- Different difficulty levels
- Sound effects
- Dark/light theme toggle
- Mobile touch optimization
Free to use and modify for personal and educational purposes.
Feel free to fork, modify, and submit pull requests for improvements!
Enjoy the game! 🎉