Skip to content

Open-source gym & body-weight tracker, now in the App Store (iPhone + Apple Watch) and as an Android APK. Plan routines, log workouts, see which muscles are trained, import from Strong/Hevy/FitNotes. Self-host it or use it on the phone alone.

Minimize the exercise animation during a workout (#12)

Duarte Santosdabffdebc016
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 54ad0d441..365050200 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,13 @@
# Changelog
+## v1.1.3 — 2026-07-22
+
+- 🔎 **Minimize the exercise animation during a workout** (#12). A ⤡ Minimize / ⤢ Expand button
+ on the animation shrinks it to a thin strip so the set rows sit right under your thumb — no more
+ scrolling past a big GIF to tick off a set. Your choice is remembered and applied to every
+ exercise and future workout until you change it, so you set it once. Tapping the animation still
+ pauses/plays it as before.
+
## v1.1.2 — 2026-07-22
Custom exercises, full localization, and input fixes.
diff --git a/frontend/package.json b/frontend/package.json
index a8842c464..2517c82f1 100644
--- a/frontend/package.json
+++ b/frontend/package.json
@@ -1,7 +1,7 @@
{
"name": "opengym-frontend",
"private": true,
- "version": "1.1.2",
+ "version": "1.1.3",
"type": "module",
"scripts": {
"dev": "vite",
diff --git a/frontend/src/components/Media.jsx b/frontend/src/components/Media.jsx
index 76119485e..26456d8d7 100644
--- a/frontend/src/components/Media.jsx
+++ b/frontend/src/components/Media.jsx
@@ -1,16 +1,25 @@
import { useState } from 'react'
import { imgSrc, gifSrc } from '../lib/exercises.js'
+import { useStore } from '../store/useStore.js'
import { t } from '../lib/i18n.js'
// Big autoplaying animation; tap toggles to the still frame. `compact` shrinks it (superset cards).
// Custom exercises have no media — the animation stays blank by design (issue #11).
-export default function Media({ ex, id, compact }) {
+// `minimizable` (workout view) adds a persistent minimize/expand control so the animation stops
+// eating the screen; the chosen size is saved to settings and carries across exercises and
+// future workouts (issue #12).
+export default function Media({ ex, id, compact, minimizable }) {
const [playing, setPlaying] = useState(true)
+ const gifSize = useStore(s => s.S.gifSize)
+ const update = useStore(s => s.update)
if (!ex.gif) return null
+ const mini = minimizable && gifSize === 'mini'
+ const toggleSize = e => { e.stopPropagation(); update(s => { s.gifSize = mini ? 'full' : 'mini' }) }
return (
- <div className={'exmedia' + (compact ? ' compact' : '')} id={id} onClick={() => setPlaying(p => !p)}>
+ <div className={'exmedia' + (compact ? ' compact' : '') + (mini ? ' mini' : '')} id={id} onClick={() => setPlaying(p => !p)}>
<img decoding="async" src={playing ? gifSrc(ex) : imgSrc(ex)} alt={ex.n} />
- <span className="gifhint">{playing ? '⏸ ' + t('tap to pause') : '▶ ' + t('tap to play')}</span>
+ {minimizable && <button className="giftoggle" onClick={toggleSize}>{mini ? '⤢ ' + t('Expand') : '⤡ ' + t('Minimize')}</button>}
+ {!mini && <span className="gifhint">{playing ? '⏸ ' + t('tap to pause') : '▶ ' + t('tap to play')}</span>}
</div>
)
}
diff --git a/frontend/src/index.css b/frontend/src/index.css
index 74c06d16e..4d5e5c232 100644
--- a/frontend/src/index.css
+++ b/frontend/src/index.css
@@ -162,6 +162,8 @@ textarea.input{min-height:88px;resize:vertical;line-height:1.45}
.exmedia img{width:100%;height:340px;object-fit:contain;display:block}
.exmedia .gifhint{position:absolute;right:10px;bottom:10px;background:rgba(0,0,0,.62);color:#fff;
border-radius:99px;padding:4px 11px;font-size:.72rem;font-weight:600}
+.exmedia .giftoggle{position:absolute;left:10px;bottom:10px;background:rgba(0,0,0,.62);color:#fff;
+ border:none;border-radius:99px;padding:5px 12px;font-size:.72rem;font-weight:600;cursor:pointer}
.sethead{display:flex;align-items:center;gap:9px;padding-bottom:2px;
font-size:.66rem;color:var(--dim);font-weight:700;text-transform:uppercase;letter-spacing:.05em}
.sethead .n-sp{width:26px;flex:none}
@@ -333,6 +335,8 @@ h4.sec{font-size:.8rem;text-transform:uppercase;letter-spacing:.08em;color:var(-
.ss-ex{position:relative}
.ss-amp{text-align:center;font-size:1.3rem;font-weight:800;color:var(--acc);margin:14px 0 8px}
.exmedia.compact img{height:190px}
+/* minimized workout animation — small enough to keep the set rows in view (issue #12) */
+.exmedia.mini img{height:88px}
/* ---------- home: today's session row under the week strip ---------- */
.today-row{display:flex;align-items:center;justify-content:space-between;gap:10px;
diff --git a/frontend/src/locales/de.js b/frontend/src/locales/de.js
index fa9f9c420..1924b7fc9 100644
--- a/frontend/src/locales/de.js
+++ b/frontend/src/locales/de.js
@@ -350,5 +350,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Beschreibung (optional) — Aufbau, Hinweise, was du dir merken willst',
'Delete exercise': 'Übung löschen',
'Edit or delete this exercise': 'Übung bearbeiten oder löschen',
- 'Remove from routine': 'Aus Routine entfernen'
+ 'Remove from routine': 'Aus Routine entfernen',
+ 'Minimize': 'Verkleinern',
+ 'Expand': 'Vergrössern'
}
diff --git a/frontend/src/locales/es.js b/frontend/src/locales/es.js
index b82759257..e85d7811c 100644
--- a/frontend/src/locales/es.js
+++ b/frontend/src/locales/es.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Descripción (opcional) — preparación, consejos, lo que quieras recordar',
'Delete exercise': 'Eliminar ejercicio',
'Edit or delete this exercise': 'Editar o eliminar este ejercicio',
- 'Remove from routine': 'Quitar de la rutina'
+ 'Remove from routine': 'Quitar de la rutina',
+ 'Minimize': 'Minimizar',
+ 'Expand': 'Ampliar'
}
diff --git a/frontend/src/locales/fr.js b/frontend/src/locales/fr.js
index cfe6a0330..284924009 100644
--- a/frontend/src/locales/fr.js
+++ b/frontend/src/locales/fr.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Description (facultatif) — installation, conseils, ce que vous voulez retenir',
'Delete exercise': 'Supprimer l’exercice',
'Edit or delete this exercise': 'Modifier ou supprimer cet exercice',
- 'Remove from routine': 'Retirer de la routine'
+ 'Remove from routine': 'Retirer de la routine',
+ 'Minimize': 'Réduire',
+ 'Expand': 'Agrandir'
}
diff --git a/frontend/src/locales/hi.js b/frontend/src/locales/hi.js
index e09b48cbe..55e07383d 100644
--- a/frontend/src/locales/hi.js
+++ b/frontend/src/locales/hi.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'विवरण (वैकल्पिक) — सेटअप, संकेत, जो कुछ भी याद रखना चाहें',
'Delete exercise': 'एक्सरसाइज़ हटाएं',
'Edit or delete this exercise': 'इस एक्सरसाइज़ को संपादित या हटाएं',
- 'Remove from routine': 'रूटीन से हटाएं'
+ 'Remove from routine': 'रूटीन से हटाएं',
+ 'Minimize': 'छोटा करें',
+ 'Expand': 'बड़ा करें'
}
diff --git a/frontend/src/locales/it.js b/frontend/src/locales/it.js
index d75935d20..0537158e4 100644
--- a/frontend/src/locales/it.js
+++ b/frontend/src/locales/it.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Descrizione (facoltativa) — setup, spunti, quello che vuoi ricordare',
'Delete exercise': 'Elimina esercizio',
'Edit or delete this exercise': 'Modifica o elimina questo esercizio',
- 'Remove from routine': 'Rimuovi dalla routine'
+ 'Remove from routine': 'Rimuovi dalla routine',
+ 'Minimize': 'Riduci',
+ 'Expand': 'Ingrandisci'
}
diff --git a/frontend/src/locales/ko.js b/frontend/src/locales/ko.js
index efa78cd21..98ef27347 100644
--- a/frontend/src/locales/ko.js
+++ b/frontend/src/locales/ko.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': '설명 (선택) — 세팅, 큐, 기억하고 싶은 모든 것',
'Delete exercise': '운동 삭제',
'Edit or delete this exercise': '이 운동 편집 또는 삭제',
- 'Remove from routine': '루틴에서 제거'
+ 'Remove from routine': '루틴에서 제거',
+ 'Minimize': '축소',
+ 'Expand': '확대'
}
diff --git a/frontend/src/locales/pl.js b/frontend/src/locales/pl.js
index 9bc5dda87..3c144567c 100644
--- a/frontend/src/locales/pl.js
+++ b/frontend/src/locales/pl.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Opis (opcjonalnie) — ustawienie, wskazówki, co chcesz zapamiętać',
'Delete exercise': 'Usuń ćwiczenie',
'Edit or delete this exercise': 'Edytuj lub usuń to ćwiczenie',
- 'Remove from routine': 'Usuń z planu'
+ 'Remove from routine': 'Usuń z planu',
+ 'Minimize': 'Zmniejsz',
+ 'Expand': 'Powiększ'
}
diff --git a/frontend/src/locales/pt.js b/frontend/src/locales/pt.js
index 355de229e..6b8cc5c29 100644
--- a/frontend/src/locales/pt.js
+++ b/frontend/src/locales/pt.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Descrição (opcional) — preparação, dicas, o que quiseres lembrar',
'Delete exercise': 'Eliminar exercício',
'Edit or delete this exercise': 'Editar ou eliminar este exercício',
- 'Remove from routine': 'Remover da rotina'
+ 'Remove from routine': 'Remover da rotina',
+ 'Minimize': 'Minimizar',
+ 'Expand': 'Ampliar'
}
diff --git a/frontend/src/locales/ru.js b/frontend/src/locales/ru.js
index 2ec50ab04..bddcac26f 100644
--- a/frontend/src/locales/ru.js
+++ b/frontend/src/locales/ru.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Описание (необязательно) — настройка, подсказки, всё, что хотите запомнить',
'Delete exercise': 'Удалить упражнение',
'Edit or delete this exercise': 'Изменить или удалить это упражнение',
- 'Remove from routine': 'Убрать из программы'
+ 'Remove from routine': 'Убрать из программы',
+ 'Minimize': 'Свернуть',
+ 'Expand': 'Развернуть'
}
diff --git a/frontend/src/locales/tr.js b/frontend/src/locales/tr.js
index 95f7aca18..b2fc5de61 100644
--- a/frontend/src/locales/tr.js
+++ b/frontend/src/locales/tr.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': 'Açıklama (isteğe bağlı) — kurulum, ipuçları, hatırlamak istediklerin',
'Delete exercise': 'Egzersizi sil',
'Edit or delete this exercise': 'Bu egzersizi düzenle veya sil',
- 'Remove from routine': 'Rutinden çıkar'
+ 'Remove from routine': 'Rutinden çıkar',
+ 'Minimize': 'Küçült',
+ 'Expand': 'Büyüt'
}
diff --git a/frontend/src/locales/zh.js b/frontend/src/locales/zh.js
index 34168a4a2..94c091310 100644
--- a/frontend/src/locales/zh.js
+++ b/frontend/src/locales/zh.js
@@ -332,5 +332,7 @@ export default {
'Description (optional) — setup, cues, anything you want to remember': '描述(可选)——设置、要点,任何你想记住的内容',
'Delete exercise': '删除动作',
'Edit or delete this exercise': '编辑或删除此动作',
- 'Remove from routine': '从计划中移除'
+ 'Remove from routine': '从计划中移除',
+ 'Minimize': '缩小',
+ 'Expand': '放大'
}
diff --git a/frontend/src/store/useStore.js b/frontend/src/store/useStore.js
index 8a954fcf0..aa0cfe788 100644
--- a/frontend/src/store/useStore.js
+++ b/frontend/src/store/useStore.js
@@ -8,7 +8,7 @@ export const DEF = {
unit: 'kg', restSec: 90, sound: true, lang: 'en',
theme: 'dark', accent: 'lime', targetW: null,
bodyweight: [], routines: [], week: {}, dayPlan: {},
- exWeights: {}, workouts: [], active: null, customEx: [],
+ exWeights: {}, workouts: [], active: null, customEx: [], gifSize: 'full',
reminder: { on: false, time: '08:00', tz: null }
}
const clone = o => JSON.parse(JSON.stringify(o))
diff --git a/frontend/src/views/Workout.jsx b/frontend/src/views/Workout.jsx
index de2b42210..a9654fd85 100644
--- a/frontend/src/views/Workout.jsx
+++ b/frontend/src/views/Workout.jsx
@@ -69,7 +69,7 @@ function ExerciseBlock({ entryIdx, compact, onToggle, onField, onBumpAll, onAddS
</div>
)
return <>
- <Media ex={ex} key={entry.id} compact={compact} />
+ <Media ex={ex} key={entry.id} compact={compact} minimizable />
<div className="row between" style={{ marginBottom: 6 }}>
<div style={{ fontSize: compact ? '1.05rem' : '1.2rem', fontWeight: 800, textTransform: 'capitalize', lineHeight: 1.2 }}>{ex.n}</div>
<button className="iconbtn" onClick={() => exerciseDetailSheet(ex)}>ℹ️</button>