73 Commits
Author SHA1 Message Date
Duarte Santos ee2be743b0 Standalone mobile app: Capacitor shells for iOS and Android
A second flavor of openGym (VITE_MOBILE=1) that runs entirely on the
phone: no account, no server, no sync. State is mirrored into a file in
the app's private storage (survives WebView storage eviction), the
workout-day reminder is a native local notification scheduled on planned
weekdays, and backups export through the OS share sheet. Exercise media
loads from the same CDN as the demo build. npm run build:mobile, then
Android Studio / Xcode — see docs/MOBILE.md. NOTICE.md gains an AGPL §7
app-store exception.
2026-07-23 15:14:36 +02:00
Duarte Santos 389315625c Import history from FitNotes, Strong, Hevy and Apple Health
Losing years of logging is the thing that stops people trying another
tracker, so Settings -> Data -> Import from another app now reads their
exports directly.

All of these ship the same thing in a different dialect: one row per set
with a date, an exercise name and some mix of weight/reps/distance/time.
So the parser builds a column map from the header rather than assuming
positions, and a new app is usually a few header aliases. Verified
against real exports from Strong (1903 sets) and Hevy, both FitNotes
column layouts, and an Apple Health body-mass extract.

Exercise matching is the part that decides whether this is useful.
Parenthetical qualifiers and BB/DB shorthand are normalised, names are
compared as an order-independent bag of words, and a curated table maps
the plain names people actually log onto the dataset's qualified ones -
without it, 'Squat' resolved to 'weighted squat' and 'Leg Press' to
'smith leg press'. Where a name stays genuinely ambiguous it is left
unmatched and becomes a custom exercise rather than guessed at: filing
years of training under the wrong lift is worse than a name the user can
see and fix. Nothing in the file is ever dropped.

A summary sheet shows workouts, sets, matches, misses and any unit
conversion before anything is written, and merging skips days that
already have data, so importing twice - or from two apps - never
duplicates a workout.
2026-07-23 14:50:36 +02:00
Duarte Santos fac45f9af9 Release v1.2.1: muscle map and live demo
Consolidates everything since v1.2.0 into one version: the muscle map
(Stats balance card, routine preview, finish screen, male/female body
diagram), the browser-only GitHub Pages demo, and the fix for the blank
screen when finishing a workout from its last exercise.

api/package.json tracks the release alongside the frontend.
2026-07-23 12:56:52 +02:00
Duarte Santos cd77cfdd84 Muscle map: see which muscles your training actually reaches
A front-and-back body diagram, shaded with the same accent ramp as the
activity heatmap, in three places: Stats gets a Muscle balance card over
a week / 30d / 90d / all-time window, the routine editor previews what a
session hits while you build it, and the finish screen shows what you
just trained. Settings switches between a male and female figure.

The Stats card's real job is the list underneath: the muscles that got
nothing in the period. Load is counted in effective sets — full weight
for an exercise's target muscle, partial for its supporting ones — not
kilograms, since 100 kg of leg press and 12 kg of lateral raise say
nothing about which muscle worked harder. Shading is relative within the
window, so it always reads as a balance rather than an absolute.

The dataset spells muscles inconsistently ('delts', 'deltoids' and
'shoulders' are one muscle); all 50 spellings it uses are normalised onto
the 18 the diagram draws, verified against the full catalogue so nothing
is dropped silently. Custom exercises fall back to their body part.

Geometry is converted from MuscleMap (MIT, see NOTICE.md), which ships
its paths as Swift source rather than .svg. At ~90 kB it is imported
dynamically, so the initial bundle is unchanged.

Also fixes a crash this surfaced but did not cause: finishing a workout
from its last exercise blanked the whole app, because the per-exercise
weight sheet read the running workout without checking it was still
there and finishing clears it while that sheet is on screen.
2026-07-23 12:51:24 +02:00
Duarte Santos e9bf38f39b Publish a browser-only demo to GitHub Pages
Self-hosting is a fair ask once someone knows they want the app, but it's a lot
to ask of someone deciding whether to look at it at all. A demo build (VITE_DEMO=1)
drops the parts that need the backend — passkeys, sync, admin — and boots straight
into guest mode with a seeded example profile, so every screen has real data behind
it: twelve weeks of Push/Pull/Legs with progression and the odd missed session,
twice-weekly weigh-ins trending toward a goal, PRs, and today's session moved onto
the current day so there's always something to press Start on.

The seed generator is imported dynamically and the demo-only UI folds away at build
time, so none of it lands in the bundle self-hosters ship. Exercise media (~140 MB)
isn't committed anywhere, so the demo build points VITE_IMG_BASE / VITE_GIF_BASE at
the upstream dataset on jsDelivr, pinned to a commit; unset, both still resolve to
img/ and gif/ next to the app exactly as before.

Deployed by a Pages workflow on every push to main.
2026-07-23 12:42:40 +02:00
Duarte Santos b28a58930c Release v1.2.0: complete visual redesign
Rebuilt design system (one type scale, neutral surface ramp, hairline
separators), a 77-icon hand-drawn set replacing every emoji in the UI,
grouped routine-icon picker with the old emoji mapped forward, new tab
bar with a raised Start/Resume button, and a reorganised Home.

Chart fixes that came out of it: axis labels, gridlines and the target
line were painted with colour variables the new sheet no longer defines
and fell back to black-on-black; the hover readout is now placed from
its measured size so it can't be clipped at the edges, and it clears
when the pointer leaves the chart.
2026-07-23 11:55:52 +02:00
Duarte Santos fc36476a5f Release v1.1.3: consolidate all work since v1.1.2
v1.1.2 is the last published release; v1.1.3 and v1.1.4 were tagged but
never released. Collapse those two plus the equipment filter and the rest
timer fix into a single v1.1.3 changelog section, grouped into 'Admin
dashboard' and 'Exercises & workout'. Set frontend/package.json to 1.1.3.

Covers #12, the admin dashboard (phases 1+2), #6 and #14.
2026-07-22 14:52:32 +02:00
Duarte Santos fbf125f6a2 Filter exercises by equipment (#6)
Adds an equipment filter row under the body-part chips, in both the
Exercises library and the exercise picker sheet.

The options are derived from the exercises already matching the current
body part and search, ordered most-common-first, so the row stays short
instead of listing all 28 equipment values (many with a single exercise)
and every combination on screen has results behind it. The row hides
itself when there is nothing to choose between.

Changing the body part clears the equipment filter; a search that
narrows the chosen equipment away drops it rather than showing an empty
list. All equipment terms were already localized — only the new 'Any
equipment' label needed adding across the 11 locale packs.

Closes #6
2026-07-22 14:44:27 +02:00
Duarte Santos f3ba05aece Admin dashboard (phase 2): live 'training now' heartbeat + release v1.1.4
Backend: in-memory presence map + POST /api/activity heartbeat (authed);
each /api/admin/users row carries a fresh 'live' snapshot (routine,
exercise x/y, sets done/total, started-at) with a ~70s TTL. Disabling a
user clears their presence immediately.

Frontend: the workout screen pings /api/activity every 20s (signed-in
only) and sends a leave signal on unmount (fetch + sendBeacon). The
dashboard gains a 'Training now' section and live markers, auto-
refreshing every 15s.

Cuts the complete admin-dashboard feature (phases 1+2) as v1.1.4.
2026-07-22 02:06:19 +02:00
Duarte Santos dabffdebc0 Minimize the exercise animation during a workout (#12)
Adds a persistent minimize/expand toggle to the workout animation so the
set rows are reachable without scrolling past a full-height GIF. A new
S.gifSize setting ('full' | 'mini') is flipped by the button, saved and
synced like other prefs, and applied across exercises and future
workouts. Tapping the animation still pauses/plays it.

Closes #12
2026-07-22 01:00:50 +02:00
Duarte Santos 785380ab1b Release v1.1.2: consolidate all work since v1.1.1
Collapse the never-released intermediate versions (custom exercises,
localization, comma fix, narrow-phone fix) into a single v1.1.2 release.
Merge their changelog sections under one v1.1.2 heading and set the
package version to 1.1.2. The confusing v1.2.0 and v1.1.3 tags are
removed in favour of a clean v1.1.2.
2026-07-22 00:50:21 +02:00
Duarte Santos 91e0bd73b9 Release v1.1.3: custom exercises + comma decimal separator
Fold the custom-exercises feature (#11) and the comma-decimal fix (#13)
into a single v1.1.3 release. Merge their changelog sections and set the
package version to 1.1.3.
2026-07-22 00:38:24 +02:00
Duarte Santos a4f73e34d1 Custom exercises: optional description + reachable delete
Adds an optional free-text description to custom exercises, shown where
a built-in exercise shows its animation (detail + config sheets) and
included in exercise search.

Deleting was only reachable from the Exercises tab detail sheet, which
you never pass through when tapping an exercise inside a routine. The
routine's config sheet now offers "Edit or delete this exercise", and
its old "Remove exercise" button is relabelled "Remove from routine" so
removing from a routine and deleting for good are no longer confusable.

Refs #11
2026-07-22 00:34:27 +02:00
Duarte Santos 0cefcb3636 Custom exercises: create your own with name + body part
Users can add movements missing from the catalogue (issue #11) from the
exercise picker or the Exercises tab. Custom exercises live in synced
state (S.customEx) and are merged into the exercise index, so routines,
supersets, logging, PRs, stats and history all work unchanged. The
animation stays blank by design. Editable and deletable from the detail
sheet; deleting keeps logged history readable by stamping the name into
past entries. Translated into all 12 UI languages.

Closes #11
2026-07-22 00:26:16 +02:00
Duarte Santos 93bd4e3850 Renumber comma-fix release as v1.1.3 2026-07-22 00:11:26 +02:00
Duarte Santos 30fd3a84a1 Accept comma as decimal separator in numeric inputs
iOS decimal keyboards in many locales only offer a comma; type=number
inputs report an empty value for it, snapping the field to 0. Numeric
fields (weight, speed, etc.) are now text inputs with inputMode=decimal
backed by a shared NumField component that normalizes ',' to '.' and
keeps partial input like "33," alive while typing.

Fixes #13
2026-07-22 00:03:48 +02:00
Duarte Santos c05b0756ec Localization: 12 UI languages + exercise instructions in 10 (#7)
Adds a Language setting (Settings → Appearance) that translates the whole
app: a tiny dependency-free i18n layer (English source strings as keys,
per-language dictionaries in frontend/src/locales/) plus per-language
exercise-instruction packs generated from the upstream dataset
(frontend/src/instr/, via scripts/build-instructions.mjs).

UI: en, de, es, fr, it, pt, pl, tr, ru, zh, ko, hi. Instructions: all of
those except de/pt (not in the upstream dataset — fall back to English).
Body-part/equipment/muscle labels and date formats are localized too;
exercise names stay English (upstream limitation).

Everything is lazy-loaded per language (Vite code-splitting), so the
initial bundle is unchanged; the choice syncs with the profile like the
theme. Closes #7.
2026-07-21 21:45:24 +02:00
Duarte Santos b9f8d18bbd Fix exercise-config sheet overflowing on narrow phones (#10)
The Sets/Reps/Weight stepper row (and its cardio variant) used fixed-width
steppers that added up to ~445px — wider than an iPhone viewport — clipping
the Weight stepper off-screen and letting iOS Safari pan the whole page
sideways. Steppers in the config sheet now flex and shrink to fit, and
html/body clip horizontal overflow as a safety net.
2026-07-21 20:48:14 +02:00
Duarte Santos fbc615aa26 Release v1.1.1 2026-07-21 12:48:12 +02:00
Duarte Santos 0c240ba6f8 Release v1.1.0 2026-07-21 11:20:24 +02:00
Duarte Santos 8e20c2c304 Publish prebuilt Docker images to GHCR
GitHub Actions builds and pushes multi-arch (amd64/arm64) api/web
images to ghcr.io on every push to main and on version tags, so
self-hosters can 'docker compose pull' instead of building from
source. compose.yml keeps both image: and build: so building locally
still works via --build.
2026-07-21 11:11:26 +02:00
Duarte Santos 4c2b6344f7 Add push notifications: rest-timer alert + workout-day reminder
Web Push (VAPID) backend: keys auto-generated on first run, per-user
subscriptions, one new dependency (web-push). The rest timer schedules
a server-side push on start/extend and cancels it on skip or on-screen
completion, so it only actually fires if the tab got suspended before
finishing. A per-minute check sends an optional daily reminder on days
with a planned routine that hasn't been logged yet.

Opt in per-profile in Settings — requires a signed-in passkey profile.
2026-07-21 11:07:10 +02:00
Duarte Santos ca6fd7c4d6 Relicense to AGPL-3.0 + README glow-up (banner, badges, screenshots, roadmap, CHANGELOG)
- Lizenz von MIT auf GNU AGPL v3.0 (verhindert geschlossene/kommerzielle Forks;
  bleibt echtes Open Source). LICENSE, package.json, NOTICE, CONTRIBUTING, App-Footer
  (Source-Link, AGPL-Netzwerk-Klausel) angepasst
- README komplett überarbeitet: SVG-Banner/Logo, Badges, Screenshots (Home/Workout/
  Stats), Roadmap, Tech, klarere Struktur
- CHANGELOG.md + assets/ (Banner, Screenshots)
2026-07-20 20:42:33 +02:00