A modern, accessible Sudoku application built with React, TypeScript, Radix UI, and Tailwind CSS.
- 5 Difficulty Levels: Easy, Medium, Hard, Difficult, Extreme
- Note-Taking System: Pencil mode for taking notes
- Time Tracking: Game timer with pause/resume functionality
- Hint System: Intelligent hints with 3-hint limit
- Attempt Management: Track failed attempts with configurable limits
- Undo/Redo: Full action history and undo functionality
- Mobile-First Design: Responsive design optimized for mobile devices
- Accessibility: WCAG 2.1 AA compliant with screen reader support
- PWA Ready: Offline functionality and app-like experience
- Framework: React 18 + TypeScript
- UI Components: Radix UI (accessible, unstyled components)
- Styling: Tailwind CSS (utility-first CSS framework)
- State Management: Zustand (lightweight state management)
- Build Tool: Vite (fast development and building)
- Code Quality: ESLint + Prettier + TypeScript
- Node.js 18+ (recommended: Node.js 20+)
- npm or yarn package manager
-
Clone the repository
git clone <repository-url> cd sudoku-frontend
-
Install dependencies
npm install
-
Start development server
npm run dev
-
Open your browser Navigate to
http://localhost:5173
npm run dev- Start development servernpm run build- Build for productionnpm run preview- Preview production buildnpm run lint- Run ESLintnpm run lint:fix- Fix ESLint issuesnpm run format- Format code with Prettiernpm run type-check- Run TypeScript type checking
src/
├── components/ # React components
│ ├── ui/ # Reusable UI components
│ ├── game/ # Game-specific components
│ └── layout/ # Layout components
├── hooks/ # Custom React hooks
├── stores/ # Zustand state stores
├── services/ # API and external services
├── types/ # TypeScript type definitions
├── utils/ # Utility functions
└── styles/ # Global styles and CSS
- Use TypeScript for all new code
- Follow ESLint and Prettier configurations
- Use functional components with hooks
- Implement proper error boundaries
- Write meaningful component and function names
- One component per file
- Use descriptive file names
- Export components as default exports
- Implement proper prop interfaces
- Use TypeScript for all props
- Use Zustand for global state
- Keep component state local when possible
- Implement proper state persistence
- Use TypeScript for state interfaces
- Use Radix UI components for accessibility
- Implement proper ARIA labels
- Ensure keyboard navigation works
- Test with screen readers
- Follow WCAG 2.1 AA guidelines
- Primary: Blue scale for main actions and highlights
- Success: Green for correct moves and completion
- Error: Red for incorrect moves and errors
- Warning: Yellow for hints and warnings
- Neutral: Gray scale for text and backgrounds
- Numbers: Large, bold text for Sudoku numbers
- Notes: Smaller text for pencil notes
- Labels: Medium weight for UI labels
- Body: Standard weight for general text
- Cell Size: 44px (touch-friendly minimum)
- Grid Lines: 2px for thin lines
- Borders: 3px for 3x3 box borders
- Padding: Consistent 4px increments
- Test individual components
- Test utility functions
- Test state management
- Use React Testing Library
- Test component interactions
- Test user workflows
- Test state persistence
- Test accessibility features
- Monitor bundle size
- Test rendering performance
- Test memory usage
- Use React DevTools Profiler
-
Run tests
npm run test -
Build for production
npm run build
-
Preview build
npm run preview
VITE_API_URL- Backend API URLVITE_APP_NAME- Application nameVITE_APP_VERSION- Application version
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests for new functionality
- Ensure all tests pass
- Submit a pull request
This project is licensed under the MIT License.
For support and questions:
- Create an issue in the repository
- Check the documentation
- Review the code examples
- ✅ Core game mechanics
- ✅ Basic UI components
- ✅ State management
- ✅ Note-taking system
- 🔄 Advanced hint system
- 🔄 Performance optimization
- 🔄 Accessibility improvements
- 🔄 Testing implementation
- 📋 Backend integration
- 📋 Cloud sync features
- 📋 Social features
- 📋 Advanced analytics