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.
JavaScript apple-watchbodyweightdockerfitnessfitness-trackergymhealthiosmcpnodejspasskeysprogressive-web-applicationspwareactself-hostedself-hostingvitewebauthnweightliftingworkout-tracker
feat(cardio): rate a cardio set in RPE from its set menu, read by the fatigue model
Duarte Santos0b2a70a3ff7d
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex f7042bbee..363f3e0ee 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -141,6 +141,10 @@ per muscle. Settings → Workout → Fine-tuning turns it off.- **Volume while you lift.** The progress bar at the top of a workout now ends in the session'svolume, adding up every set you tick, in all four layouts. Handy for deciding whether today wasenough or you've got one more in you (#774).+- **Rate your cardio** (Discord). A cardio set's menu (tap the set number) now has How hard it+ felt, in RPE whatever your sets use, worded for a run instead of reps left. An easy walk then+ loads your fatigue map less than a hard run; unrated cardio counts as it always did. The incline+ keeps its column.- **Count warm-ups in volume**, if you like (#719). A new switch in Settings → Units & languageadds your done warm-ups to every volume the app shows: the workout, the summary, history,Stats, the report and the coach. Off by default, and records ignore warm-ups either way. Thediff --git a/frontend/src/lib/effort.js b/frontend/src/lib/effort.jsindex 3e5e57596..80d5905e5 100644--- a/frontend/src/lib/effort.js+++ b/frontend/src/lib/effort.js@@ -185,18 +185,20 @@ export const isHardSet = s => { const r = rirOf(s); return r != null && r <= HAR// 0, 0.5 and 1 actually changes the training. A typed value between presets still colours by// the band it falls in, so the flexibility of a free number is never lost.export const EFFORT_BANDS = [- { rir: 0, max: 0.25, color: 'var(--purple)', feel: 'Nothing left, went to failure' },- { rir: 0.5, max: 0.75, color: 'var(--red)', feel: 'Maybe half a rep left' },- { rir: 1, max: 1.5, color: 'var(--orange)', feel: 'One more rep in the tank' },- { rir: 2, max: 2.5, color: 'var(--yellow)', feel: 'Two more reps' },- { rir: 3, max: 3.5, color: 'var(--green)', feel: 'Three more reps' },- { rir: 4, max: Infinity, color: 'var(--acc-2)', feel: 'Easy, warm-up territory' }+ { rir: 0, max: 0.25, color: 'var(--purple)', feel: 'Nothing left, went to failure', cardioFeel: 'All out, nothing left' },+ { rir: 0.5, max: 0.75, color: 'var(--red)', feel: 'Maybe half a rep left', cardioFeel: 'Nearly all out' },+ { rir: 1, max: 1.5, color: 'var(--orange)', feel: 'One more rep in the tank', cardioFeel: 'Very hard, one word at a time' },+ { rir: 2, max: 2.5, color: 'var(--yellow)', feel: 'Two more reps', cardioFeel: 'Hard, short sentences only' },+ { rir: 3, max: 3.5, color: 'var(--green)', feel: 'Three more reps', cardioFeel: 'Working, but steady' },+ { rir: 4, max: Infinity, color: 'var(--acc-2)', feel: 'Easy, warm-up territory', cardioFeel: 'Easy, you could chat the whole way' }]// The presets shown in the picker, hardest first — the order they read on the scale and the// order the colours run. `tail` is the collapsed top bucket ("4+"): its value is the floor it// stands for, so a tap logs a concrete 4, not a range nothing downstream could average.+// Cardio rates on the same bands in RPE (a run has no reps left), so it gets its own words:+// the talk test instead of reps in the tank. `cardioFeel` is that sentence.export const EFFORT_PRESETS = EFFORT_BANDS.map((b, i) => ({- rir: b.rir, color: b.color, feel: b.feel, tail: i === EFFORT_BANDS.length - 1+ rir: b.rir, color: b.color, feel: b.feel, cardioFeel: b.cardioFeel, tail: i === EFFORT_BANDS.length - 1}))/**diff --git a/frontend/src/lib/recovery.cardio-rpe.test.js b/frontend/src/lib/recovery.cardio-rpe.test.jsnew file mode 100644index 000000000..b2de0b6a3--- /dev/null+++ b/frontend/src/lib/recovery.cardio-rpe.test.js@@ -0,0 +1,33 @@+// Cardio effort (Discord thehypetrainhobo): a treadmill walk counted as a full hard set for its+// muscles, because a cardio row had no way to carry a rating. The set menu now stores an RPE on+// the row as `rpe`, and the fatigue model reads it through rirOf like any rated set. No new+// weighting for walking: a rated row follows the same curve a rated lift does, an unrated one+// stays exactly where it was.+import { describe, expect, it } from 'vitest'+import { fatigueOf } from './recovery.js'++const HOUR = 3600000+const NOW = Date.UTC(2026, 9, 25, 12)+const TREADMILL = '2259' // walking on treadmill+const walk = extra => [{+ id: 'w1', d: '2026-10-25', start: NOW - 2 * HOUR,+ entries: [{ id: TREADMILL, target: { mode: 'cardio', min: 30, speed: 5 }, sets: [{ min: 30, speed: 5, incline: 8, done: true, ...extra }] }],+}]+// The muscle the walk loads most, read off the model itself.+const slug = Object.entries(fatigueOf(walk({}), NOW)).sort((a, b) => b[1] - a[1])[0][0]++describe('a rated cardio row in the fatigue model', () => {+ it('an easy walk (RPE 6) loads less than an unrated one, a hard one the same', () => {+ const unrated = fatigueOf(walk({}), NOW)[slug]+ expect(unrated).toBeGreaterThan(0)+ expect(fatigueOf(walk({ rpe: 6 }), NOW)[slug]).toBeLessThan(unrated)+ // RPE 9 is RIR 1, inside the hard range, which counts full like an unrated set.+ expect(fatigueOf(walk({ rpe: 9 }), NOW)[slug]).toBeCloseTo(unrated, 12)+ })++ it('unrated cardio keeps its weight (no walking discount)', () => {+ const run = walk({})+ run[0].entries[0].sets[0].speed = 10+ expect(fatigueOf(walk({}), NOW)[slug]).toBeCloseTo(fatigueOf(run, NOW)[slug], 12)+ })+})diff --git a/frontend/src/locales/ar.js b/frontend/src/locales/ar.jsindex cf8880c3a..3ab416b29 100644--- a/frontend/src/locales/ar.js+++ b/frontend/src/locales/ar.js@@ -2604,4 +2604,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'هذه المجموعة كلها: {0} {1} هو الأثقل، لذا يبقى الوزن كما هو.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'لا يوجد رمز على هاتفك؟ لا يظهر إلا وهو متصل بهذا الخادم: الإعدادات ← الحساب ← الاتصال بخادمي.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'لتسجيل الدخول على حاسوبك أيضًا تحتاج إلى خادمك الخاص. اربط هذا الهاتف به، وعندها يعطي «إضافة جهاز آخر» الحاسوب رمزًا.',+ 'How hard it felt': 'كم كان صعبًا',+ 'Not rated yet': 'لم يُقيَّم بعد',+ 'How hard did that feel?': 'كم بدا ذلك صعبًا؟',+ 'Tap how it felt, or type an exact {0}.': 'اضغط على ما شعرت به، أو اكتب {0} دقيقًا.',+ 'All out, nothing left': 'بكل ما لديّ، لم يتبقَّ شيء',+ 'Nearly all out': 'قريب من أقصى جهد',+ 'Very hard, one word at a time': 'صعب جدًا، كلمة واحدة في كل مرة',+ 'Hard, short sentences only': 'صعب، جمل قصيرة فقط',+ 'Working, but steady': 'مجهود، لكن بثبات',+ 'Easy, you could chat the whole way': 'سهل، يمكنك الدردشة طوال الوقت',}diff --git a/frontend/src/locales/bn.js b/frontend/src/locales/bn.jsindex f35b0d4bc..f607bb829 100644--- a/frontend/src/locales/bn.js+++ b/frontend/src/locales/bn.js@@ -2628,4 +2628,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'এটাই পুরো স্ট্যাক: {0} {1} সবচেয়ে ভারী, তাই ওজন একই থাকে।','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'ফোনে কোনো কোড নেই? এই সার্ভারে সংযুক্ত থাকলেই কেবল কোড থাকে: সেটিংস → অ্যাকাউন্ট → আমার সার্ভারে সংযোগ করুন।','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'কম্পিউটারেও সাইন ইন করতে আপনার নিজের সার্ভার লাগবে। এই ফোনটি সেখানে সংযোগ করুন, তারপর আরেকটি ডিভাইস যোগ করুন কম্পিউটারকে একটি কোড দেবে।',+ 'How hard it felt': 'কতটা কঠিন লাগল',+ 'Not rated yet': 'এখনও রেট করা হয়নি',+ 'How hard did that feel?': 'এটা কতটা কঠিন লাগল?',+ 'Tap how it felt, or type an exact {0}.': 'কেমন লাগল তাতে ট্যাপ করো, বা সঠিক {0} লেখো।',+ 'All out, nothing left': 'সব দিয়ে দিয়েছি, কিছু বাকি নেই',+ 'Nearly all out': 'প্রায় সর্বোচ্চ',+ 'Very hard, one word at a time': 'খুব কঠিন, একবারে একটা শব্দ',+ 'Hard, short sentences only': 'কঠিন, শুধু ছোট বাক্য',+ 'Working, but steady': 'পরিশ্রম হচ্ছে, তবে স্থির',+ 'Easy, you could chat the whole way': 'সহজ, পুরো সময় গল্প করা যায়',}diff --git a/frontend/src/locales/de.js b/frontend/src/locales/de.jsindex 3d5b98d84..5394a50fd 100644--- a/frontend/src/locales/de.js+++ b/frontend/src/locales/de.js@@ -2569,4 +2569,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'Das ist der ganze Block: {0} {1} ist das Schwerste, also bleibt das Gewicht.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Kein Code auf deinem Handy? Den gibt es nur, solange es mit diesem Server verbunden ist: Einstellungen → Konto → Mit meinem Server verbinden.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Um dich auch am Computer anzumelden, brauchst du deinen eigenen Server. Verbinde dieses Handy damit, dann gibt Weiteres Gerät hinzufügen dem Computer einen Code.',+ 'How hard it felt': 'Wie hart es sich anfühlte',+ 'Not rated yet': 'Noch nicht bewertet',+ 'How hard did that feel?': 'Wie hart hat sich das angefühlt?',+ 'Tap how it felt, or type an exact {0}.': 'Tippe, wie es sich angefühlt hat, oder gib einen genauen {0}-Wert ein.',+ 'All out, nothing left': 'Alles gegeben, nichts mehr übrig',+ 'Nearly all out': 'Fast am Limit',+ 'Very hard, one word at a time': 'Sehr hart, nur noch einzelne Wörter',+ 'Hard, short sentences only': 'Hart, nur kurze Sätze',+ 'Working, but steady': 'Fordernd, aber gleichmäßig',+ 'Easy, you could chat the whole way': 'Locker, du könntest die ganze Zeit plaudern',}diff --git a/frontend/src/locales/es.js b/frontend/src/locales/es.jsindex ba241c1b8..9dd3a3ac2 100644--- a/frontend/src/locales/es.js+++ b/frontend/src/locales/es.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'Es toda la columna: {0} {1} es lo máximo que da, así que el peso se queda.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': '¿No hay código en tu móvil? Solo tiene uno mientras está conectado a este servidor: Ajustes → Cuenta → Conectar a mi servidor.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Para iniciar sesión también en tu ordenador hace falta tu propio servidor. Conecta este móvil a él y Añadir otro dispositivo le dará un código al ordenador.',+ 'How hard it felt': 'Qué tan duro se sintió',+ 'Not rated yet': 'Sin valorar todavía',+ 'How hard did that feel?': '¿Qué tan duro se sintió?',+ 'Tap how it felt, or type an exact {0}.': 'Toca cómo se sintió o escribe un {0} exacto.',+ 'All out, nothing left': 'A tope, no queda nada',+ 'Nearly all out': 'Casi a tope',+ 'Very hard, one word at a time': 'Muy duro, palabra a palabra',+ 'Hard, short sentences only': 'Duro, solo frases cortas',+ 'Working, but steady': 'Exigente, pero estable',+ 'Easy, you could chat the whole way': 'Fácil, podrías charlar todo el rato',}diff --git a/frontend/src/locales/fr.js b/frontend/src/locales/fr.jsindex 9a599160a..ac2044a27 100644--- a/frontend/src/locales/fr.js+++ b/frontend/src/locales/fr.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'C’est toute la pile : {0} {1} est le maximum, donc le poids reste.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Pas de code sur ton téléphone ? Il n’en a un que s’il est connecté à ce serveur : Réglages → Compte → Se connecter à mon serveur.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Pour te connecter aussi sur ton ordinateur, il te faut ton propre serveur. Connecte ce téléphone à celui-ci, puis Ajouter un autre appareil donne un code à l’ordinateur.',+ 'How hard it felt': 'Ressenti de l’effort',+ 'Not rated yet': 'Pas encore noté',+ 'How hard did that feel?': 'C’était dur à quel point ?',+ 'Tap how it felt, or type an exact {0}.': 'Touche ton ressenti, ou saisis un {0} exact.',+ 'All out, nothing left': 'À fond, plus rien dans le réservoir',+ 'Nearly all out': 'Presque à fond',+ 'Very hard, one word at a time': 'Très dur, un mot à la fois',+ 'Hard, short sentences only': 'Dur, phrases courtes seulement',+ 'Working, but steady': 'Ça travaille, mais régulier',+ 'Easy, you could chat the whole way': 'Facile, tu pourrais papoter tout du long',}diff --git a/frontend/src/locales/hi.js b/frontend/src/locales/hi.jsindex 1d88592b1..d0040eed3 100644--- a/frontend/src/locales/hi.js+++ b/frontend/src/locales/hi.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'यही पूरा स्टैक है: {0} {1} सबसे भारी है, इसलिए वज़न वही रहता है।','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'फ़ोन पर कोई कोड नहीं? कोड तभी होता है जब वह इस सर्वर से कनेक्ट हो: सेटिंग्स → खाता → मेरे सर्वर से कनेक्ट करें।','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'कंप्यूटर पर भी साइन इन करने के लिए आपका अपना सर्वर चाहिए। इस फ़ोन को उससे कनेक्ट करें, फिर दूसरा डिवाइस जोड़ें कंप्यूटर को एक कोड देगा।',+ 'How hard it felt': 'कितना कठिन लगा',+ 'Not rated yet': 'अभी रेट नहीं किया',+ 'How hard did that feel?': 'यह कितना कठिन लगा?',+ 'Tap how it felt, or type an exact {0}.': 'जैसा लगा उस पर टैप करें, या सटीक {0} लिखें।',+ 'All out, nothing left': 'पूरा ज़ोर, कुछ नहीं बचा',+ 'Nearly all out': 'लगभग पूरा ज़ोर',+ 'Very hard, one word at a time': 'बहुत कठिन, एक-एक शब्द ही',+ 'Hard, short sentences only': 'कठिन, बस छोटे वाक्य',+ 'Working, but steady': 'मेहनत है, पर स्थिर',+ 'Easy, you could chat the whole way': 'आसान, पूरे रास्ते बातें कर सकते हो',}diff --git a/frontend/src/locales/hu.js b/frontend/src/locales/hu.jsindex 62369b1a9..adb491f03 100644--- a/frontend/src/locales/hu.js+++ b/frontend/src/locales/hu.js@@ -2552,4 +2552,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'Ez az egész oszlop: {0} {1} a legtöbb, így a súly marad.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Nincs kód a telefonodon? Csak akkor van, ha ehhez a szerverhez csatlakozik: Beállítások → Fiók → Csatlakozás a szerveremhez.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Ahhoz, hogy a gépeden is bejelentkezz, saját szerver kell. Csatlakoztasd hozzá ezt a telefont, és a Másik eszköz hozzáadása ad egy kódot a gépnek.',+ 'How hard it felt': 'Mennyire volt nehéz',+ 'Not rated yet': 'Még nincs értékelve',+ 'How hard did that feel?': 'Mennyire érezted nehéznek?',+ 'Tap how it felt, or type an exact {0}.': 'Koppints arra, milyen volt, vagy írj be pontos {0} értéket.',+ 'All out, nothing left': 'Teljes erő, semmi sem maradt',+ 'Nearly all out': 'Majdnem teljes erő',+ 'Very hard, one word at a time': 'Nagyon nehéz, csak egy-egy szó',+ 'Hard, short sentences only': 'Nehéz, csak rövid mondatok',+ 'Working, but steady': 'Dolgozol, de egyenletesen',+ 'Easy, you could chat the whole way': 'Könnyű, végig tudnál beszélgetni',}diff --git a/frontend/src/locales/it.js b/frontend/src/locales/it.jsindex 7418e9b21..c918aa84c 100644--- a/frontend/src/locales/it.js+++ b/frontend/src/locales/it.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'È tutto il pacco: {0} {1} è il massimo, quindi il peso resta.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Nessun codice sul telefono? Ne ha uno solo mentre è connesso a questo server: Impostazioni → Account → Connettiti al mio server.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Per accedere anche dal computer serve il tuo server. Collega questo telefono al server e Aggiungi un altro dispositivo darà un codice al computer.',+ 'How hard it felt': 'Quanto è stato duro',+ 'Not rated yet': 'Non ancora valutato',+ 'How hard did that feel?': 'Quanto ti è sembrato duro?',+ 'Tap how it felt, or type an exact {0}.': 'Tocca come ti è sembrato, o scrivi un {0} esatto.',+ 'All out, nothing left': 'Al massimo, non resta niente',+ 'Nearly all out': 'Quasi al massimo',+ 'Very hard, one word at a time': 'Molto duro, una parola alla volta',+ 'Hard, short sentences only': 'Duro, solo frasi brevi',+ 'Working, but steady': 'Impegnativo, ma costante',+ 'Easy, you could chat the whole way': 'Facile, potresti chiacchierare per tutto il tempo',}diff --git a/frontend/src/locales/ko.js b/frontend/src/locales/ko.jsindex c333166e8..130305ada 100644--- a/frontend/src/locales/ko.js+++ b/frontend/src/locales/ko.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': '스택 끝이에요: {0} {1}이(가) 가장 무거우니 무게를 유지해요.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': '휴대폰에 코드가 없나요? 이 서버에 연결되어 있을 때만 코드가 있어요: 설정 → 계정 → 내 서버에 연결.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': '컴퓨터에서도 로그인하려면 내 서버가 필요해요. 이 휴대폰을 서버에 연결하면 다른 기기 추가가 컴퓨터에 쓸 코드를 줘요.',+ 'How hard it felt': '얼마나 힘들었는지',+ 'Not rated yet': '아직 평가 안 함',+ 'How hard did that feel?': '얼마나 힘들게 느껴졌나요?',+ 'Tap how it felt, or type an exact {0}.': '느낌을 탭하거나 정확한 {0}를 입력하세요.',+ 'All out, nothing left': '전력, 남은 게 없음',+ 'Nearly all out': '거의 전력',+ 'Very hard, one word at a time': '매우 힘듦, 한 단어씩만',+ 'Hard, short sentences only': '힘듦, 짧은 문장만',+ 'Working, but steady': '힘쓰지만 안정적',+ 'Easy, you could chat the whole way': '쉬움, 내내 수다 떨 수 있음',}diff --git a/frontend/src/locales/pl.js b/frontend/src/locales/pl.jsindex 6a37ebf14..0b54d03f8 100644--- a/frontend/src/locales/pl.js+++ b/frontend/src/locales/pl.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'To cały stos: {0} {1} to najwięcej, więc ciężar zostaje.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Nie ma kodu na telefonie? Pojawia się tylko, gdy telefon jest połączony z tym serwerem: Ustawienia → Konto → Połącz z moim serwerem.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Żeby logować się też na komputerze, potrzebujesz własnego serwera. Połącz z nim ten telefon, a Dodaj kolejne urządzenie da komputerowi kod.',+ 'How hard it felt': 'Jak ciężko było',+ 'Not rated yet': 'Jeszcze bez oceny',+ 'How hard did that feel?': 'Jak ciężko to było?',+ 'Tap how it felt, or type an exact {0}.': 'Stuknij, jak było, albo wpisz dokładne {0}.',+ 'All out, nothing left': 'Na maksa, nic nie zostało',+ 'Nearly all out': 'Prawie na maksa',+ 'Very hard, one word at a time': 'Bardzo ciężko, pojedyncze słowa',+ 'Hard, short sentences only': 'Ciężko, tylko krótkie zdania',+ 'Working, but steady': 'Wysiłek, ale równo',+ 'Easy, you could chat the whole way': 'Lekko, dałoby się gadać całą drogę',}diff --git a/frontend/src/locales/pt-BR.js b/frontend/src/locales/pt-BR.jsindex 7265c1ec0..aad52b1b4 100644--- a/frontend/src/locales/pt-BR.js+++ b/frontend/src/locales/pt-BR.js@@ -1642,6 +1642,16 @@ export const PT_BR_OVERRIDES = {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'É o bloco todo: {0} {1} é o máximo que dá, então o peso fica.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Não tem código no celular? Ele só aparece enquanto o celular está conectado a este servidor: Configurações → Conta → Conectar ao meu servidor.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Para entrar também no computador, você precisa do seu próprio servidor. Conecte este celular a ele, e Adicionar outro dispositivo dá um código para o computador.',+ 'How hard it felt': 'Quão puxado foi',+ 'Not rated yet': 'Ainda sem avaliação',+ 'How hard did that feel?': 'Quão puxado pareceu?',+ 'Tap how it felt, or type an exact {0}.': 'Toque em como foi, ou digite um {0} exato.',+ 'All out, nothing left': 'No limite, não sobrou nada',+ 'Nearly all out': 'Quase no limite',+ 'Very hard, one word at a time': 'Muito puxado, uma palavra por vez',+ 'Hard, short sentences only': 'Puxado, só frases curtas',+ 'Working, but steady': 'Exigente, mas estável',+ 'Easy, you could chat the whole way': 'Fácil, dava para bater papo o tempo todo',}export default { ...pt, ...PT_BR_OVERRIDES }diff --git a/frontend/src/locales/pt.js b/frontend/src/locales/pt.jsindex a340f2759..bcf3212b2 100644--- a/frontend/src/locales/pt.js+++ b/frontend/src/locales/pt.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'É o bloco todo: {0} {1} é o máximo que dá, por isso o peso fica.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Não há código no telemóvel? Só tem um enquanto está ligado a este servidor: Definições → Conta → Ligar ao meu servidor.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Para iniciar sessão também no computador precisas do teu próprio servidor. Liga este telemóvel a ele e Adicionar outro dispositivo dá um código ao computador.',+ 'How hard it felt': 'Quão duro foi',+ 'Not rated yet': 'Ainda sem avaliação',+ 'How hard did that feel?': 'Quão duro te pareceu?',+ 'Tap how it felt, or type an exact {0}.': 'Toca em como te soube, ou escreve um {0} exato.',+ 'All out, nothing left': 'No limite, não sobra nada',+ 'Nearly all out': 'Quase no limite',+ 'Very hard, one word at a time': 'Muito duro, uma palavra de cada vez',+ 'Hard, short sentences only': 'Duro, só frases curtas',+ 'Working, but steady': 'Exigente, mas estável',+ 'Easy, you could chat the whole way': 'Fácil, dava para conversar o tempo todo',}diff --git a/frontend/src/locales/ru.js b/frontend/src/locales/ru.jsindex 9925e0002..3215cf6b6 100644--- a/frontend/src/locales/ru.js+++ b/frontend/src/locales/ru.js@@ -2553,4 +2553,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'Это весь стек: {0} {1} и есть максимум, так что вес остаётся.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'На телефоне нет кода? Он появляется, только пока телефон подключён к этому серверу: Настройки → Аккаунт → Подключиться к моему серверу.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Чтобы входить и с компьютера, нужен ваш собственный сервер. Подключите к нему этот телефон, и «Добавить другое устройство» выдаст компьютеру код.',+ 'How hard it felt': 'Насколько тяжело было',+ 'Not rated yet': 'Пока без оценки',+ 'How hard did that feel?': 'Насколько тяжело это было?',+ 'Tap how it felt, or type an exact {0}.': 'Нажми, как ощущалось, или введи точный {0}.',+ 'All out, nothing left': 'На пределе, сил не осталось',+ 'Nearly all out': 'Почти на пределе',+ 'Very hard, one word at a time': 'Очень тяжело, по одному слову',+ 'Hard, short sentences only': 'Тяжело, только короткие фразы',+ 'Working, but steady': 'Работаю, но ровно',+ 'Easy, you could chat the whole way': 'Легко, можно болтать всю дорогу',}diff --git a/frontend/src/locales/sv.js b/frontend/src/locales/sv.jsindex c736e7eaf..9521aa3ff 100644--- a/frontend/src/locales/sv.js+++ b/frontend/src/locales/sv.js@@ -2596,4 +2596,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'Det är hela stacken: {0} {1} är det tyngsta, så vikten står kvar.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Ingen kod på telefonen? Den finns bara medan telefonen är ansluten till den här servern: Inställningar → Konto → Anslut till min server.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'För att logga in på datorn också behöver du en egen server. Anslut telefonen till den, så ger Lägg till en annan enhet datorn en kod.',+ 'How hard it felt': 'Hur tungt det kändes',+ 'Not rated yet': 'Inte betygsatt än',+ 'How hard did that feel?': 'Hur tungt kändes det?',+ 'Tap how it felt, or type an exact {0}.': 'Tryck på hur det kändes, eller skriv ett exakt {0}.',+ 'All out, nothing left': 'Allt gav jag, inget kvar',+ 'Nearly all out': 'Nästan allt',+ 'Very hard, one word at a time': 'Mycket tungt, ett ord i taget',+ 'Hard, short sentences only': 'Tungt, bara korta meningar',+ 'Working, but steady': 'Jobbigt, men jämnt',+ 'Easy, you could chat the whole way': 'Lätt, du kunde prata hela vägen',}diff --git a/frontend/src/locales/th.js b/frontend/src/locales/th.jsindex 35985dccd..2b154bf4c 100644--- a/frontend/src/locales/th.js+++ b/frontend/src/locales/th.js@@ -2560,4 +2560,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'สุดสแต็กแล้ว: {0} {1} หนักที่สุด น้ำหนักจึงคงเดิม','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'ไม่มีรหัสในโทรศัพท์? จะมีรหัสก็ต่อเมื่อเชื่อมต่อกับเซิร์ฟเวอร์นี้อยู่: ตั้งค่า → บัญชี → เชื่อมต่อกับเซิร์ฟเวอร์ของฉัน','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'หากจะเข้าสู่ระบบบนคอมพิวเตอร์ด้วย ต้องมีเซิร์ฟเวอร์ของคุณเอง เชื่อมต่อโทรศัพท์นี้กับเซิร์ฟเวอร์ แล้วเพิ่มอุปกรณ์อื่นจะให้รหัสกับคอมพิวเตอร์',+ 'How hard it felt': 'รู้สึกหนักแค่ไหน',+ 'Not rated yet': 'ยังไม่ได้ให้คะแนน',+ 'How hard did that feel?': 'รู้สึกหนักแค่ไหน?',+ 'Tap how it felt, or type an exact {0}.': 'แตะความรู้สึก หรือพิมพ์ {0} แบบตรงๆ',+ 'All out, nothing left': 'สุดแรง ไม่เหลืออะไรแล้ว',+ 'Nearly all out': 'เกือบสุดแรง',+ 'Very hard, one word at a time': 'หนักมาก พูดได้ทีละคำ',+ 'Hard, short sentences only': 'หนัก พูดได้แค่ประโยคสั้นๆ',+ 'Working, but steady': 'เหนื่อย แต่คงที่',+ 'Easy, you could chat the whole way': 'สบายๆ คุยได้ตลอดทาง',}diff --git a/frontend/src/locales/tr.js b/frontend/src/locales/tr.jsindex 491b77e71..df3dbde8b 100644--- a/frontend/src/locales/tr.js+++ b/frontend/src/locales/tr.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'Bloğun tamamı bu: {0} {1} en ağırı, o yüzden ağırlık sabit kalır.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'Telefonunda kod yok mu? Kod yalnızca bu sunucuya bağlıyken olur: Ayarlar → Hesap → Sunucuma bağlan.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Bilgisayarda da giriş yapmak için kendi sunucun gerekir. Bu telefonu ona bağla, ardından Başka bir cihaz ekle bilgisayara bir kod verir.',+ 'How hard it felt': 'Ne kadar zorladı',+ 'Not rated yet': 'Henüz puanlanmadı',+ 'How hard did that feel?': 'Ne kadar zor geldi?',+ 'Tap how it felt, or type an exact {0}.': 'Nasıl hissettirdiğine dokun ya da tam bir {0} yaz.',+ 'All out, nothing left': 'Sonuna kadar, hiçbir şey kalmadı',+ 'Nearly all out': 'Neredeyse sonuna kadar',+ 'Very hard, one word at a time': 'Çok zor, tek tek kelime',+ 'Hard, short sentences only': 'Zor, sadece kısa cümleler',+ 'Working, but steady': 'Zorlayıcı ama dengeli',+ 'Easy, you could chat the whole way': 'Kolay, yol boyunca sohbet edebilirdin',}diff --git a/frontend/src/locales/uk.js b/frontend/src/locales/uk.jsindex 649df415b..874616a0a 100644--- a/frontend/src/locales/uk.js+++ b/frontend/src/locales/uk.js@@ -2546,4 +2546,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': 'Це весь стек: {0} {1} і є максимум, тож вага лишається.','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': 'На телефоні немає коду? Він є, лише поки телефон підключений до цього сервера: Налаштування → Акаунт → Підключитися до мого сервера.','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': 'Щоб входити й на комп’ютері, потрібен твій власний сервер. Підключи до нього цей телефон, і «Додати інший пристрій» дасть комп’ютеру код.',+ 'How hard it felt': 'Наскільки важко було',+ 'Not rated yet': 'Ще без оцінки',+ 'How hard did that feel?': 'Наскільки важко це було?',+ 'Tap how it felt, or type an exact {0}.': 'Торкнись, як відчувалося, або введи точний {0}.',+ 'All out, nothing left': 'На максимум, нічого не лишилося',+ 'Nearly all out': 'Майже на максимум',+ 'Very hard, one word at a time': 'Дуже важко, по одному слову',+ 'Hard, short sentences only': 'Важко, лише короткі речення',+ 'Working, but steady': 'Працюю, але рівно',+ 'Easy, you could chat the whole way': 'Легко, можна балакати всю дорогу',}diff --git a/frontend/src/locales/zh-TW.js b/frontend/src/locales/zh-TW.jsindex 9539c9f84..867b47afc 100644--- a/frontend/src/locales/zh-TW.js+++ b/frontend/src/locales/zh-TW.js@@ -2542,4 +2542,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': '已經到底了:{0} {1} 是最重的一檔,所以重量不變。','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': '手機上沒有代碼?只有連線至這個伺服器時才會有:設定 → 帳號 → 連線至我的伺服器。','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': '想在電腦上也登入,需要你自己的伺服器。把這支手機連線上去,然後「新增其他裝置」就會給電腦一組代碼。',+ 'How hard it felt': '感覺有多累',+ 'Not rated yet': '還沒評分',+ 'How hard did that feel?': '感覺有多累?',+ 'Tap how it felt, or type an exact {0}.': '點一下感覺,或輸入精確的 {0}。',+ 'All out, nothing left': '全力以赴,一點不剩',+ 'Nearly all out': '差不多全力',+ 'Very hard, one word at a time': '非常累,只能一個字一個字說',+ 'Hard, short sentences only': '累,只能說短句',+ 'Working, but steady': '有點吃力,但很穩',+ 'Easy, you could chat the whole way': '輕鬆,一路都能聊天',}diff --git a/frontend/src/locales/zh.js b/frontend/src/locales/zh.jsindex 8b21dcbcd..fe7cf3437 100644--- a/frontend/src/locales/zh.js+++ b/frontend/src/locales/zh.js@@ -2549,4 +2549,14 @@ export default {'That’s the whole stack: {0} {1} is the heaviest it goes, so the weight stays.': '已经到底了:{0} {1} 是最重的一档,所以重量不变。','No code on your phone? It only has one while it’s connected to this server: Settings → Account → Connect to my server.': '手机上没有代码?只有连接到这个服务器时才会有:设置 → 账号 → 连接到我的服务器。','Signing in on your computer too needs your own server. Connect this phone to it, and Add another device then gives the computer a code.': '想在电脑上也登录,需要你自己的服务器。把这部手机连接上去,然后“添加其他设备”就会给电脑一个代码。',+ 'How hard it felt': '感觉有多累',+ 'Not rated yet': '还没评分',+ 'How hard did that feel?': '感觉有多累?',+ 'Tap how it felt, or type an exact {0}.': '点一下感觉,或输入准确的 {0}。',+ 'All out, nothing left': '全力以赴,一点不剩',+ 'Nearly all out': '差不多全力',+ 'Very hard, one word at a time': '非常累,只能一个字一个字说',+ 'Hard, short sentences only': '累,只能说短句',+ 'Working, but steady': '有点吃力,但很稳',+ 'Easy, you could chat the whole way': '轻松,一路都能聊天',}diff --git a/frontend/src/sheets.effort-picker.test.jsx b/frontend/src/sheets.effort-picker.test.jsxindex 45511046f..528ff9435 100644--- a/frontend/src/sheets.effort-picker.test.jsx+++ b/frontend/src/sheets.effort-picker.test.jsx@@ -126,3 +126,31 @@ describe('the effort picker commits once', () => {expect(onPick).not.toHaveBeenCalled()})})++// Cardio (Discord thehypetrainhobo): the same bands in RPE, worded for a run, not for reps left.+describe('the effort picker for cardio', () => {+ it('talks about how it felt and logs RPE', () => {+ const onPick = vi.fn()+ effortPickerSheet('rpe', null, onPick, { cardio: true })+ const sheet = useUI.getState().sheets.at(-1)+ const host = document.createElement('div')+ document.body.appendChild(host)+ const root = createRoot(host)+ mounted.push(root)+ act(() => root.render(sheet.render(() => {})))+ expect(host.textContent).toContain('How hard did that feel?')+ expect(host.textContent).toContain('All out, nothing left')+ expect(host.textContent).toContain('Easy, you could chat the whole way')+ expect(host.textContent).not.toContain('reps')+ const rows = presetRows(host)+ expect(rows[0].textContent).toContain('10')+ tap(rows.at(-1))+ expect(onPick).toHaveBeenCalledWith(6)+ })++ it('a lift keeps its reps-left wording', () => {+ const p = openPicker('rir', null, vi.fn())+ expect(p.host.textContent).toContain('How hard was that set?')+ expect(p.host.textContent).toContain('Two more reps')+ })+})diff --git a/frontend/src/sheets.jsx b/frontend/src/sheets.jsxindex 4f5bd431d..3ffac1ddf 100644--- a/frontend/src/sheets.jsx+++ b/frontend/src/sheets.jsx@@ -2398,7 +2398,7 @@ export const glyphPicker = (current, onPick) => {// for the value between two presets. Presets are stored in RIR internally; a profile that logs// RPE sees the same buttons labelled on its own scale (toScale), coloured identically — the// colour is the effort, not the number, so 0 RIR and 10 RPE are both the "went to failure" end.-function EffortPicker({ kind, value, onPick, close }) {+function EffortPicker({ kind, value, onPick, close, cardio = false }) {// Local mirror so the ticked preset and the exact field track typing live.const [v, setV] = useState(value ?? null)// The exact field used to write through on every change, and onPick concludes the set (issue@@ -2427,8 +2427,8 @@ function EffortPicker({ kind, value, onPick, close }) {// as the row title, a tick on the current one. The exact field is the app's own stepper,// tinted like the logged cell in the set row, so the sheet and the row read as one thing.return <>- <h3 style={{ marginBottom: 2 }}>{t('How hard was that set?')}</h3>- <div className="muted small" style={{ marginBottom: 10 }}>{t('Tap how many reps you had left, or type an exact {0}.', hd)}</div>+ <h3 style={{ marginBottom: 2 }}>{cardio ? t('How hard did that feel?') : t('How hard was that set?')}</h3>+ <div className="muted small" style={{ marginBottom: 10 }}>{cardio ? t('Tap how it felt, or type an exact {0}.', hd) : t('Tap how many reps you had left, or type an exact {0}.', hd)}</div><div className="list menu-list effpick">{EFFORT_PRESETS.map(p => {const label = fmtNum(toScale(kind, p.rir)) + (p.tail ? '+' : '')@@ -2436,7 +2436,7 @@ function EffortPicker({ kind, value, onPick, close }) {return <div key={p.rir} className={'item menu-item' + (on ? ' on' : '')} style={{ '--bc': p.color }}{...tappable(() => pick(p.rir))}><span className="lrow-i effpick-n">{label}</span>- <div className="grow"><div className="tt">{t(p.feel)}</div></div>+ <div className="grow"><div className="tt">{t(cardio ? p.cardioFeel : p.feel)}</div></div><span className={'menu-on' + (on ? ' is-on' : '')}><Icon name="check" /></span></div>})}@@ -2463,9 +2463,10 @@ function EffortPicker({ kind, value, onPick, close }) {}// kind is 'rir' | 'rpe'; value is the set's current rating on that scale (or null); onPick// receives the new value on that same scale (null to clear). The caller stores it exactly as-// weight/reps are stored — a null drops the key rather than writing a zero.-export const effortPickerSheet = (kind, value, onPick) =>- ui().openSheet(close => <EffortPicker kind={kind} value={value} onPick={onPick} close={close} />)+// weight/reps are stored — a null drops the key rather than writing a zero. `cardio` words the+// presets for a run or a ride (the caller passes 'rpe' then: reps in reserve mean nothing there).+export const effortPickerSheet = (kind, value, onPick, { cardio = false } = {}) =>+ ui().openSheet(close => <EffortPicker kind={kind} value={value} onPick={onPick} close={close} cardio={cardio} />)/* ============================ share / print / import a plan ============================ */// What the Plan menu does with a plan: export it, print it, import a friend's.diff --git a/frontend/src/views/FocusView.jsx b/frontend/src/views/FocusView.jsxindex df9935f9f..0a927df1b 100644--- a/frontend/src/views/FocusView.jsx+++ b/frontend/src/views/FocusView.jsx@@ -251,6 +251,8 @@ export default function FocusView({{ icon: 'arrowDown', label: t('Add drop set'), onClick: () => onMutateSet(setIdx, row => addDropTo(row, entry.target)) },{ icon: 'bolt', label: t('Add burst'), onClick: () => onMutateSet(setIdx, row => addBurstTo(row, entry.target?.intensifier?.type === 'restpause' ? entry.target.intensifier.restSec : (S.restPauseSec || 15))) },!isWarmupRow(set) && mode !== 'cardio' && { icon: 'gauge', label: t('Taken to failure'), sub: t('Nothing left in the tank'), on: isFailureSet(set), onClick: () => onMutateSet(setIdx, toggleFailure) },+ // Cardio rates in RPE from here, as in the list's set menu (Workout.jsx): no column to spare.+ !isWarmupRow(set) && mode === 'cardio' && { icon: 'gauge', label: t('How hard it felt'), sub: set.rpe != null ? t(EFFORT.rpe.hd) + ' ' + fmtNum(set.rpe) : t('Not rated yet'), onClick: () => effortPickerSheet('rpe', set.rpe ?? null, value => onField(setIdx, 'rpe', value), { cardio: true }) },{ icon: 'trash', label: t('Delete set'), danger: true, disabled: entry.sets.length <= 1, onClick: () => onRemoveSetAt(setIdx) },],})diff --git a/frontend/src/views/Workout.jsx b/frontend/src/views/Workout.jsxindex 8bdbe75f8..909f87d55 100644--- a/frontend/src/views/Workout.jsx+++ b/frontend/src/views/Workout.jsx@@ -496,6 +496,10 @@ function ExerciseBlock({ entryIdx, compact, dense, editing, onToggle, onToggleSi// as RIR 0 wherever effort is read, unless a rating was logged on the set. A timed// per-side pair is one set, so both halves get it.!warm && mode !== 'cardio' && { icon: 'gauge', label: t('Taken to failure'), sub: t('Nothing left in the tank'), on: isFailureSet(s), onClick: () => toggleFailureAt(i) },+ // Cardio's effort lives here, not in a column (the third one is the incline): RPE only,+ // whatever the profile logs, since reps in reserve mean nothing on a treadmill. Stored as+ // `rpe` on the set, which the fatigue model already reads (recovery.js via rirOf).+ !warm && cardio && { icon: 'gauge', label: t('How hard it felt'), sub: s.rpe != null ? t(EFFORT.rpe.hd) + ' ' + fmtNum(s.rpe) : t('Not rated yet'), onClick: () => effortPickerSheet('rpe', s.rpe ?? null, nv => onField(i, 'rpe', nv), { cardio: true }) },// Just this set's rest, this session (#609): a long one before the top set, none after a light one.!editing && { icon: 'timer', label: t('Rest after this set'), sub: ownRestHere == null ? t('Default ({0})', fmtRest(setRestDefault(i))) : ownRestHere === 0 ? t('No timer') : fmtRest(ownRestHere), onClick: () => openSetRest(i) },] },diff --git a/frontend/src/views/Workout.test.jsx b/frontend/src/views/Workout.test.jsxindex e22aa2062..87fcdf7f9 100644--- a/frontend/src/views/Workout.test.jsx+++ b/frontend/src/views/Workout.test.jsx@@ -1864,6 +1864,21 @@ describe('workout focus view', () => {expect(mocks.S.active.entries[0].sets[0]).toMatchObject({ min: 21, speed: 8.5 })})+ it('rates a cardio set in RPE from the focus card\'s set menu', async () => {+ await mount([exercise('plain-treadmill', [false], {+ target: { mode: 'cardio', min: 20, speed: 8 },+ sets: [{ min: 20, speed: 8, done: false }],+ })], 0, { active: { workoutView: 'focus' } })+ await click(buttonNamed('Set menu'))+ const rate = mocks.menuSheet.mock.calls.at(-1)[0].items.filter(Boolean).find(item => item.label === 'How hard it felt')+ expect(rate.sub).toBe('Not rated yet')+ await act(async () => { rate.onClick() })+ const [scale, , onPick, opts] = mocks.effortPickerSheet.mock.calls.at(-1)+ expect([scale, opts]).toEqual(['rpe', { cardio: true }])+ await act(async () => { onPick(7.5) })+ expect(mocks.S.active.entries[0].sets[0].rpe).toBe(7.5)+ })+it('keeps drop and burst rows editable and opens every set action', async () => {await mount([exercise('plain-bench', [false], {sets: [{@@ -2960,6 +2975,39 @@ describe('workout controls: the more menu and the set menu', () => {expect(mocks.S.active.entries[0].sets.length).toBe(1)})+ // Cardio effort (Discord thehypetrainhobo): the third column stays the incline, so the rating+ // sits in the set menu, RPE only, and lands on the row as `rpe` for the fatigue model.+ it('rates a cardio row in RPE from its set menu, whatever the profile logs', async () => {+ await mount([exercise('plain-treadmill', [false], {+ target: { mode: 'cardio', min: 30, speed: 5 },+ sets: [{ min: 30, speed: 5, done: true }],+ })], 0, { effort: 'rir' })+ const openSet = async () => { await act(async () => { container.querySelector('button[aria-label="Set 1"]').dispatchEvent(new dom.Event('click', { bubbles: true })) }) }+ await openSet()+ expect(item('Taken to failure')).toBeUndefined()+ expect(item('How hard it felt').sub).toBe('Not rated yet')+ mocks.effortPickerSheet.mockClear()+ await act(async () => { item('How hard it felt').onClick() })+ const [scale, value, onPick, opts] = mocks.effortPickerSheet.mock.calls.at(-1)+ expect([scale, value, opts]).toEqual(['rpe', null, { cardio: true }])+ await act(async () => { onPick(6) })+ expect(mocks.S.active.entries[0].sets[0]).toMatchObject({ rpe: 6, done: true })+ expect('rir' in mocks.S.active.entries[0].sets[0]).toBe(false)+ await rerender()+ await openSet()+ expect(item('How hard it felt').sub).toBe('RPE 6')+ // Cleared, the key goes again.+ await act(async () => { item('How hard it felt').onClick() })+ await act(async () => { mocks.effortPickerSheet.mock.calls.at(-1)[2](null) })+ expect('rpe' in mocks.S.active.entries[0].sets[0]).toBe(false)+ })++ it('offers no effort row on a lift, where the column already does it', async () => {+ await mount([exercise('plain-bench', [false])])+ await act(async () => { container.querySelector('button[aria-label="Set 1"]').dispatchEvent(new dom.Event('click', { bubbles: true })) })+ expect(item('How hard it felt')).toBeUndefined()+ })+// #609: one set's rest, from its menu, this session only.it('gives one set its own rest: No timer, a picked time, and back to the default', async () => {await mount([exercise('ramped-squat', [false, false, false, false], {