Wer an der Stange arbeitet, rechnet vor jedem Satz dasselbe im Kopf: was muss
pro Seite drauf. Die App kennt beide Zahlen laengst — das Gesamtgewicht steht
im Satz, der Stangentyp in der Uebung — und hat sie nie zusammengebracht.
Neu: lib/bar.js mit den ueblichen Stangen (Olympia 20 kg, EZ 10, Multipresse 9,
Trap 25) und den Markierungen, die ein lb-Profil wirklich im Rack hat (45, 25,
20, 55) — keine umgerechneten 44,1 lb, die auf keiner Stange stehen. Das
Stangengewicht liegt in S.barWeights pro Uebung und in der Profil-Einheit, wie
jedes andere Gewicht im State: ein Einheitenwechsel beschriftet um und rechnet
nicht, sonst waere die Stange die eine Zahl, die unter dem Nutzer wegrutscht,
waehrend die Totale drumherum stehen bleiben.
Eingetragen wird weiterhin das Gesamtgewicht. Historie, Progression und 1RM
bedeuten exakt das, was sie vorher bedeutet haben — die Stange ist reine
Anzeige-Metadatei und speist nur die Rechnung "(Total − Stange) / 2".
Im Workout haengt der Chip "Stange 20 kg · 30 kg pro Seite" am Satz, der als
naechstes dran ist (erster offener; ist alles abgehakt, der schwerste). Ein
Tipp darauf oeffnet dieselbe Stepper-Zeile, die auch in Uebungsdetail und
Konfiguration steht — auf 0 gestellt faellt die Uebung auf den Standard ihres
Stangentyps zurueck, dieselbe "0 loescht den Schluessel"-Form wie bei den
nullbaren Satzfeldern.
Strings in allen vierzehn Sprachen; der pt-BR-Vererbungs-Fingerabdruck ist
nachgezogen (4 Overrides, 3 geerbt).
Rebased onto the Brazilian-Portuguese localization that landed while this was
in progress — that MR introduced EXERCISE_NAME_LANGS/exerciseNameFor()/
exerciseNameSearchText() in lib/i18n-core.js and a generated-pack convention
(scripts/exercise-name-sources/<lang>.json → scripts/build-<lang>-exercise-
names.mjs → frontend/src/exercise-names/<lang>.js), which is exactly the
mechanism this MR originally invented independently as NAME_LANGS/nameFor().
Dropped that duplicate plumbing entirely and reused theirs instead:
- frontend/src/locales/hu.js — full UI translation, 740/740 keys (654 from
the original translation pass, 86 more added to cover the drop-set/rest-
pause, equipment-profile, server-pairing and session-note strings that
landed in the same window).
- frontend/src/instr/hu.js — unchanged mechanism, all 1,324 exercises' step-
by-step instructions. The upstream exercise dataset (hasaneyldrm/exercises-
dataset) still has no hu field, so this stays hand-maintained here.
- scripts/exercise-name-sources/hu.json + scripts/build-hu-exercise-
names.mjs (mirrors the pt-BR ones) → frontend/src/exercise-names/hu.js —
all 1,324 exercise names, added to EXERCISE_NAME_LANGS. Exercise names
now render the same bilingual way pt-BR's do: the translated name alone
when it's the same loanword as English (e.g. "burpee"), otherwise
"translated (english)".
- One small generalization to exerciseNameFor(): its loanword-casing
comparison was hardcoded to `.toLocaleLowerCase('pt-BR')`. Changed to the
active language instead, so it is correct for hu (and any language after
it) rather than only for pt-BR. No behavior change for pt-BR itself.
- Workout.remove.test.jsx's locale-coverage test hardcoded an expected pack
count; already fixed once for the 12th language, re-applied here since hu
is now the 14th — derives the count from LANGS so this stops recurring.
Translated in bulk with AI assistance and validated programmatically (id
coverage against the 1,324-exercise catalogue, key-set parity across all 13
locales via check-locales.mjs, duplicate/collision and encoding checks) —
not yet proofread line-by-line by a fluent human reviewer, same disclosure
standard scripts/exercise-name-sources/README.md and instruction-sources/
README.md already hold the pt-BR translations to.
node frontend/scripts/check-locales.mjs: 13 locales, 740 keys each, in sync.
Full frontend test suite: 39 files / 533 tests passing.
- check-locales.mjs was failing: th.js had 628/741 keys. One key
('...rest after both') didn't match the source string used in code
('...rest when done'), and 112 keys were missing outright — most of
them the whole tail block (equipment profiles, mobile-app pairing,
session notes) that never made it into th.js.
- Renamed the mismatched key and added Thai translations for the 112
missing keys, preserving {n} placeholders and section comments to
match the other locale files.
- Workout.remove.test.jsx hardcoded 12 locale packs; bumped to 13 now
that th.js is a complete pack.
npm test / npm run build / node scripts/check-locales.mjs all pass now.
An exercise can now carry its own restSec: the workout timer prefers it
over the global default, a superset rests the longest resolved rest in
the group after each round, and the field travels with shared plans —
normalised on import like every other prescribed number. An explicit
restSec still times its rest when the global timer is turned off; only
the default is silenced. Closes#10.