settings: show the version, and let the rest timer be turned off
Two things people asked for on release day, both small, both awkward to live without. The version was not visible anywhere. mflova asked how to tell which build the phone app is running and andi242 said he had wondered the same that morning; issue #7 asks for it too. The support template in #install-help has been telling people to read it off "the bottom of Settings" — where it was not. It is there now, read from package.json at build time so it cannot drift from the release it shipped in. On the phone there is no address bar and no about box, so this was the only missing way to answer "did the update actually install". The rest timer had no off switch. andi242, in the per-exercise-timers thread: "I don't use rest timers, so I find it's a bit tedious to skip the timer every time." v1.2.10 made that worse rather than better — it now rests after every set except the last of the session, so an exercise that used to end quietly no longer does, and there was still no way out. "Off" now sits at the top of the same list as 60/90/120/150/180. The guard is inside startRest rather than at the four places that call it, for the same reason the rest-after-a-set rule became one shared condition: a rule that has to be repeated is a rule that gets forgotten. 'Off' already exists in all twelve locale packs, so this adds no translation work.
This commit is contained in:
1 parent
fa879a8b40
commit
9bec4bb785
4 files changed
+44
-2
No files matched your search
@@ -131,7 +131,7 @@ export default function Settings() {
|
||||
<Section title={t('During a workout')} footer={wakeOK ? t('The screen stays on while a workout is running, so you don’t have to unlock your phone between sets.') : null}>
|
||||
<SelectRow icon="timer" iconTint="var(--orange)" title={t('Rest timer')}
|
||||
value={S.restSec} onChange={v => update(s => { s.restSec = v })}
|
||||
options={[60, 90, 120, 150, 180].map(v => ({ value: v, label: v + 's' }))} />
|
||||
options={[{ value: 0, label: t('Off') }, ...[60, 90, 120, 150, 180].map(v => ({ value: v, label: v + 's' }))]} />
|
||||
{/* Default for a rest-pause burst added live on a plain set — a planned exercise's own
|
||||
"Rest (s)" (in its Intensifier config) overrides this, same as the main rest timer
|
||||
is the fallback whenever an exercise has no progression rule of its own. */}
|
||||
@@ -223,8 +223,12 @@ export default function Settings() {
|
||||
subtitle={t('to install openGym as a full-screen app.') + ' ' + (user ? t('Your data syncs with your profile — sign in anywhere to see it.') : t('Guest data stays on this device — export a backup now and then!'))} />
|
||||
</Section>}
|
||||
|
||||
{/* The version, at the bottom of Settings — which is where the support template has been
|
||||
telling people to look for it, and where it was not. On the phone build there is no
|
||||
address bar and no about box, so without this there is no way to tell which build you
|
||||
are running, or whether an update actually installed. */}
|
||||
<div className="dim small" style={{ textAlign: 'center', marginTop: 4, lineHeight: 1.6 }}>
|
||||
openGym · {t('free & open source (AGPL v3)')}<br />
|
||||
openGym v{__APP_VERSION__} · {t('free & open source (AGPL v3)')}<br />
|
||||
<a href="https://gitlab.com/DuarteSantos8/opengym" target="_blank" rel="noopener">source code</a> · exercise data: hasaneyldrm/exercises-dataset (MIT)<br />
|
||||
exercise images and animations © <a href="https://gymvisual.com/" target="_blank" rel="noopener">Gym visual</a>
|
||||
</div>
|
||||
|
||||
Reference in new issue
Block a user