Add Material Design style

This commit is contained in:
Miguel Astor
2026-03-08 12:36:14 -04:00
parent c0c25e2719
commit 1472c14d44
4 changed files with 636 additions and 6 deletions

View File

@@ -18,6 +18,7 @@ Generate report with modern style:
python generate_report.py --style glassmorphism --output report.html
python generate_report.py --style brutalism --output report.html
python generate_report.py --style neumorphism --output report.html
python generate_report.py --style material --output report.html
```
Generate report with legacy Platinum template:
@@ -38,19 +39,19 @@ python generate_report.py --db pga.db --output report.html --top 10 --background
- Loads HTML template from `templates/` folder (default: `templates/platinum.html`)
**HTML templates (`templates/`):**
- **modern.html**: Unified template for modern styles (brutalism, glassmorphism, neumorphism)
- **modern.html**: Unified template for modern styles (brutalism, glassmorphism, neumorphism, material)
- **platinum.html**: Legacy Mac OS 9 Platinum visual style (separate template due to unique structure)
- All templates use Chart.js doughnut charts and dynamic JavaScript filtering
- Placeholder tokens like `__ALL_GAMES__`, `__BACKGROUND_IMAGE__` are replaced at generation time
- Modern templates support light/dark/auto theme toggle button
**Style system (`styles.py`):**
- CSS definitions for each modern style (brutalism, glassmorphism, neumorphism)
- CSS definitions for each modern style (brutalism, glassmorphism, neumorphism, material)
- Theme configurations (colors, fonts, chart options) injected via `__THEME_CSS__`
- Use `--style` argument to select a modern style instead of `--template`
**Javascript (`templates/script.js`):**
- A single common script is used for each modern style (brutalism, glassmorphism, neumorphism)
- A single common script is used for each modern style (brutalism, glassmorphism, neumorphism, material)
- Theme configurations (colors, fonts, chart options) injected via `__THEME_CONFIG__`
- Data inserted via `__ALL_GAMES__` and `__TOP_N__`