A spell management application for the SAGA tabletop role-playing game system. This web-based tool helps players and game masters manage spells, create spellbooks for characters, and export spell information for reference during gameplay.
- Comprehensive Spell Browser: Browse, search, and filter the complete SAGA spell database
- Custom Spellbooks: Create and manage spellbooks for your characters
- Advanced Filtering: Filter spells by class, school, complexity, and keywords
- PDF Export: Export spell lists and spellbooks to PDF for easy printing and reference
- Dark/Light Mode: Toggle between light and dark themes for comfortable viewing
- Offline Support: Access your spells and spellbooks even without an internet connection
- Progressive Web App: Install on your device for quick access and offline functionality
- Optimized Performance: Fast loading times with code splitting and lazy loading
-
Clone the repository:
git clone https://github.com/yourusername/saga-spells.git cd saga-spells
-
Install dependencies:
pnpm install
-
Start the development server:
pnpm dev
-
Open your browser and navigate to http://localhost:5173
To create an optimized production build:
pnpm build:prod
This project uses GitHub Actions for continuous integration and deployment:
- Runs type checking, testing, and building in parallel jobs
- Uses dependency caching for faster workflow execution
- Uploads test coverage and build artifacts
- Optimized for PNPM and modern Node.js
- Runs Lighthouse performance tests automatically
- Generates detailed reports with performance metrics
- Adds report summaries as PR comments
- Enforces performance, accessibility, and PWA standards
- Automatically scans dependencies for vulnerabilities
- Creates GitHub issues for critical security problems
- Runs on schedule and when dependencies change
We've set up automated deployment to two platforms:
- GitHub Pages: Zero-configuration deployment with GitHub's hosting
- Cloudflare Pages: High-performance global CDN deployment
See CI_CD.md for detailed information about our CI/CD setup.
To run these workflows locally before pushing:
# Run tests
pnpm test
# Build the app
pnpm build
# Run Lighthouse tests
pnpm lighthouse
For more details on the CI/CD setup, see CI_CD.md. For deployment instructions, see DEPLOYMENT.md.
This will:
- Clean the previous build
- Type check all TypeScript code
- Bundle and optimize all assets
- Apply code splitting and lazy loading
- Compress assets (Gzip and Brotli)
- Optimize images
- Generate bundle analysis (available at dist/stats.html)
To preview the production build locally:
pnpm preview
The main page displays all available spells. Use the filter panel to narrow down spells by:
- Spell class
- School of magic
- Complexity level
- Keywords
- Text search
- Navigate to the Spellbooks page
- Click "New Spellbook"
- Enter a name, character name, and optional description
- Add spells to your spellbook from the main spells page
- Export individual spells or entire spellbooks to PDF
- Customize the export format with different layout options
All spellbooks are stored in your browser's local storage. To prevent data loss:
- Use the export feature regularly to back up your spellbooks
- Do not clear your browser data without exporting first
Contributions are welcome! See DEVELOPMENT.md for details on setting up the development environment and contributing guidelines.
For information on deploying this application to production, see DEPLOYMENT.md.
This project is licensed under the ISC License - see the LICENSE file for details.
- Built with React, Vite, and Mantine UI
- PDF generation powered by jsPDF and jsPDF-AutoTable
- Inspired by the SAGA TTRPG system