Commit Graph

37 Commits

Author SHA1 Message Date
Roland Geider
c411e8949a Consolidate time and date picking logic into their own widgets
This makes it easier to fix things like localization, etc. in one place
2026-05-20 23:59:14 +02:00
Roland Geider
130232ead8 Remove null assertions where not needed 2026-05-08 10:58:40 +02:00
Roland Geider
395eb58cbd Merge remote-tracking branch 'origin/master' into feature/offline-mode 2026-05-07 14:16:58 +02:00
Roland Geider
c93f03fa0b Replace pumpAndSettle with pump where possible 2026-05-07 12:27:33 +02:00
Roland Geider
1249036cce Properly update routine data
Since this happens in the backend only, we need to refetch everything, when
the user edits one of the routine's models
2026-05-03 12:17:23 +02:00
Roland Geider
c1dccbd822 Make the "impression" in workout session an enum
This is cleaner and simplifies a handful of places
2026-05-03 12:17:23 +02:00
Roland Geider
2cb40612b1 Cleanup providers and use consistent naming 2026-05-01 16:58:08 +02:00
Roland Geider
5d30a1ca79 Cleanup providers and use consistent naming 2026-05-01 16:50:15 +02:00
Roland Geider
16ffafeb28 Remove unused methods 2026-05-01 15:36:15 +02:00
Roland Geider
c5dbcc27ef Extract routines repository to its own file 2026-04-29 10:56:17 +02:00
Roland Geider
680127e139 Sync the base Routine and Nutritional plan entries via powersync
This makes sure the lists is always kept current and allows the user to edit
them offline as well. Note that we still kepp the backend's ID here, so no
creation is possible.
2026-04-29 10:03:59 +02:00
Roland Geider
af378dfdb3 Make the routines provider async
This makes the behaviour consistent with the others
2026-04-18 17:40:45 +02:00
Roland Geider
6dea8d5e8f Merge branch 'master' into feature/offline-mode 2026-04-17 12:32:11 +02:00
Roland Geider
9c531a7799 Merge branch 'master' into feature/offline-mode
# Conflicts:
#	integration_test/1_dashboard.dart
#	integration_test/3_gym_mode.dart
#	ios/Podfile.lock
#	lib/database/exercises/exercise_database.dart
#	lib/database/exercises/type_converters.dart
#	lib/models/exercises/exercise.dart
#	lib/models/exercises/exercise.g.dart
#	lib/models/exercises/exercise_api.dart
#	lib/models/exercises/exercise_api.freezed.dart
#	lib/models/exercises/exercise_api.g.dart
#	lib/models/exercises/translation.dart
#	lib/models/exercises/translation.g.dart
#	lib/models/exercises/variation.dart
#	lib/providers/exercises.dart
#	lib/widgets/add_exercise/steps/step_1_basics.dart
#	lib/widgets/add_exercise/steps/step_2_variations.dart
#	lib/widgets/exercises/exercises.dart
#	lib/widgets/measurements/forms.dart
#	lib/widgets/routines/forms/slot.dart
#	pubspec.lock
#	pubspec.yaml
#	test/core/settings_test.mocks.dart
#	test/exercises/contribute_exercise_image_test.mocks.dart
#	test/exercises/contribute_exercise_test.mocks.dart
#	test/exercises/exercise_provider_load_test.dart
#	test/exercises/exercise_provider_test.dart
#	test/exercises/exercises_detail_widget_test.dart
#	test/exercises/exercises_detail_widget_test.mocks.dart
#	test/exercises/model_exercise_test.dart
#	test/measurements/measurement_entries_screen_test.dart
#	test/routine/gym_mode/gym_mode_test.dart
#	test/routine/gym_mode/gym_mode_test.mocks.dart
#	test/routine/routines_provider_test.mocks.dart
#	test/weight/weight_screen_test.mocks.dart
#	test/widgets/routines/gym_mode/log_page_test.mocks.dart
#	test_data/measurements.dart
2026-04-17 12:23:56 +02:00
Roland Geider
9971acbe5f Use correct mock file 2026-04-10 10:12:28 +02:00
Roland Geider
85b261fad7 Group slots in the UI with the same exercise
This allows the user to add different slots (sets) to an exercise, like
10 x 10kg, 8 x 12kg, 6 x 15kg. Also note that this is purely a UI change,
as it was already possible to simply add the same exercise again.
2026-03-29 20:46:13 +02:00
Roland Geider
077dcaf742 Handle HTML errors in WgerHttpException
These need to be handled separately when the server encounters an error and
returns HTML instead of JSON.
2025-12-17 18:59:45 +01:00
Roland Geider
e639709d24 Recreate generated files 2025-12-02 13:16:53 +01:00
Roland Geider
ecd0b6c6b4 Add overview page when a workout has been completed 2025-11-26 20:17:02 +01:00
Roland Geider
ae6db6ee07 Move to riverpod three
Needed to downgrade build_runner and mockito for now
2025-11-11 13:22:18 +01:00
Roland Geider
4a2047ec8b Edit sessions with the new sessions provider 2025-11-08 17:15:17 +01:00
Roland Geider
aafd464fbe Fix tests 2025-11-07 15:45:13 +01:00
Roland Geider
2132249682 Wrap the routines provider
This makes it easier to load the data from the powersync database
2025-11-07 15:10:04 +01:00
Roland Geider
5912cea664 Fix some tests 2025-11-04 15:23:55 +01:00
Roland Geider
a368fe2f79 Pass the exercises and workout units as parameters
If the routine provider is rewritten to be a riverpod provider as well,
we will be able to simply read the necessary providers ourselves as needed.
2025-11-04 14:25:25 +01:00
Roland Geider
c60cfbe347 Add tables for workout sessions 2025-10-26 18:18:22 +01:00
Roland Geider
8b8c4626eb Powersync seems to be working now 2025-10-23 15:32:21 +02:00
Roland Geider
017cccab18 Start adding drift and using riverpod 2025-10-22 20:49:38 +02:00
Roland Geider
4d2083f05a Update body weight provider to use riverpod 2025-10-21 12:04:59 +02:00
Roland Geider
93a11a16e4 Recreate generated files and reformat the repo
Seems the default dart formatting rules changed recently, and this was causing
huge diffs in branches
2025-10-09 17:39:02 +02:00
Roland Geider
fa7f670e9f Some light cleanup 2025-10-06 12:31:12 +02:00
Roland Geider
798406eaa9 Make routineId nullable in session and related files
Sessions can be added ad-hoc, without needing to be part of any specific
routine.
2025-09-16 14:47:47 +02:00
Roland Geider
4330e51f86 Retrieve the current routine dynamically
This behaviour is now the same as the nutritional plans.
2025-09-05 22:47:27 +02:00
Roland Geider
a853e45107 Optimize fetching exercises from the server
This might be the reason behind wger-project/wger#2028 since depending on the routine
the server could get hammered with requests and one (or other unrelated ones) fail.
Even if this is not the case, being a bit more reserved here is still a good idea.
2025-08-27 18:52:54 +02:00
Roland Geider
8ae889a1ea Improve decimal input handling
We now use TextInputType.numberWithOptions(decimal: true) which seems to have
a more consistent behaviour under android and iOS. Also, we now use NumberFormat
to parse the inputs according to the user's locale.
2025-06-27 13:24:53 +02:00
Roland Geider
d2dd9c144d Fix some paths and recreate generated files 2025-05-16 18:01:30 +02:00
Roland Geider
1613b9b91a Rename test folder
We're now using "routine" throughout the application
2025-05-16 17:47:36 +02:00