Exercises.
Project plan — a minimalist exercise PWA, hosted on GitHub Pages.
Vision
One small, fast, installable web app for daily physical practice. Three sections —
GymStretchingCalisthenics —
presented as a compact grid of cards. Every exercise has its own illustrated figure,
a fullscreen player with rep selection or auto-starting timers (toggleable per exercise), and one-tap logging that flows to the next exercise by itself.
Everything lives in localStorage on your device: no accounts, no servers, works offline.
The app
- Grid. A fixed catalog of 120 exercises as a compact 2-column grid (more columns on wider screens), filtered by section chips — Gym adds sub-groups matching the real training program: eight ~1 hour sessions Série A through Série H, each exercise with its working weight (editable in-app).
- Fullscreen player. Tap any exercise → it takes the whole screen. Pick the reps with a stepper (revealed behind an Edit toggle, remembered per exercise) and hit Done — the set is logged (reps × weight) and the next exercise slides in automatically. Timer exercises start counting down on entry, chime at zero, log themselves and advance. A reps ⇄ timer toggle lives inside the player.
- Corpo routine. A guided stretching & mobility session (details below) with auto-advancing hold/rest timers, chimes, vibration, wake-lock and resume-after-interruption.
- History. Sets grouped by day with weekly totals and weights. JSON export / import as backup, plus optional private-gist sync across devices.
- PWA. Add to home screen → opens standalone, fully offline via a cache-first service worker (all 120 figures precached — ~0.7 MB).
The Corpo routine
Built from the “Corpo” playlist (@gabriel_om), filtered to its stretching & mobility content and focused on three goals: front split (espacate), pancake opening, and feet / ballet work.
Format: each slot is 60 s hold + 30 s rest (bilateral stretches take one slot per side). The eight source blocks are paired into four standalone ~30-minute series so a session fits in a lunch break; Série 1 opens with the warm-up and the others carry a warm-up reminder — never stretch cold.
| Series | Block | Slots | Stretches (×2 = per side) |
|---|---|---|---|
| Série 1 Feet & Ankles |
Warm-up | 8 | Leg Swings · Cat–Cow · Thoracic Rotation ×2 · Hip CARs ×2 · Deep Squat Hold · Down Dog → Walk |
| Feet & Ankles | 13 | Ankle Circles ×2 · Knee-over-toe Rocks ×2 · Wall Calf ×2 · Soleus ×2 · Foot Doming · Point & Flex · Relevé Holds · Kneeling Toe Stretch · Arch & Pointe Stretch | |
| Série 2 Psoas & Hamstrings |
Psoas & Hip Flexors | 9 | Psoas March · Low Lunge ×2 · Couch Stretch ×2 · Lizard ×2 · Standing Hip Extension ×2 |
| Hamstrings | 10 | Elephant Walks · Forward Fold · Single-leg Hamstring ×2 · Hinge Fold · Half Split ×2 · Hurdler ×2 · Jefferson Curl | |
| Série 3 Front Split |
Front Split · Espacate | 16 | Lunge Pulses ×2 · Lunge ⇄ Half-split Flow ×2 · Pigeon ×2 · Standing Quad ×2 · Front Split ×2 · Split PNF Press ×2 · Standing Split ×2 · Twisted Lizard ×2 |
| Back & Spine | 4 | Sphinx → Cobra · Puppy Pose · Chest Opener · Bridge Hold | |
| Série 4 Pancake & Glutes |
Pancake & Middle Split | 14 | Butterfly · 90/90 ×2 · Frog Rocks · Frog Hold · Horse Stance · Straddle Side Reach ×2 · Straddle Center · Pancake Fold · Cossack ×2 · Wall Straddle · Wide-leg Fold |
| Glutes & Finish | 5 | Figure-4 ×2 · Glute Bridge · Hip Airplane ×2 |
Every completed hold is logged to History automatically. The routine definition lives in one file
(js/data.js), so re-deriving it from an updated playlist is a single-file change.
Data
All keys are namespaced (exercises.*) because every *.github.io site shares one localStorage origin.
exercises.log— append-only set entries{t, d, ex, mode, v, w?, side?, routine?}exercises.prefs— per-exercise mode / weight overridesexercises.routine— resume state for the Corpo playerexercises.settings,exercises.v— theme & schema versionexercises.gist— optional sync token + gist id (never exported)
Cross-device sync is serverless: the append-only log is union-merged into a private GitHub gist, so two devices never conflict. The same JSON shape is the export/import backup format.
Tech
- Static vanilla ES modules — no framework, no build step, no dependencies. GitHub Pages serves it as-is.
- Every figure is an AI illustration generated by Gemini Flash Image (“Nano Banana”):
tools/genimages.mjswrites a PNG per exercise in a single flat, androgynous, sage-toned style, andtools/optimize.mjsshrinks each to a transparent 768 px WebP (img/gen/<id>.webp) that reads on both light and dark backgrounds. The app loads them directly viaimgForinjs/data.js. - Cache-first service worker with a versioned shell — bump
VERSIONinsw.jsto ship updates.
Roadmap
- Watch companion — count reps automatically (motion sensors), log into the same JSON schema, sync via the gist or Web Share.
- Playlist re-sync — regenerate the Stretching catalog when “Corpo” changes.
- Streaks & simple charts in History.
- Configurable hold/rest durations per block.