Skip to content

Commit 802da6a

Browse files
committed
Don't use ExerciseBase anymore...
1 parent 396c98d commit 802da6a

File tree

4 files changed

+43
-45
lines changed

4 files changed

+43
-45
lines changed

lib/widgets/add_exercise/steps/step2variations.dart

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,7 @@ class Step2Variations extends StatelessWidget {
5858
),
5959
),
6060
// Exercise bases without variations
61-
...exerciseProvider.exercises
62-
.where((b) => b.variationId == null)
63-
.map(
61+
...exerciseProvider.exercises.where((b) => b.variationId == null).map(
6462
(base) => Row(
6563
mainAxisAlignment: MainAxisAlignment.spaceBetween,
6664
children: [

test_data/exercises.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ List<Exercise> getTestExerciseBases() {
214214
return [benchPress, crunches, deadLift, curls, squats, sideRaises];
215215
}
216216

217-
List<ExerciseBase> getScreenshotExercises() {
217+
List<Exercise> getScreenshotExercises() {
218218
benchPress.translations = benchPressTranslations;
219219
crunches.translations = crunchesTranslations;
220220
deadLift.translations = deadLiftTranslations;

test_data/screenshots_exercises.dart

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ final squatsPT = Translation(
9090
name: 'Agachamento de impulso',
9191
description:
9292
'''<p>Posição inicial:</p><p>Comece na posição de prancha alta:costas, braços e pernas retos e as mãos afastadas alinhadas aos ombros.</p><p>Passos:</p><ol><li>Pule jogando seus pés para frente entre os braços, mantendo as costas reta.</li><li>Mantendo suas mãos no chão, retorne suas pernas para a posição de prancha altas.</li><li>Repita.</li></ol>''',
93-
baseId: 616,
93+
exerciseId: 616,
9494
language: tLanguage7,
9595
);
9696

@@ -101,7 +101,7 @@ final squatsNL = Translation(
101101
name: 'Hurkstoten',
102102
description:
103103
'''<p>Startpositie:</p><p>Begin in hoge plankpositie:rug, armen en benen recht en handen op schouderbreedte uit elkaar.</p><p>Stap:</p><ol><li>Spring met je voeten naar voren tussen je armen en houd je rug plat.</li><li>Houd je handen op de vloer, spring je benen terug in hoge plank positie.</li><li>Herhalen.</li></ol>''',
104-
baseId: 616,
104+
exerciseId: 616,
105105
language: tLanguage6,
106106
);
107107

@@ -112,7 +112,7 @@ final squatsID = Translation(
112112
name: 'Jongkok menyodorkan',
113113
description:
114114
'''<p>Posisi awal:</p><p>Mulailah dengan posisi papan tinggi:punggung, lengan, dan kaki lurus dan tangan selebar bahu.</p><p>Langkah:</p><ol><li>Lompati kaki Anda ke depan di antara kedua lengan, jaga punggung tetap rata.</li><li>Menjaga tangan Anda di lantai, melompat kaki Anda kembali ke posisi papan tinggi.</li><li>Ulangi.</li></ol>''',
115-
baseId: 616,
115+
exerciseId: 616,
116116
language: tLanguage23,
117117
);
118118

@@ -123,7 +123,7 @@ final squatsDE = Translation(
123123
name: 'Kniebeugen',
124124
description:
125125
'''<p>Ausgangsposition:</p><p>Beginne in der hohen Plank-Position:Rücken, Arme und Beine sind gestreckt, die Hände sind schulterbreit auseinander.</p><p>Schritte:</p><ol><li>Springe mit den Füßen zwischen den Armen nach vorne und halte den Rücken flach.</li><li>Lasse die Hände auf dem Boden und springe mit den Beinen zurück in die hohe Plank-Position.</li><li>Wiederhole die Übung.</li></ol>''',
126-
baseId: 616,
126+
exerciseId: 616,
127127
language: tLanguage1,
128128
);
129129

@@ -133,7 +133,7 @@ final squatsFR = Translation(
133133
created: DateTime(2021, 1, 15),
134134
name: 'Poussées de squat',
135135
description: '''''',
136-
baseId: 616,
136+
exerciseId: 616,
137137
language: tLanguage12,
138138
);
139139

@@ -144,7 +144,7 @@ final squatsIT = Translation(
144144
name: 'Spinte squat',
145145
description:
146146
'''<p>Posizione di partenza:</p><p>Iniziare in posizione di plank alto:schiena, braccia e gambe dritte e mani alla larghezza delle spalle.</p><p>Passi:</p><ol><li>Saltare i piedi in avanti tra le braccia, mantenendo la schiena piatta.</li><li>Tenendo le mani sul pavimento, saltare le gambe indietro in posizione di plank alto.</li><li>Ripetere.</li></ol>''',
147-
baseId: 616,
147+
exerciseId: 616,
148148
language: tLanguage13,
149149
);
150150

@@ -155,7 +155,7 @@ final squatsEN = Translation(
155155
name: 'Squat Thrust',
156156
description:
157157
'''The burpee, or squat thrust, is a full body exercise used in strength training and as an aerobic exercise. The basic movement is performed in four steps and known as a four-count burpee: Begin in a standing position. Move into a squat position with your hands on the ground. (count 1) Kick your feet back into a plank position, while keeping your arms extended. (count 2) Immediately return your feet into squat position. (count 3) Stand up from the squat position (count 4)''',
158-
baseId: 616,
158+
exerciseId: 616,
159159
language: tLanguage2,
160160
);
161161

@@ -166,7 +166,7 @@ final squatsEL = Translation(
166166
name: 'Ωθήσεις βαθέος καθίσματος',
167167
description:
168168
'''<p>Θέση εκκίνησης:</p><p>Εκκίνηση σε θέση υψηλής σανίδας:πλάτη, χέρια και πόδια είναι ίσια, και τα χέρια βρίσκονται στο πλάτος των ώμων.</p><p>Βήματα:</p><ol><li>Πηδήξτε με τα πόδια προς τα εμπρός ανάμεσα στα χέρια, κρατώντας την πλάτη επίπεδη.</li><li>Διατηρώντας τα χέρια στο πάτωμα, πηδήξτε με τα πόδια σας πίσω σε θέση υψηλής σανίδας.</li><li>Επαναλάβετε.</li></ol>''',
169-
baseId: 616,
169+
exerciseId: 616,
170170
language: tLanguage8,
171171
);
172172

@@ -177,7 +177,7 @@ final squatsAR = Translation(
177177
name: 'دفعات القرفصاء',
178178
description:
179179
'''<p>وضع البداية:</p><p>ابدأ في وضع اللوح الخشبي المرتفع:الظهر والذراعين والساقين مستقيمين واليدين متباعدتين بعرض الكتفين.</p><p>الخطوات:</p><ol><li>اقفز قدميك للأمام بين ذراعيك ، مع الحفاظ على ظهرك مسطحًا.</li><li>إبقاء يديك على الأرض ، واقفز رجليك إلى الوراء في وضع اللوح الخشبي العالي.</li><li>كرر.</li></ol>''',
180-
baseId: 616,
180+
exerciseId: 616,
181181
language: tLanguage17,
182182
);
183183

@@ -188,7 +188,7 @@ final squatsZH = Translation(
188188
name: '俯卧撑腿屈伸',
189189
description:
190190
'''<p>起始姿势:以高位平板支撑姿势开始:背部、手臂和腿均伸直,双手分开与肩同宽。</p><p>步骤:</p><ol><li>双脚向双臂的方向向前跳,保持背部平直。</li><li>双手撑地,双腿跳回高位平板支撑位置。</li><li>重复。</li></ol>''',
191-
baseId: 616,
191+
exerciseId: 616,
192192
language: tLanguage24,
193193
);
194194

@@ -218,7 +218,7 @@ final benchPressDE = Translation(
218218
<li>breiter Griff: äußere Brustmuskeln</li>
219219
<li>enger Griff: innere Brustmuskeln und Trizeps</li>
220220
</ul>''',
221-
baseId: 73,
221+
exerciseId: 73,
222222
language: tLanguage1,
223223
);
224224

@@ -235,7 +235,7 @@ final benchPressEN = Translation(
235235
<li>wide grip: outer chest muscles</li>
236236
<li>narrow grip: inner chest muscles and triceps</li>
237237
</ul>''',
238-
baseId: 73,
238+
exerciseId: 73,
239239
language: tLanguage2,
240240
);
241241

@@ -245,7 +245,7 @@ final benchPressIT = Translation(
245245
created: DateTime(2021, 1, 15),
246246
name: 'Distensione Panca Piana con Bilanciere',
247247
description: '''Distensione Panca Piana con BilanciereDistensione Panca Piana con Bilanciere''',
248-
baseId: 73,
248+
exerciseId: 73,
249249
language: tLanguage13,
250250
);
251251

@@ -259,7 +259,7 @@ final deadLiftEN = Translation(
259259
description:
260260
'''<p>Stand firmly, with your feet slightly more than shoulder wide apart. Stand directly behind the bar where it should barely touch your shin, your feet pointing a bit out. Bend down with a straight back, the knees also pointing somewhat out. Grab the bar with a shoulder wide grip, one underhand, one reverse grip.</p>
261261
<p>Pull the weight up. At the highest point make a slight hollow back and pull the bar back. Hold 1 or 2 seconds that position. Go down, making sure the back is not bent. Once down you can either go back again as soon as the weights touch the floor, or make a pause, depending on the weight.</p>''',
262-
baseId: 184,
262+
exerciseId: 184,
263263
language: tLanguage2,
264264
);
265265

@@ -271,7 +271,7 @@ final deadLiftDE = Translation(
271271
description:
272272
'''<p>Stelle dich mit etwas mehr als schulterbreitem Stand vor der Stange, die Füße zeigen leicht nach außen, die Stange ist direkt darüber und sehr nahe am Schienbein. Beuge die Knie (zeigen ebenfalls etwas nach außen) und neige den Oberkörper (bleibt während der ganzen Übung gerade). Greife die Stange schulterbreit mit einem Unter- und einem Obergriff.</p>
273273
<p>Ziehe nun die Stange nach oben. An der höchsten Stelle mache ein leichtes Hohlkreuz und drücke die Schultern nach hinten. Gehe wieder runter, wobei du darauf achtest, dass der Rücken gerade bleibt und sich nicht krümmt. Du kannst unten angekommen eine kleine Pause einlegen oder sofort weitermachen.</p>''',
274-
baseId: 184,
274+
exerciseId: 184,
275275
language: tLanguage1,
276276
);
277277

@@ -284,7 +284,7 @@ final deadLiftPT = Translation(
284284
'''Fique firme, com os pés ligeiramente mais afastados do que os ombros. Fique diretamente atrás da barra, onde ela mal deve tocar sua canela, com os pés apontando um pouco para fora. Curve-se com as costas retas, os joelhos também apontando um pouco para fora. Agarre a barra com uma pegada na largura dos ombros, uma pegada por baixo e uma pegada reversa.
285285
286286
Puxe o peso para cima. No ponto mais alto, faça uma leve depressão para trás e puxe a barra para trás. Segure 1 ou 2 segundos nessa posição. Desça, certificando-se de que as costas não estão dobradas. Depois de descer, você pode voltar assim que os pesos tocarem o chão ou fazer uma pausa, dependendo do peso.''',
287-
baseId: 184,
287+
exerciseId: 184,
288288
language: tLanguage7,
289289
);
290290

@@ -295,7 +295,7 @@ final deadLiftIT = Translation(
295295
name: 'Stacco',
296296
description: '''StaccoStacco
297297
Stacco''',
298-
baseId: 184,
298+
exerciseId: 184,
299299
language: tLanguage13,
300300
);
301301

@@ -308,7 +308,7 @@ final crunchesPT = Translation(
308308
name: 'Abdominal',
309309
description:
310310
'''<ol><li>Deite-se de barriga para cima no chão com os joelhos dobrados.</li><li>Curve os ombros em direção a pélvis. As mãos podem ficar atrás ou do lado do pescoço ou cruzadas sobre o peito.</li><li>Repita</li></ol>''',
311-
baseId: 167,
311+
exerciseId: 167,
312312
language: tLanguage7,
313313
);
314314

@@ -319,7 +319,7 @@ final crunchesES = Translation(
319319
name: 'Abdominales',
320320
description:
321321
'''<ol><li>Acuéstese boca arriba en el suelo con las rodillas dobladas.</li><li>Flexione los hombros hacia la pelvis. Las manos pueden estar detrás o al costado del cuello o cruzadas sobre el pecho.</li><li>Repita</li></ol>''',
322-
baseId: 167,
322+
exerciseId: 167,
323323
language: tLanguage4,
324324
);
325325

@@ -330,7 +330,7 @@ final crunchesFR = Translation(
330330
name: 'Abdominaux',
331331
description:
332332
'''<ol><li>Allongez-vous sur le sol, face contre terre, genoux pliés.</li><li>Courbez les épaules vers le bassin. Les mains peuvent être derrière ou à côté du cou ou croisées sur la poitrine.</li><li>Répétez</li></ol>''',
333-
baseId: 167,
333+
exerciseId: 167,
334334
language: tLanguage12,
335335
);
336336

@@ -341,7 +341,7 @@ final crunchesIT = Translation(
341341
name: 'Addominali',
342342
description:
343343
'''<ol><li>Sdraiati a pancia in su sul pavimento con le ginocchia piegate.</li><li>Solleva il busto verso il bacino, a 30° / 40° dal suolo. Le mani possono essere dietro o accanto al collo o incrociate sul petto.</li><li>Ripeti</li></ol>''',
344-
baseId: 167,
344+
exerciseId: 167,
345345
language: tLanguage13,
346346
);
347347

@@ -352,7 +352,7 @@ final crunchesNL = Translation(
352352
name: 'Crunch',
353353
description:
354354
'''<ol><li>Ga op je rug liggen en buig je knieën.</li><li>Draai je schouders richting je bekken. Houd je handen achter of naast je nek of kruislings over je borstkas.</li><li>Herhaal</li></ol>''',
355-
baseId: 167,
355+
exerciseId: 167,
356356
language: tLanguage6,
357357
);
358358

@@ -363,7 +363,7 @@ final crunchesID = Translation(
363363
name: 'Crunch',
364364
description:
365365
'''<ol><li>Tiarap di lantai dengan lutut bengkok.</li><li>Ikatkan bahumu ke pinggulnya. Tangan bisa berada di belakang atau di samping leher atau menyeberang di atas dada.</li><li>Ulangi</li></ol>''',
366-
baseId: 167,
366+
exerciseId: 167,
367367
language: tLanguage23,
368368
);
369369

@@ -375,7 +375,7 @@ final crunchesDE = Translation(
375375
description:
376376
'''<p>Lege dich auf eine Matte mit angewinkelten Beinen. Die Füße werden irgendwie festgehalten (Partner, Lanhghantel, o.Ä.) und die Hände werden hinter dem Nacken verschränkt. Aus dieser Position führe den Oberkörper so weit nach oben, bis Kopf oder Ellenbogen die angewinkelten Beine berühren.</p>
377377
<p>Es ist wichtig, dass dieser Vorgang mit einer rollenden Bewegung durchgeführt wird: die Wirbelsäule sollte sich Wirbel für Wirbel von der Matte lösen. Ein Hohlkreuz ist stets zu vermeiden.</p>''',
378-
baseId: 167,
378+
exerciseId: 167,
379379
language: tLanguage1,
380380
);
381381

@@ -386,7 +386,7 @@ final crunchesEN = Translation(
386386
name: 'Crunches',
387387
description:
388388
'''<p>Lay down on your back a soft surface, the feet are on the floor. Ask a partner or use some other help (barbell, etc.) to keep them fixed, your hands are behind your head. From this position move your upper body up till your head or elbows touch your knees. Do this movement by rolling up your back.</p>''',
389-
baseId: 167,
389+
exerciseId: 167,
390390
language: tLanguage2,
391391
);
392392

@@ -397,7 +397,7 @@ final crunchesCS = Translation(
397397
name: 'Sedolehy',
398398
description:
399399
'''<ol><li>Lehni si na zem hlavou nahoru s pokrčenými koleny.Zvedni záda tak, aby se tvá ramena co nejblíže přiblížily ke kolenům. Plosky nohou včetně prstů by měly zůstat na zemi. Ruce mohou být za hlavou nebo přeložené v kříž na hrudi.</li><li>Opakuj</li></ol>''',
400-
baseId: 167,
400+
exerciseId: 167,
401401
language: tLanguage9,
402402
);
403403

@@ -407,7 +407,7 @@ final crunchesHR = Translation(
407407
created: DateTime(2021, 1, 15),
408408
name: 'Trbušnjaci',
409409
description: '''''',
410-
baseId: 167,
410+
exerciseId: 167,
411411
language: tLanguage22,
412412
);
413413

@@ -418,7 +418,7 @@ final crunchesTR = Translation(
418418
name: 'Yarım mekik',
419419
description:
420420
'''<ol><li>Dizlerinizi bükerek yere sırtüstü yatın.</li><li>Omuzları leğen kemiğine doğru bükün. Eller boynun arkasında veya yanında olabilir ya da göğsün üzerinden geçebilir.</li><li>Tekrarlayın</li></ol>''',
421-
baseId: 167,
421+
exerciseId: 167,
422422
language: tLanguage16,
423423
);
424424

@@ -429,7 +429,7 @@ final crunchesEL = Translation(
429429
name: 'Κοιλιακοί',
430430
description:
431431
'''<ol><li>Ξαπλώστε ανάσκελα στο πάτωμα με τα γόνατα λυγισμένα.</li><li>Κυρτώστε τους ώμους προς τη λεκάνη. Τα χέρια μπορεί να είναι πίσω ή δίπλα από τον αυχένα ή σταυρωμένα πάνω από το στήθος.</li><li>Επαναλάβετε</li></ol>''',
432-
baseId: 167,
432+
exerciseId: 167,
433433
language: tLanguage8,
434434
);
435435

@@ -439,7 +439,7 @@ final crunchesRU = Translation(
439439
created: DateTime(2021, 1, 15),
440440
name: 'Скручивания',
441441
description: '''''',
442-
baseId: 167,
442+
exerciseId: 167,
443443
language: tLanguage5,
444444
);
445445

@@ -449,7 +449,7 @@ final crunchesHE = Translation(
449449
created: DateTime(2021, 1, 15),
450450
name: 'כפיפות בטן',
451451
description: '''''',
452-
baseId: 167,
452+
exerciseId: 167,
453453
language: tLanguage21,
454454
);
455455

@@ -460,7 +460,7 @@ final crunchesAR = Translation(
460460
name: 'الطحن',
461461
description:
462462
'''<ol><li>الاستلقاء على الأرض مع ثني الركبتين.</li><li>لف الكتفين نحو الحوض. يمكن أن تكون اليدين خلف العنق أو بجانبه أو متقاطعتين فوق الصدر.</li><li>كرر التمرين</li></ol>''',
463-
baseId: 167,
463+
exerciseId: 167,
464464
language: tLanguage17,
465465
);
466466

@@ -471,7 +471,7 @@ final crunchesZH = Translation(
471471
name: '仰卧起坐',
472472
description:
473473
'''<p>起始姿势:膝盖弯曲,脸朝上躺在地板上。</p><p>步骤:</p><ol><li>朝骨盆方向弯曲肩膀。 双手可以放在脖子后面或脖子旁边,也可以交叉在胸前。2.回到初始姿势。</li><li>重复。</li></ol>''',
474-
baseId: 167,
474+
exerciseId: 167,
475475
language: tLanguage24,
476476
);
477477

@@ -502,7 +502,7 @@ final curlsEN = Translation(
502502
description:
503503
'''<p>Hold two barbells, the arms are streched, the hands are on your side, the palms face inwards. Bend the arms and bring the weight with a fast movement up. At the same time, rotate your arms by 90 degrees at the very beginning of the movement. At the highest point, rotate a little the weights further outwards. Without a pause, bring them down, slowly.</p>
504504
<p>Don't allow your body to swing during the exercise, all work is done by the biceps, which are the only mucles that should move (pay attention to the elbows).</p>''',
505-
baseId: 92,
505+
exerciseId: 92,
506506
language: tLanguage2,
507507
);
508508

@@ -514,7 +514,7 @@ final curlsDE = Translation(
514514
description:
515515
'''<p>Halte zwei Kurzhantel mit ausgestreckten Armen neben dem Körper, die Handflächen zeigen nach innen. Beuge die Arme und brige die Hanteln mit einer schnellen Bewegung nach oben wobei sie gleichzeitig um 90 Grad gedreht werden. Am höchsten Punkt kann man die Hanteln ganz leicht weiter nach außen drehen. Ohne Pause wird das Gewicht nun kontrolliert nach unten gebracht. Beachte, dass die Bewegung nach oben schneller ist als nach unten.</p>
516516
<p>Während des Bewegungablaufs darf der Körper nicht mitschwingen. Die Ellenbogen bleiben dabei immer an der Stelle.</p>''',
517-
baseId: 92,
517+
exerciseId: 92,
518518
language: tLanguage1,
519519
);
520520

@@ -525,7 +525,7 @@ final curlsES = Translation(
525525
name: 'Curl de bíceps con mancuerna',
526526
description:
527527
'''Sujeta dos pesas, los brazos estirados, las manos a los lados, las palmas hacia dentro. Flexiona los brazos y sube el peso con un movimiento rápido. Al mismo tiempo, gira los brazos 90 grados al principio del movimiento. En el punto más alto, gira un poco las pesas hacia fuera. Sin pausa, bájalas lentamente.No permitas que tu cuerpo se balancee durante el ejercicio, todo el trabajo lo realizan los bíceps, que son los únicos músculos que deben moverse (presta atención a los codos).''',
528-
baseId: 92,
528+
exerciseId: 92,
529529
language: tLanguage4,
530530
);
531531

@@ -537,7 +537,7 @@ final raisesIT = Translation(
537537
created: DateTime(2021, 1, 15),
538538
name: 'Alzate Laterali',
539539
description: '''Alzate LateraliAlzate Laterali''',
540-
baseId: 348,
540+
exerciseId: 348,
541541
language: tLanguage13,
542542
);
543543

@@ -548,7 +548,7 @@ final raisesEN = Translation(
548548
name: 'Lateral Raises',
549549
description:
550550
'''This exercise works the deltoid muscle of the shoulder. The movement starts with the arms straight, and the hands holding weights at the sides or in front of the body. Body is in a slight forward-leaning position with hips and knees bent a little. Arms are kept straight or slightly bent, and raised through an arc of movement in the coronal plane that terminates when the hands are at approximately shoulder height. Weights are lowered to the starting position, completing one rep. When using a cable machine the individual stands with the coronal plane in line with the pulley, which is at or near the ground.[9] The exercise can be completed one shoulder at a time (with the other hand used to stabilize the body against the weight moved), or with both hands simultaneously if two parallel pulleys are available.''',
551-
baseId: 348,
551+
exerciseId: 348,
552552
language: tLanguage2,
553553
);
554554

@@ -565,7 +565,7 @@ final raisesDE = Translation(
565565
<li>Am höchsten Punkt hältst du für 1-2 Sekunden inne und ziehst deine Schulterblätter zusammen.</li>
566566
<li>Führe die Hanteln langsam wieder nach unten in die Ausgangsposition und atme ein.</li>
567567
</ol>''',
568-
baseId: 348,
568+
exerciseId: 348,
569569
language: tLanguage1,
570570
);
571571

0 commit comments

Comments
 (0)