Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Cristiang1021/ErgoKawsay/llms.txt

Use this file to discover all available pages before exploring further.

The Exercises module is ErgoKawsay’s full-body preventive movement library. It contains 18 targeted exercises organized into 8 body-zone categories, covering every area of the body that teachers strain during a typical school day. Each exercise launches its own guided Exercise Session Screen with a countdown timer, step-by-step instructions in Spanish or Kichwa, and automatic progress recording — all offline.

Exercise Categories

Cuello (Neck)

3 exercises targeting cervical rotation, flexion, and lateral tilt. Essential for teachers who write on the blackboard or look down at a desk for prolonged periods.

Hombros (Shoulders)

3 exercises for shoulder elevation, circles, and cross-arm stretch. Directly counters the fatigue from repeatedly raising both arms while writing on the board.

Manos (Hands)

3 exercises for finger extension, wrist rotation, and finger opposition. Targets the overuse patterns caused by typing, grading, and touchscreen use.

Espalda (Back)

2 exercises — spinal arch & round and trunk rotation — that relieve compression in the thoracic and lumbar spine from prolonged sitting or standing.

Caderas (Hips)

3 exercises including hip circles, lateral lunges, and standing hip flexion. Mobilizes the hip flexors that tighten from extended sitting between classes.

Piernas (Legs)

2 exercises — heel raises and ankle rotation — that activate the calf muscles and improve circulation in the lower limbs after prolonged standing.

Vista (Vision)

1 exercise: the 20-20-20 Rule. Every 20 minutes, look at an object 6 metres away for 20 seconds. Then blink several times to rehydrate the eyes. Relieves digital eye strain and dry-eye syndrome.

Respiración consciente (Breathing)

1 exercise: the 4-7-8 Technique. Sit comfortably, inhale for 4 s, hold for 7 s, exhale for 8 s. Repeat 4–6 cycles to reduce stress and tension. Session duration: 5 minutes (300 s).

Full Exercise List

All 18 exercises are defined as constants in LocalDataRepository.instance.exercises. The table below lists every exercise with its unique ID, category, name, and timed duration.
CategoryIDExercise Name (Spanish)Duration
Cuelloneck_1Rotación60 s
Cuelloneck_2Flexión anterior y posterior40 s
Cuelloneck_3Inclinación lateral30 s
Hombrosshoulders_1Elevación de hombros50 s
Hombrosshoulders_2Círculos de hombros45 s
Hombrosshoulders_3Estiramiento cruzado40 s
Manoshands_1Extensión de dedos40 s
Manoshands_2Rotación de muñecas35 s
Manoshands_3Oposición de dedos30 s
Espaldaback_1Arco y redondeo de columna60 s
Espaldaback_2Rotación de tronco45 s
Caderaships_1Círculos de cadera40 s
Caderaships_2Zancada lateral60 s
Caderaships_3Flexión de cadera de pie60 s
Piernaslegs_1Elevación de talones60 s
Piernaslegs_2Rotación de tobillos50 s
Vistavision_1Regla 20-20-2060 s
Respiración conscientebreathing_1Técnica 4-7-8300 s

Exercise of the Day

LocalDataRepository.instance.exerciseOfDay() selects a daily featured exercise by rotating through the full exercise list based on the current day of the month:
Exercise exerciseOfDay([DateTime? date]) {
  final list = exercises;
  final day = (date ?? DateTime.now()).day;
  return list[day % list.length];
}
This ensures every teacher sees a different exercise highlighted each day without any server calls or user data — a fully deterministic, offline-first feature. The exercise of the day is surfaced on the HomeScreen’s Today section. The selection uses day % list.length where day is the day-of-month integer (1–31).

Exercise Session Screen

Selecting any exercise from the category list opens ExerciseSessionScreen, which provides a complete guided session:
1

Timer Display

A large MM:SS countdown shows the remaining time. A linear progress bar fills as the session advances. When the session completes, the timer block transitions to a mint-green completion state.
2

Step-by-Step Instructions

Instructions are rendered as a numbered list sourced from the stepsEs or stepsQu fields of the Exercise model (language-dependent). For exercises without explicit steps, the descriptionEs / descriptionQu field is used as a single-step instruction.
3

Session Controls

Three actions are available: Start (begins the countdown), Pause / Resume (toggles mid-session), and Finish (marks complete early). All controls provide haptic feedback.
4

Completion Recording

When the timer reaches zero — or the teacher taps Finish — StorageServiceScope.of(context).recordExerciseCompleted() is called automatically. Completion data feeds into the Progress module (/progress).

Exercise Data Model

Each exercise is defined by the Exercise class:
class Exercise {
  final String id;              // Unique identifier (e.g. 'neck_1')
  final String categoryId;      // Parent category (e.g. 'neck')
  final String nameEs;          // Exercise name in Spanish
  final String nameQu;          // Exercise name in Kichwa
  final String descriptionEs;   // Short description in Spanish
  final String descriptionQu;   // Short description in Kichwa
  final int durationSeconds;    // Session timer length in seconds
  final String? imageAsset;     // Optional local image asset path
  final String? imageUrl;       // Optional remote image URL (unused offline)
  final String? videoUrl;       // Optional video URL (unused offline)
  final List<String>? stepsEs;  // Ordered step instructions in Spanish
  final List<String>? stepsQu;  // Ordered step instructions in Kichwa
}
The steps(bool isKichwa) method returns the appropriate language list, falling back to [description(isKichwa)] if no explicit steps are provided.

Screen Navigation

The Exercises module is registered as the /exercises route, accessible from the HomeScreen under the Today category. The category grid is rendered by ExercisesScreen. Tapping a category tile navigates to ExerciseListScreen for that category, and selecting an exercise opens ExerciseSessionScreen.
HomeScreen → /exercises → ExercisesScreen (8-category grid)
                              └── Category tile → ExerciseListScreen
                                                      └── Exercise card → ExerciseSessionScreen (timer + steps)

Build docs developers (and LLMs) love