Files
comarques-de-catalunya/index.html
Jaume Garriga Maestre b9404dd5b2 feat: add Level 8 Trencaclosques (drag-and-drop puzzle)
- Blind base map (grey slots for all comarques)
- Shuffled tray at the bottom with each comarca's shape + name
- Drag-and-drop with pointer events (works on touch + mouse)
- Hit test: SVG isPointInFill (precise) + 65px center fallback for small comarques
- Correct placement: comarca snaps to map with color + label
- Wrong drop: piece shakes and returns to tray (counts errors)
- Score = total pieces - errors; stars via showResult(8)
- Respects active group filter (same piece count as other map levels)
2026-05-13 22:29:45 +02:00

106 KiB