Commit Graph
534 Commits
Author SHA1 Message Date
Duarte Santos f767d007a5 Merge !90: MCP: preview_session — what a routine will actually open with
# Conflicts:
#	mcp/README.md
2026-09-04 16:54:53 +02:00
Duarte Santos dfc63543ea Merge !94: feat: add Upper/Lower, Full Body and 5×5 starter plans
# Conflicts:
#	frontend/src/lib/pt-br-locale.test.js
2026-09-04 16:54:38 +02:00
Duarte Santos 194aa15f0e Merge !87: feat: add muscle exercise explorer
# Conflicts:
#	frontend/src/lib/pt-br-locale.test.js
2026-09-04 16:54:38 +02:00
Duarte Santos dab232a591 Merge !96: feat(workout): add configurable list view for active workouts
# Conflicts:
#	frontend/src/views/Workout.jsx
2026-09-04 16:54:38 +02:00
Duarte Santos d8130443a9 Merge !72: Exercise picker: the "+" adds now instead of opening the detail sheet
# Conflicts:
#	frontend/src/views/RoutineEdit.jsx
2026-09-04 16:54:08 +02:00
Duarte Santos 4bca5336d1 Merge !85: feat: add copy routine button to RoutineEdit view
# Conflicts:
#	frontend/src/lib/pt-br-locale.test.js
2026-09-04 16:53:52 +02:00
Duarte Santos f00400206d Merge !92: fix: capture working weight automatically 2026-09-04 16:53:52 +02:00
Duarte Santos 26847dac3b Merge !80: fix: use available width for exercise selector 2026-09-04 16:53:52 +02:00
Duarte Santos e94bd1250e Merge !82: BodyMap tests: import the geometry before the first render 2026-09-04 16:53:52 +02:00
Duarte Santos 566463c45f Merge !81: MCP: get_routine reports an exercise's own rest 2026-09-04 16:53:52 +02:00
Duarte Santos 6c22076d35 Merge !77: Show and edit progression policy during workouts 2026-09-04 16:53:52 +02:00
Duarte Santos 11bb1392f8 Merge !93: Fixed and tested deload spiral 2026-09-04 16:53:52 +02:00
Duarte Santos 953d91c806 Merge !71: fix: keep no-progression routine targets 2026-09-04 16:53:52 +02:00
Duarte Santos dca8393a7a Merge !89: Timer flash: blink the real theme instead of a black/white overlay, sk 2026-09-04 16:53:52 +02:00
Duarte Santos b301b8c81d Merge !84: fix: use exercise weight step for workout controls
# Conflicts:
#	frontend/src/views/Workout.jsx
2026-09-04 16:53:51 +02:00
Duarte Santos 8fb22e7994 Merge !97: bugfix: RIR counter ins supersets required two clicks per increment 2026-09-04 16:53:32 +02:00
Daniel Patrón Gómez 98ed4ddcb1 Merge branch 'main' into feat/workout-list-view 2026-09-04 16:14:27 +02:00
Duarte Santos dca6bcdf2d Images: alpine-Upgrades beim Bauen, npm aus dem publizierten api-Image, APK-Checksumme bei jedem Build
Der Trivy-Scan meldete 13 Funde, alle im api-Image und keiner in einer Abhaengigkeit der App:
2x openssl aus alpine (node:22-alpine hinkt alpines Fixes hinterher) und 11x in npms eigenem
gebuendelten Baum (tar, brace-expansion, pacote, ...). Beide Images ziehen jetzt `apk upgrade`
beim Bauen; das publizierte api-Image (Target default) verliert npm komplett - der Server
startet mit `node server.js`, nichts spawnt npm. build:api-check prueft das. Das coach-Target
behaelt npm fuer die Codex-CLI.

build:apk schreibt die .sha256 jetzt bei jedem Build (die Artefakt-Warnung auf Branches ist weg),
hochgeladen wird sie weiterhin nur vom Release-Tag.
2026-09-04 15:34:49 +02:00
prasad-gade05 e4139a4e9f feat: add muscle exercise explorer 2026-09-04 19:03:02 +05:30
Duarte Santos 4924ad8aeb Merge !95: gym membership QR check-in, in app and PWA, with a Settings switch 2026-09-04 15:21:53 +02:00
Duarte Santos 50a8b96285 cap sync: secure-storage and ML Kit plugin in the generated gradle/Podfile lists 2026-09-04 15:16:23 +02:00
Duarte Santos aa487d29f4 Gym check-in in the browser/PWA too
The feature was gated behind MOBILE because scanning went through the native ML Kit
plugin. iPhone users only have the PWA, so: route, Home card and Settings switch on
every platform; photo import and a live camera sheet decode in the browser with
BarcodeDetector where it exists and jsQR (Apache-2.0, lazy chunk) otherwise. The app
build keeps ML Kit. Round-trip test lean-qr -> jsQR.
2026-09-04 15:15:31 +02:00
Duarte Santos 0af9f55528 Gym check-in: Settings switch to turn the feature off
Off hides the Home card and the /checkin route; saved cards stay. On by default,
profiles without the key read as on. pt-BR: trailing comma the MR's last override
line was missing, override count 600.
2026-09-04 14:42:48 +02:00
Duarte Santos 5478b2d621 CI: Image-Digest robust auslesen (buildx druckte den ganzen Block, dotenv-Upload scheiterte) 2026-09-04 14:09:40 +02:00
Duarte Santos 2899f27fa6 CI: Pipelines fuer Fork-MRs, Testberichte im MR, Stack-Check der Images, Trivy+SBOM, Release-Preflight
Was die Pipeline neu kann:
- release:preflight prueft auf einem v*-Tag, dass frontend/api-package.json und CHANGELOG
  zum Tag passen und der Commit auf main liegt - bevor 40 Minuten Build anlaufen.
- test:* liefern JUnit (Fehler stehen im MR-Widget) und Coverage (Badge + Diff-Annotation);
  test:frontend misst das Bundle und zeigt im MR die Differenz zu main.
- verify:stack startet die gerade gepushten Images ueber die echte docker-compose.yml und
  fragt sie durch nginx ab; verify:scan (Trivy) scannt beide Images und legt je ein
  CycloneDX-SBOM ab, das der Release verlinkt.
- Der Release nennt Digests, Pull-Befehl und APK-SHA-256.
- mr:fork-pipelines startet die Pipelines von Fork-MRs bekannter Contributor hier im
  Projekt (Fork-Pipelines laufen sonst im Fork ohne Runner); Erstkontakte bekommen das
  Label ci-approval-needed. Braucht PIPELINE_API_TOKEN und den Zeitplan SCHEDULE_JOB=fork-mrs.

Korrekturen:
- web/Dockerfile: npm ci --ignore-scripts statt "npm ci || npm install" - der
  sharp/libvips-Download hatte v1.3.1 rot gemacht, und der Fallback ignorierte das Lockfile.
- interruptible + Retry bei Runner-Fehlern fuer alle Jobs, Timeouts pro Job,
  release-cli gepinnt, Docker-/Rules-Vorlagen statt Copy-Paste.
- Zeitplaene unterscheiden sich per SCHEDULE_JOB, damit Renovate und der MR-Starter sich
  nicht gegenseitig ausloesen.
2026-09-04 14:06:50 +02:00
Sebastian G 3197f9e9be Merge remote-tracking branch 'origin/main' into feat/gym-checkin-qr
# Conflicts:
#	frontend/package-lock.json
#	frontend/package.json
#	frontend/src/index.css
#	frontend/src/lib/pt-br-locale.test.js
#	frontend/src/locales/hu.js
#	frontend/src/locales/th.js
2026-09-04 13:14:01 +02:00
Sebastian G eb59240e2f fix: superset RIR counter fixed 2026-09-04 10:46:53 +02:00
Daniel Patrón Gómez e278051fae feat(workout): add configurable list view for active workouts 2026-09-04 10:09:30 +02:00
Duarte Santos d6f0db9b4b v1.3.1 v1.3.1 2026-09-04 09:51:25 +02:00
Duarte Santos 565311accc Handy: 'Use my self-hosted openGym' erkennt den Coach des gepaarten Servers
Der Mobile-Boot und das Pairing haben /api/config nie geladen, nur die Web-Variante und der
Login-Screen. Auf dem gepaarten Handy stand deshalb im Coach-Setup immer 'Your server has no
Coach enabled' — waehrend der Admin auf einen gruenen Test schaute (Discord-Meldung, 2026-09-04).
Jetzt: refreshConfig() fragt immer, loadConfig() cached nur noch darueber; Boot (remote) und
connectToServer laden die Config, der Setup-Screen fragt beim Oeffnen neu und zeigt bis dahin
'Loading…'. Regressionstest fuer load/refresh.
2026-09-04 09:51:01 +02:00
Duarte Santos 8b7abe5c26 Website: der AI Coach steht auf der Startseite 2026-09-03 23:24:30 +02:00
Duarte Santos 6b3c7d0ed7 v1.3.0 v1.3.0 2026-09-03 23:08:45 +02:00
Duarte Santos eead4afd88 assets: Brand-Dateien wieder raus, die 11d5632 versehentlich mitgenommen hat
BMC-Cover, Logo-Varianten und Merch-Vorlagen lagen unversioniert im Arbeitsverzeichnis und
sind mit einem git add -A in den Stats-Commit gerutscht. Sie gehoeren nicht ins oeffentliche
Repo; ab hier sind sie wieder unversioniert (in der Historie bleiben sie, main ist gegen
Force-Push geschuetzt).
2026-09-03 23:05:05 +02:00
Duarte Santos 11d5632156 Stats: die Strength-Liste sagt, wie lange ein Muskel nicht trainiert wurde
Die Zeilen unter der Strength-Karte zeigten die Saetze der letzten 90 Tage — fuer Muskeln,
die genau deshalb in der Liste stehen, weil sie lange nicht trainiert wurden, also fast immer
0, und sonst als ungerundeter Float (1.2000000000000002). Jetzt: Wochen seit dem letzten
Training bzw. 'not trained', gerundete 90-Tage-Saetze nur darueber, wenn es welche gibt.
Balance-Zeilen runden ueber fmtNum.
2026-09-03 23:01:34 +02:00
Duarte Santos 12309f394b Website: APK-Zeile v1.2.16 · 4.8 MB 2026-09-03 22:55:28 +02:00
Duarte Santos f190f0ba4a v1.2.16: das Web-Image baut wieder, und ein MR-Check dafuer
web/Dockerfile kopierte nur frontend/, aber frontend/src importiert den Coach-Kern aus
api/coach/core (../../../api/coach/core/*). Der Build-Stage liegt jetzt unter /app/frontend
und bekommt api/coach/core an derselben relativen Stelle wie im Repo. Neuer Job
build:web-check baut das Web-Image in jeder MR-Pipeline, die frontend/, web/ oder den Kern
anfasst (der API-Check gab es schon, den Web-Check nicht — deshalb ist v1.2.15 durchgerutscht).
Auf der VM gebaut und geprueft: App-Shell 200, Coach im Bundle.
v1.2.16
2026-09-03 22:45:31 +02:00
Duarte Santos 6c4af7d5fc v1.2.15 v1.2.15 2026-09-03 22:36:31 +02:00
Duarte Santos 02c75b320d Coach: ein API-Key gilt fuer die ganze Instanz, Warm-ups zaehlen nicht, Retries bei 429/5xx, sichtbare Admin-Felder
- Instanz-Modus: nur eine persoenliche Anmeldung (Setup-Token/OAuth) bindet sich an das
  erste Profil, ein API-Key ist gemessen und wird von allen Profilen unter den Tageslimits
  geteilt. Die Bindung passiert jetzt wirklich beim Einreihen eines Jobs (jobs.enqueue),
  vorher gab es sie nur in den Tests.
- HTTP-Adapter: 429/500/502/503/504/529 werden zweimal mit kurzer Pause wiederholt, ein
  4xx nie. retryDelayMs fuer Tests.
- Payload: Warm-up-Saetze wie in progression.js aus readSession/stalls, done/planned,
  Top-Satz, setsByBodyPart und workingWeights herausgefiltert; in vollen Sessions als
  warmup:true markiert, common.md sagt dem Modell, was das ist.
- Admin-Karte: .field im Card hat jetzt eine sichtbare Flaeche, die Limit-Zahlenfelder
  sind echte Felder statt weisser Browser-Boxen; Text zu 'Whose account pays' unterscheidet
  API-Key und persoenliche Anmeldung.
- Neuer Test e2e-apikey: Key ueber die Admin-Routen einlegen, Modelle listen, Review durch
  die echte Queue gegen einen lokalen Anthropic/OpenAI/Gemini-Stand-in, inkl. Header,
  Cache-Block, Schema, Retry und Auth-Fehler. api 150, frontend 1029, mcp 45 gruen.
2026-09-03 22:27:10 +02:00
Duarte Santos 63cf1deaed Merge main (v1.2.14) in coach-providers
Konflikte: zwoelf Locale-Packs (beide Seiten haengen Strings an, sechs doppelte
Schluessel bereinigt), Admin.jsx/admin.css (Coach-Karte bleibt, main-Umbau uebernommen),
Workout/Home/Plan/sheets (main gewinnt), docs.html (Coach-Kapitel war doppelt).
Ungarisch und Thai sind auf main dazugekommen und bekommen die 334 Coach-Strings.
pt-BR-Fingerprint nachgezogen.
2026-09-03 22:17:29 +02:00
sebastian.goendoer e57eac027f fix: read fresh store value in set-stepper bump to prevent stale closure in supersets
In a superset both ExerciseBlock instances subscribe to the same store
slice. When one member's field is updated the store clone invalidates all
entry references, causing both instances to re-render. The +/- button
handlers were closing over the set object from the previous render, so
the first tap wrote the correct value but the replacement closure made
the next tap operate on stale data -- requiring two taps per visible
increment instead of one.

Fix: read the current field value directly from the store at call time
instead of relying on the render-time snapshot.
2026-09-03 21:40:11 +02:00
Luke M 44138e07d7 feat: add starter plan chooser and loading flow 2026-09-03 11:36:39 +02:00
Luke M 89fdd1b787 feat: add additional starter plan definitions 2026-09-03 11:36:27 +02:00
Sebastian G 0f1500b102 i18n and tests 2026-09-03 11:24:17 +02:00
Sebastian G a797729dd0 feat(checkin): gym membership QR check-in (mobile-only)
Add a mobile-only gym check-in screen: saved membership codes shown as
QR codes in a swipeable carousel, reached from a 'Check in' card on Home.
Cards are added by typing the code, importing a photo, or scanning with
the camera. Only the code value + symbology are stored — never a photo;
the QR is regenerated from the value on every display.

Rendering uses lean-qr (MIT); camera scan and photo decode use
@capacitor-mlkit/barcode-scanning (Apache-2.0), pinned to the 7.x line
for Capacitor 7. Both are documented in NOTICE.md and bundled only in the
mobile build — the whole feature folds away in web/demo builds via MOBILE,
so nothing new lands in the web bundle. No backend/schema change: gymCards
rides the existing state sync and backup like every other field.

Non-QR symbologies are readable but not reproducible, so capture refuses
them rather than storing a code that would display wrong bars.

Native wiring: CAMERA permission + ML Kit barcode_ui meta-data
(AndroidManifest), NSCameraUsageDescription (iOS Info.plist), mlkit plugin
registered via cap sync. Debug builds get an applicationIdSuffix '.test'
and an 'OpenGymTest' label so a test build installs alongside the real app.
2026-09-03 11:10:58 +02:00
Manuel 6013874e99 fix: require explicit next after completed exercise 2026-09-02 21:07:48 +02:00
Manuel 697e482033 fix: capture working weight automatically 2026-09-02 17:48:53 +02:00
arhx91 c6d8e873ce Fixed and tested deload spiral 2026-09-02 17:39:09 +02:00
Sebastian G 5375dcc758 Merge remote-tracking branch 'origin/main' into feat/copy-routine
# Conflicts:
#	frontend/src/lib/pt-br-locale.test.js
2026-09-02 13:29:30 +02:00
Ameer KhanandClaude Opus 5 733dfa9d37 MCP: preview_session — what a routine will actually open with
get_routine reports what a routine stores. That is not what the athlete
sees. buildSets() consults the confirmed working weight and the previous
session's reps first, and applyPrescription() then overwrites the weight
with whatever the progression policy decided — so the routine's own
sets/reps/weight are the last fallback, not the first.

The gap is not academic. A routine holding "squat 3x8 @ 60 kg" opens at
75 kg when Greyskull deloaded from the last logged session, and an LLM
reading get_routine will confidently name a weight the app never shows.
Editing the routine to fix it changes nothing, which is worse.

preview_session mirrors beginWorkout() exactly — buildSets,
applyPrescription, applyIntensifierPlan — and returns, per exercise:
the planned target, the policy's decision with its stated reason, the
opening set rows including planned drop sets, and which of plan /
confirmed weight / history each number came from. `overridden` lists
just the exercises where the stored plan and the opening session
disagree, so the discrepancy cannot be scrolled past.

Read-only, no new dependency, one new tool registration. This is the
Phase 1.5 `progression_next` item from the README roadmap, named for
what it answers.

9 tests: precedence in both directions (plan wins with no history,
confirmed weight beats plan, policy beats both), reps carrying from
history, drop-set rows, explicit routine_id, rest day, unknown id.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DUgSPgBBqMYdy4vnKjK3bE
2026-09-02 08:18:56 +00:00
mzspicoli ad4bee99be Timer flash: blink the real theme instead of a black/white overlay, skip it while the app is backgrounded
The completion alert (Settings → "Flash screen when timer ends") laid an
opaque black/white rectangle over the whole screen, so the app's own UI
flickered into view between pulses. It now flips document.documentElement's
data-theme (light/dark) three times and settles back on whatever theme the
user actually had — same duration, no overlay, no rectangle. Fully dark ->
light, dark, light; fully light -> dark, light, dark; either way it lands
back where it started.

Separately: the rest/work timers reuse their tick on 'visibilitychange' to
stay accurate after the tab is throttled in the background. That reuse had
a side effect — reopening the app (or the tab regaining focus) after the
countdown had already finished while hidden replayed the completion beep,
vibration, flash and toast, even though nothing was actually watching when
it ended. Now those perceptible effects only fire if the countdown reaches
zero while the app is genuinely visible; finishing hidden only sends the
existing push notification, and reopening later stays silent.
2026-09-02 07:27:30 +02:00