Appearance
Seasonal & Holiday Theming β
The HTML report supports seasonal and holiday themes with different mascots, particles, and glow effects.
Theme system β
getTheme(date) in html-report.ts returns a ThemeKey. Holidays are checked first (they override seasons).
Currently hardcoded to summer (white sparkles, default mascot) until all seasonal assets are finalized. To enable auto-detection, change:
typescript
// const theme: ThemeKey = 'summer';
const theme = getTheme(new Date());Holidays (checked first, by date range) β
| Theme key | Date range | Particles | Mascot | Glow |
|---|---|---|---|---|
new-year | Dec 30 β Jan 2 | π sparkle | default | gold |
valentines | Feb 13 β Feb 15 | π petal | default | pink |
easter | Thu before β Mon after Easter | π£ petal | default | warm yellow |
may17 | May 16 β May 18 | π³π΄ petal | default | red |
midsummer | Jun 20 β Jun 24 | π» petal | default | warm yellow |
halloween | Oct 25 β Nov 1 | π leaf | halloween | orange |
christmas | Dec 1 β Dec 29 | β snowflake | christmas | ice blue |
Easter is computed dynamically using the Anonymous Gregorian algorithm (easterSunday(year)).
Seasons (fallback) β
| Theme key | Months | Particles | Mascot | Glow |
|---|---|---|---|---|
winter | JanβFeb | β snowflake | default | ice blue |
spring | MarβMay | πΈ petal | default | pink |
summer | JunβAug | β¦ sparkle (CSS diamond) | default | white |
autumn | SepβNov | π leaf | default | orange |
Config structure β
THEME_CONFIG maps each ThemeKey to:
particlesβ emoji/character for floating particles in the hero headerparticleShapeβ CSS class suffix (shape-snowflake,shape-petal,shape-sparkle,shape-leaf)mascotβ key intoMASCOT_ASSETS('default','christmas','halloween')glowβrgba()color for the hero corner glow animation
Mascot assets β
| Key | File | Status |
|---|---|---|
default | bubbles-normal.ts | Done (Bubbles normal, 200px height, ~50KB base64) |
christmas | bubbles-christmas.ts | Done (Bubbles with Santa hat, ~43KB) |
halloween | bubbles-halloween.ts | Done (Bubbles halloween variant, ~54KB) |
Source PNGs are in /Users/nicolay/Cavai/CavaiAssets/. Original resolution ~3000px, resized to 200px height (retina) using sips -Z 200.
How to add a new mascot β
- Export the image as PNG (transparent background)
- Resize to ~200px height:
sips -Z 200 image.png - Convert to base64:
base64 -i image.png | tr -d '\n' - Create a new file like
bubbles-spring.ts:typescriptexport const BUBBLES_SPRING_BASE64 = 'data:image/png;base64,...'; - Import in
html-report.ts:typescriptimport { BUBBLES_SPRING_BASE64 } from './bubbles-spring.js'; - Add to
MASCOT_ASSETS:typescriptspring: BUBBLES_SPRING_BASE64, - Update
THEME_CONFIGentries that should use this mascot
Hero glow β
The hero header has a ::after pseudo-element with a radial gradient positioned in the bottom-right corner (where the mascot is). It uses --season-glow CSS custom property and pulses with a 5s glow-pulse animation. The on-brand Cavai gradient is always preserved β the glow is purely additive.
Console preview β
setSeason(themeKey) is available in the browser console for previewing any theme. It animates the mascot swap (slide out/in), updates particles, and changes the glow color. Available keys: all theme keys above plus normal (alias for summer).
TODO: Future assets β
Particle assets β
Currently particles use emoji characters. Could be replaced with proper SVG/PNG:
- Snowflake β delicate, white, semi-transparent (winter/christmas)
- Cherry blossom petal β soft pink, organic shape (spring)
- Leaf β warm orange/brown, organic (autumn)
- Holiday-specific β fireworks, Easter eggs, flags, etc.
Additional mascot variants β
- Spring β Bubbles with flowers?
- Summer β Bubbles with sunglasses?
- Autumn β Bubbles with scarf?
- Valentine's β Bubbles with hearts?
Future enhancements β
- Gradient tweaks β warm tones in summer, cooler in winter
- Animation variants β snowfall drift vs. petal scatter vs. leaf tumble
- User override β allow metadata to force a specific theme