@aneuhold/core-ts-db-lib 4.0.4 → 4.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (140) hide show
  1. package/CHANGELOG.md +22 -1
  2. package/lib/browser.d.ts +36 -4
  3. package/lib/browser.d.ts.map +1 -1
  4. package/lib/browser.js +23 -2
  5. package/lib/browser.js.map +1 -1
  6. package/lib/browser.ts +126 -4
  7. package/lib/documents/BaseDocument.d.ts +8 -0
  8. package/lib/documents/BaseDocument.d.ts.map +1 -1
  9. package/lib/documents/BaseDocument.js +10 -0
  10. package/lib/documents/BaseDocument.js.map +1 -1
  11. package/lib/documents/BaseDocument.ts +18 -0
  12. package/lib/documents/common/User.d.ts +1 -0
  13. package/lib/documents/common/User.d.ts.map +1 -1
  14. package/lib/documents/common/User.js +4 -2
  15. package/lib/documents/common/User.js.map +1 -1
  16. package/lib/documents/common/User.ts +4 -2
  17. package/lib/documents/dashboard/NonogramKatanaItem.d.ts +1 -1
  18. package/lib/documents/dashboard/NonogramKatanaItem.js +1 -1
  19. package/lib/documents/dashboard/NonogramKatanaItem.js.map +1 -1
  20. package/lib/documents/dashboard/NonogramKatanaItem.ts +1 -1
  21. package/lib/documents/dashboard/NonogramKatanaUpgrade.d.ts +1 -1
  22. package/lib/documents/dashboard/NonogramKatanaUpgrade.js +1 -1
  23. package/lib/documents/dashboard/NonogramKatanaUpgrade.js.map +1 -1
  24. package/lib/documents/dashboard/NonogramKatanaUpgrade.ts +1 -1
  25. package/lib/documents/workout/README.md +557 -0
  26. package/lib/documents/workout/WorkoutEquipmentType.d.ts +22 -0
  27. package/lib/documents/workout/WorkoutEquipmentType.d.ts.map +1 -0
  28. package/lib/documents/workout/WorkoutEquipmentType.js +31 -0
  29. package/lib/documents/workout/WorkoutEquipmentType.js.map +1 -0
  30. package/lib/documents/workout/WorkoutEquipmentType.ts +40 -0
  31. package/lib/documents/workout/WorkoutExercise.d.ts +82 -0
  32. package/lib/documents/workout/WorkoutExercise.d.ts.map +1 -0
  33. package/lib/documents/workout/WorkoutExercise.js +124 -0
  34. package/lib/documents/workout/WorkoutExercise.js.map +1 -0
  35. package/lib/documents/workout/WorkoutExercise.ts +143 -0
  36. package/lib/documents/workout/WorkoutExerciseCalibration.d.ts +43 -0
  37. package/lib/documents/workout/WorkoutExerciseCalibration.d.ts.map +1 -0
  38. package/lib/documents/workout/WorkoutExerciseCalibration.js +45 -0
  39. package/lib/documents/workout/WorkoutExerciseCalibration.js.map +1 -0
  40. package/lib/documents/workout/WorkoutExerciseCalibration.ts +74 -0
  41. package/lib/documents/workout/WorkoutMesocycle.d.ts +49 -0
  42. package/lib/documents/workout/WorkoutMesocycle.d.ts.map +1 -0
  43. package/lib/documents/workout/WorkoutMesocycle.js +84 -0
  44. package/lib/documents/workout/WorkoutMesocycle.js.map +1 -0
  45. package/lib/documents/workout/WorkoutMesocycle.ts +102 -0
  46. package/lib/documents/workout/WorkoutMicrocycle.d.ts +27 -0
  47. package/lib/documents/workout/WorkoutMicrocycle.d.ts.map +1 -0
  48. package/lib/documents/workout/WorkoutMicrocycle.js +42 -0
  49. package/lib/documents/workout/WorkoutMicrocycle.js.map +1 -0
  50. package/lib/documents/workout/WorkoutMicrocycle.ts +55 -0
  51. package/lib/documents/workout/WorkoutMuscleGroup.d.ts +22 -0
  52. package/lib/documents/workout/WorkoutMuscleGroup.d.ts.map +1 -0
  53. package/lib/documents/workout/WorkoutMuscleGroup.js +25 -0
  54. package/lib/documents/workout/WorkoutMuscleGroup.js.map +1 -0
  55. package/lib/documents/workout/WorkoutMuscleGroup.ts +34 -0
  56. package/lib/documents/workout/WorkoutSession.d.ts +39 -0
  57. package/lib/documents/workout/WorkoutSession.d.ts.map +1 -0
  58. package/lib/documents/workout/WorkoutSession.js +66 -0
  59. package/lib/documents/workout/WorkoutSession.js.map +1 -0
  60. package/lib/documents/workout/WorkoutSession.ts +79 -0
  61. package/lib/documents/workout/WorkoutSessionExercise.d.ts +39 -0
  62. package/lib/documents/workout/WorkoutSessionExercise.d.ts.map +1 -0
  63. package/lib/documents/workout/WorkoutSessionExercise.js +66 -0
  64. package/lib/documents/workout/WorkoutSessionExercise.js.map +1 -0
  65. package/lib/documents/workout/WorkoutSessionExercise.ts +79 -0
  66. package/lib/documents/workout/WorkoutSet.d.ts +41 -0
  67. package/lib/documents/workout/WorkoutSet.d.ts.map +1 -0
  68. package/lib/documents/workout/WorkoutSet.js +69 -0
  69. package/lib/documents/workout/WorkoutSet.js.map +1 -0
  70. package/lib/documents/workout/WorkoutSet.ts +90 -0
  71. package/lib/embedded-types/workout/Fatigue.d.ts +16 -0
  72. package/lib/embedded-types/workout/Fatigue.d.ts.map +1 -0
  73. package/lib/embedded-types/workout/Fatigue.js +34 -0
  74. package/lib/embedded-types/workout/Fatigue.js.map +1 -0
  75. package/lib/embedded-types/workout/Fatigue.ts +41 -0
  76. package/lib/embedded-types/workout/Rsm.d.ts +17 -0
  77. package/lib/embedded-types/workout/Rsm.d.ts.map +1 -0
  78. package/lib/embedded-types/workout/Rsm.js +34 -0
  79. package/lib/embedded-types/workout/Rsm.js.map +1 -0
  80. package/lib/embedded-types/workout/Rsm.ts +42 -0
  81. package/lib/services/DocumentService.d.ts +19 -0
  82. package/lib/services/DocumentService.d.ts.map +1 -1
  83. package/lib/services/DocumentService.js.map +1 -1
  84. package/lib/services/DocumentService.ts +20 -0
  85. package/lib/services/workout/EquipmentType/WorkoutEquipmentTypeService.d.ts +35 -0
  86. package/lib/services/workout/EquipmentType/WorkoutEquipmentTypeService.d.ts.map +1 -0
  87. package/lib/services/workout/EquipmentType/WorkoutEquipmentTypeService.js +74 -0
  88. package/lib/services/workout/EquipmentType/WorkoutEquipmentTypeService.js.map +1 -0
  89. package/lib/services/workout/EquipmentType/WorkoutEquipmentTypeService.ts +90 -0
  90. package/lib/services/workout/Exercise/WorkoutExerciseService.d.ts +55 -0
  91. package/lib/services/workout/Exercise/WorkoutExerciseService.d.ts.map +1 -0
  92. package/lib/services/workout/Exercise/WorkoutExerciseService.js +133 -0
  93. package/lib/services/workout/Exercise/WorkoutExerciseService.js.map +1 -0
  94. package/lib/services/workout/Exercise/WorkoutExerciseService.ts +173 -0
  95. package/lib/services/workout/ExerciseCalibration/WorkoutExerciseCalibrationService.d.ts +35 -0
  96. package/lib/services/workout/ExerciseCalibration/WorkoutExerciseCalibrationService.d.ts.map +1 -0
  97. package/lib/services/workout/ExerciseCalibration/WorkoutExerciseCalibrationService.js +42 -0
  98. package/lib/services/workout/ExerciseCalibration/WorkoutExerciseCalibrationService.js.map +1 -0
  99. package/lib/services/workout/ExerciseCalibration/WorkoutExerciseCalibrationService.ts +45 -0
  100. package/lib/services/workout/Mesocycle/WorkoutMesocyclePlanContext.d.ts +90 -0
  101. package/lib/services/workout/Mesocycle/WorkoutMesocyclePlanContext.d.ts.map +1 -0
  102. package/lib/services/workout/Mesocycle/WorkoutMesocyclePlanContext.js +131 -0
  103. package/lib/services/workout/Mesocycle/WorkoutMesocyclePlanContext.js.map +1 -0
  104. package/lib/services/workout/Mesocycle/WorkoutMesocyclePlanContext.ts +159 -0
  105. package/lib/services/workout/Mesocycle/WorkoutMesocycleService.d.ts +52 -0
  106. package/lib/services/workout/Mesocycle/WorkoutMesocycleService.d.ts.map +1 -0
  107. package/lib/services/workout/Mesocycle/WorkoutMesocycleService.js +180 -0
  108. package/lib/services/workout/Mesocycle/WorkoutMesocycleService.js.map +1 -0
  109. package/lib/services/workout/Mesocycle/WorkoutMesocycleService.ts +274 -0
  110. package/lib/services/workout/Microcycle/WorkoutMicrocycleService.d.ts +28 -0
  111. package/lib/services/workout/Microcycle/WorkoutMicrocycleService.d.ts.map +1 -0
  112. package/lib/services/workout/Microcycle/WorkoutMicrocycleService.js +172 -0
  113. package/lib/services/workout/Microcycle/WorkoutMicrocycleService.js.map +1 -0
  114. package/lib/services/workout/Microcycle/WorkoutMicrocycleService.ts +236 -0
  115. package/lib/services/workout/Session/WorkoutSessionService.d.ts +49 -0
  116. package/lib/services/workout/Session/WorkoutSessionService.d.ts.map +1 -0
  117. package/lib/services/workout/Session/WorkoutSessionService.js +95 -0
  118. package/lib/services/workout/Session/WorkoutSessionService.js.map +1 -0
  119. package/lib/services/workout/Session/WorkoutSessionService.ts +136 -0
  120. package/lib/services/workout/SessionExercise/WorkoutSessionExerciseService.d.ts +45 -0
  121. package/lib/services/workout/SessionExercise/WorkoutSessionExerciseService.d.ts.map +1 -0
  122. package/lib/services/workout/SessionExercise/WorkoutSessionExerciseService.js +69 -0
  123. package/lib/services/workout/SessionExercise/WorkoutSessionExerciseService.js.map +1 -0
  124. package/lib/services/workout/SessionExercise/WorkoutSessionExerciseService.ts +77 -0
  125. package/lib/services/workout/Set/WorkoutSetService.d.ts +36 -0
  126. package/lib/services/workout/Set/WorkoutSetService.d.ts.map +1 -0
  127. package/lib/services/workout/Set/WorkoutSetService.js +90 -0
  128. package/lib/services/workout/Set/WorkoutSetService.js.map +1 -0
  129. package/lib/services/workout/Set/WorkoutSetService.ts +153 -0
  130. package/lib/services/workout/util/SFR/WorkoutSFRService.d.ts +29 -0
  131. package/lib/services/workout/util/SFR/WorkoutSFRService.d.ts.map +1 -0
  132. package/lib/services/workout/util/SFR/WorkoutSFRService.js +50 -0
  133. package/lib/services/workout/util/SFR/WorkoutSFRService.js.map +1 -0
  134. package/lib/services/workout/util/SFR/WorkoutSFRService.ts +61 -0
  135. package/lib/services/workout/util/VolumePlanning/WorkoutVolumePlanningService.d.ts +48 -0
  136. package/lib/services/workout/util/VolumePlanning/WorkoutVolumePlanningService.d.ts.map +1 -0
  137. package/lib/services/workout/util/VolumePlanning/WorkoutVolumePlanningService.js +261 -0
  138. package/lib/services/workout/util/VolumePlanning/WorkoutVolumePlanningService.js.map +1 -0
  139. package/lib/services/workout/util/VolumePlanning/WorkoutVolumePlanningService.ts +339 -0
  140. package/package.json +5 -4
@@ -0,0 +1,40 @@
1
+ import { z } from 'zod';
2
+ import { RequiredUserIdSchema } from '../../schemas/required-refs/RequiredUserId.js';
3
+ import {
4
+ BaseDocumentWithTypeSchema,
5
+ BaseDocumentWithUpdatedAndCreatedDatesSchema
6
+ } from '../BaseDocument.js';
7
+
8
+ /**
9
+ * The docType value for WorkoutEquipmentType documents.
10
+ */
11
+ export const WorkoutEquipmentType_docType = 'workoutEquipmentType';
12
+
13
+ /**
14
+ * The schema for {@link WorkoutEquipmentType} documents.
15
+ */
16
+ export const WorkoutEquipmentTypeSchema = z.object({
17
+ ...BaseDocumentWithTypeSchema.shape,
18
+ ...RequiredUserIdSchema.shape,
19
+ ...BaseDocumentWithUpdatedAndCreatedDatesSchema.shape,
20
+ docType: z.literal(WorkoutEquipmentType_docType).default(WorkoutEquipmentType_docType),
21
+ /**
22
+ * The title of the equipment type.
23
+ */
24
+ title: z.string(),
25
+ /**
26
+ * The available weight options for this equipment type.
27
+ *
28
+ * This is used to assist in algorithms where weight needs to be incremented
29
+ * or decremented for a schedule. For fixed weights like dumbbells, this would
30
+ * be a list of available weights. For adjustable equipment like barbells,
31
+ * this can be calculated based on minimum weight (e.g., the bar) and possible
32
+ * increments.
33
+ */
34
+ weightOptions: z.array(z.number().nonnegative()).nullish()
35
+ });
36
+
37
+ /**
38
+ * Represents a type of workout equipment with its available weight options.
39
+ */
40
+ export type WorkoutEquipmentType = z.infer<typeof WorkoutEquipmentTypeSchema>;
@@ -0,0 +1,82 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * The different types of exercise properties.
4
+ */
5
+ export declare enum ExercisePropertyType {
6
+ Weight = "Weight",
7
+ Text = "Text",
8
+ YesNo = "Yes/No",
9
+ Number = "Number"
10
+ }
11
+ /**
12
+ * Zod schema for {@link ExerciseProperty}.
13
+ */
14
+ export declare const ExercisePropertySchema: z.ZodObject<{
15
+ name: z.ZodString;
16
+ type: z.ZodEnum<typeof ExercisePropertyType>;
17
+ }, z.core.$strip>;
18
+ /**
19
+ * Represents a custom property for an exercise.
20
+ */
21
+ export type ExerciseProperty = z.infer<typeof ExercisePropertySchema>;
22
+ /**
23
+ * The rep range for an exercise.
24
+ *
25
+ * - Heavy exercises: Normally done in the 5-15 rep range
26
+ * - Medium exercises: Normally done in the 10-20 rep range (This should be the most common)
27
+ * - Light exercises: Normally done in the 15-30 rep range
28
+ */
29
+ export declare enum ExerciseRepRange {
30
+ Heavy = "Heavy",
31
+ Medium = "Medium",
32
+ Light = "Light"
33
+ }
34
+ /**
35
+ * The preferred progression type for an exercise.
36
+ *
37
+ * - Rep: Add 2 reps per week (default). When max reps exceeded, increase weight by smallest increment.
38
+ * - Load: Add smallest available increment each week (or 2% of current load, whichever is greater).
39
+ */
40
+ export declare enum ExerciseProgressionType {
41
+ Rep = "Rep",
42
+ Load = "Load"
43
+ }
44
+ /**
45
+ * The docType value for WorkoutExercise documents.
46
+ */
47
+ export declare const WorkoutExercise_docType = "workoutExercise";
48
+ /**
49
+ * The schema for {@link WorkoutExercise} documents.
50
+ */
51
+ export declare const WorkoutExerciseSchema: z.ZodObject<{
52
+ docType: z.ZodDefault<z.ZodLiteral<"workoutExercise">>;
53
+ exerciseName: z.ZodString;
54
+ workoutEquipmentTypeId: z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
55
+ notes: z.ZodOptional<z.ZodNullable<z.ZodString>>;
56
+ restSeconds: z.ZodOptional<z.ZodNullable<z.ZodInt>>;
57
+ customProperties: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
58
+ name: z.ZodString;
59
+ type: z.ZodEnum<typeof ExercisePropertyType>;
60
+ }, z.core.$strip>>>>;
61
+ repRange: z.ZodEnum<typeof ExerciseRepRange>;
62
+ preferredProgressionType: z.ZodDefault<z.ZodEnum<typeof ExerciseProgressionType>>;
63
+ primaryMuscleGroups: z.ZodDefault<z.ZodArray<z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>>>;
64
+ secondaryMuscleGroups: z.ZodDefault<z.ZodArray<z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>>>;
65
+ initialFatigueGuess: z.ZodObject<{
66
+ jointAndTissueDisruption: z.ZodOptional<z.ZodNullable<z.ZodInt>>;
67
+ perceivedEffort: z.ZodOptional<z.ZodNullable<z.ZodInt>>;
68
+ unusedMusclePerformance: z.ZodOptional<z.ZodNullable<z.ZodInt>>;
69
+ }, z.core.$strip>;
70
+ createdDate: z.ZodDefault<z.ZodDate>;
71
+ lastUpdatedDate: z.ZodDefault<z.ZodDate>;
72
+ _id: z.ZodPipe<z.ZodDefault<z.ZodUUID>, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
73
+ userId: z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
74
+ }, z.core.$strip>;
75
+ /**
76
+ * Represents a specific variation of an exercise with all its details.
77
+ *
78
+ * This is intentionally very specific - each variation (different grip, tempo,
79
+ * equipment position, etc.) should be its own exercise for accurate tracking.
80
+ */
81
+ export type WorkoutExercise = z.infer<typeof WorkoutExerciseSchema>;
82
+ //# sourceMappingURL=WorkoutExercise.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WorkoutExercise.d.ts","sourceRoot":"","sources":["../../../src/documents/workout/WorkoutExercise.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB;;GAEG;AACH,oBAAY,oBAAoB;IAC9B,MAAM,WAAW;IACjB,IAAI,SAAS;IACb,KAAK,WAAW;IAChB,MAAM,WAAW;CAClB;AAED;;GAEG;AACH,eAAO,MAAM,sBAAsB;;;iBASjC,CAAC;AAEH;;GAEG;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAEtE;;;;;;GAMG;AACH,oBAAY,gBAAgB;IAC1B,KAAK,UAAU;IACf,MAAM,WAAW;IACjB,KAAK,UAAU;CAChB;AAED;;;;;GAKG;AACH,oBAAY,uBAAuB;IACjC,GAAG,QAAQ;IACX,IAAI,SAAS;CACd;AAED;;GAEG;AACH,eAAO,MAAM,uBAAuB,oBAAoB,CAAC;AAEzD;;GAEG;AACH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;;;;;iBAgEhC,CAAC;AAEH;;;;;GAKG;AACH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC"}
@@ -0,0 +1,124 @@
1
+ import { z } from 'zod';
2
+ import { FatigueSchema } from '../../embedded-types/workout/Fatigue.js';
3
+ import { RequiredUserIdSchema } from '../../schemas/required-refs/RequiredUserId.js';
4
+ import { BaseDocumentWithTypeSchema, BaseDocumentWithUpdatedAndCreatedDatesSchema } from '../BaseDocument.js';
5
+ /**
6
+ * The different types of exercise properties.
7
+ */
8
+ export var ExercisePropertyType;
9
+ (function (ExercisePropertyType) {
10
+ ExercisePropertyType["Weight"] = "Weight";
11
+ ExercisePropertyType["Text"] = "Text";
12
+ ExercisePropertyType["YesNo"] = "Yes/No";
13
+ ExercisePropertyType["Number"] = "Number";
14
+ })(ExercisePropertyType || (ExercisePropertyType = {}));
15
+ /**
16
+ * Zod schema for {@link ExerciseProperty}.
17
+ */
18
+ export const ExercisePropertySchema = z.object({
19
+ /**
20
+ * The name of the custom property.
21
+ */
22
+ name: z.string(),
23
+ /**
24
+ * The type of the custom property. See {@link ExercisePropertyType} for details.
25
+ */
26
+ type: z.enum(ExercisePropertyType)
27
+ });
28
+ /**
29
+ * The rep range for an exercise.
30
+ *
31
+ * - Heavy exercises: Normally done in the 5-15 rep range
32
+ * - Medium exercises: Normally done in the 10-20 rep range (This should be the most common)
33
+ * - Light exercises: Normally done in the 15-30 rep range
34
+ */
35
+ export var ExerciseRepRange;
36
+ (function (ExerciseRepRange) {
37
+ ExerciseRepRange["Heavy"] = "Heavy";
38
+ ExerciseRepRange["Medium"] = "Medium";
39
+ ExerciseRepRange["Light"] = "Light";
40
+ })(ExerciseRepRange || (ExerciseRepRange = {}));
41
+ /**
42
+ * The preferred progression type for an exercise.
43
+ *
44
+ * - Rep: Add 2 reps per week (default). When max reps exceeded, increase weight by smallest increment.
45
+ * - Load: Add smallest available increment each week (or 2% of current load, whichever is greater).
46
+ */
47
+ export var ExerciseProgressionType;
48
+ (function (ExerciseProgressionType) {
49
+ ExerciseProgressionType["Rep"] = "Rep";
50
+ ExerciseProgressionType["Load"] = "Load";
51
+ })(ExerciseProgressionType || (ExerciseProgressionType = {}));
52
+ /**
53
+ * The docType value for WorkoutExercise documents.
54
+ */
55
+ export const WorkoutExercise_docType = 'workoutExercise';
56
+ /**
57
+ * The schema for {@link WorkoutExercise} documents.
58
+ */
59
+ export const WorkoutExerciseSchema = z.object({
60
+ ...BaseDocumentWithTypeSchema.shape,
61
+ ...RequiredUserIdSchema.shape,
62
+ ...BaseDocumentWithUpdatedAndCreatedDatesSchema.shape,
63
+ docType: z.literal(WorkoutExercise_docType).default(WorkoutExercise_docType),
64
+ /**
65
+ * The name of the exercise.
66
+ *
67
+ * WorkoutExercise is meant to be specific to a particular way of doing an
68
+ * exercise. For example there should be separate exercises for:
69
+ * - Barbell Bench Press (Straight Sets)
70
+ * - Barbell Bench Press (Myoreps)
71
+ * - Dumbbell Bench Press (Straight Sets, Eccentric Focus, 3s Down, 1s Pause)
72
+ *
73
+ * It needs to be ultra specific, because even a different hand position will
74
+ * result in a different exercise and should be tracked separately.
75
+ */
76
+ exerciseName: z.string(),
77
+ /**
78
+ * The ID of the equipment type used for this exercise.
79
+ */
80
+ workoutEquipmentTypeId: z.uuidv7().transform((val) => val),
81
+ /**
82
+ * Optional notes about the exercise.
83
+ */
84
+ notes: z.string().nullish(),
85
+ /**
86
+ * The recommended rest time in seconds between sets.
87
+ *
88
+ * This is used for a timer that will be built into the app for each exercise.
89
+ * No tracking will be done of the timer, it will be purely client-side.
90
+ */
91
+ restSeconds: z.int().positive().nullish(),
92
+ /**
93
+ * Custom properties for this exercise.
94
+ *
95
+ * When customProperties are changed, they should be propagated to all
96
+ * existing WorkoutSet documents with this WorkoutExercise linked to it.
97
+ */
98
+ customProperties: z.array(ExercisePropertySchema).nullish(),
99
+ /**
100
+ * The recommended rep range for this exercise. See {@link ExerciseRepRange} for details.
101
+ */
102
+ repRange: z.enum(ExerciseRepRange),
103
+ /**
104
+ * The preferred progression type for this exercise.
105
+ *
106
+ * Defaults to Rep progression if not specified.
107
+ */
108
+ preferredProgressionType: z.enum(ExerciseProgressionType).default(ExerciseProgressionType.Rep),
109
+ /**
110
+ * The IDs of the primary muscle groups targeted by this exercise.
111
+ */
112
+ primaryMuscleGroups: z.array(z.uuidv7().transform((val) => val)).default([]),
113
+ /**
114
+ * The IDs of the secondary muscle groups targeted by this exercise.
115
+ */
116
+ secondaryMuscleGroups: z.array(z.uuidv7().transform((val) => val)).default([]),
117
+ /**
118
+ * An initial guess of the fatigue this exercise produces.
119
+ *
120
+ * This is needed for scheduling algorithms when empirical data isn't yet available.
121
+ */
122
+ initialFatigueGuess: FatigueSchema
123
+ });
124
+ //# sourceMappingURL=WorkoutExercise.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WorkoutExercise.js","sourceRoot":"","sources":["../../../src/documents/workout/WorkoutExercise.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,aAAa,EAAE,MAAM,yCAAyC,CAAC;AACxE,OAAO,EAAE,oBAAoB,EAAE,MAAM,+CAA+C,CAAC;AACrF,OAAO,EACL,0BAA0B,EAC1B,4CAA4C,EAC7C,MAAM,oBAAoB,CAAC;AAE5B;;GAEG;AACH,MAAM,CAAN,IAAY,oBAKX;AALD,WAAY,oBAAoB;IAC9B,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,wCAAgB,CAAA;IAChB,yCAAiB,CAAA;AACnB,CAAC,EALW,oBAAoB,KAApB,oBAAoB,QAK/B;AAED;;GAEG;AACH,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7C;;OAEG;IACH,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;IAChB;;OAEG;IACH,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,oBAAoB,CAAC;CACnC,CAAC,CAAC;AAOH;;;;;;GAMG;AACH,MAAM,CAAN,IAAY,gBAIX;AAJD,WAAY,gBAAgB;IAC1B,mCAAe,CAAA;IACf,qCAAiB,CAAA;IACjB,mCAAe,CAAA;AACjB,CAAC,EAJW,gBAAgB,KAAhB,gBAAgB,QAI3B;AAED;;;;;GAKG;AACH,MAAM,CAAN,IAAY,uBAGX;AAHD,WAAY,uBAAuB;IACjC,sCAAW,CAAA;IACX,wCAAa,CAAA;AACf,CAAC,EAHW,uBAAuB,KAAvB,uBAAuB,QAGlC;AAED;;GAEG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAG,iBAAiB,CAAC;AAEzD;;GAEG;AACH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5C,GAAG,0BAA0B,CAAC,KAAK;IACnC,GAAG,oBAAoB,CAAC,KAAK;IAC7B,GAAG,4CAA4C,CAAC,KAAK;IACrD,OAAO,EAAE,CAAC,CAAC,OAAO,CAAC,uBAAuB,CAAC,CAAC,OAAO,CAAC,uBAAuB,CAAC;IAC5E;;;;;;;;;;;OAWG;IACH,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE;IACxB;;OAEG;IACH,sBAAsB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAW,CAAC;IAClE;;OAEG;IACH,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,OAAO,EAAE;IAC3B;;;;;OAKG;IACH,WAAW,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,EAAE;IACzC;;;;;OAKG;IACH,gBAAgB,EAAE,CAAC,CAAC,KAAK,CAAC,sBAAsB,CAAC,CAAC,OAAO,EAAE;IAC3D;;OAEG;IACH,QAAQ,EAAE,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC;IAClC;;;;OAIG;IACH,wBAAwB,EAAE,CAAC,CAAC,IAAI,CAAC,uBAAuB,CAAC,CAAC,OAAO,CAAC,uBAAuB,CAAC,GAAG,CAAC;IAC9F;;OAEG;IACH,mBAAmB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC;IACpF;;OAEG;IACH,qBAAqB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAW,CAAC,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC;IACtF;;;;OAIG;IACH,mBAAmB,EAAE,aAAa;CACnC,CAAC,CAAC"}
@@ -0,0 +1,143 @@
1
+ import type { UUID } from 'crypto';
2
+ import { z } from 'zod';
3
+ import { FatigueSchema } from '../../embedded-types/workout/Fatigue.js';
4
+ import { RequiredUserIdSchema } from '../../schemas/required-refs/RequiredUserId.js';
5
+ import {
6
+ BaseDocumentWithTypeSchema,
7
+ BaseDocumentWithUpdatedAndCreatedDatesSchema
8
+ } from '../BaseDocument.js';
9
+
10
+ /**
11
+ * The different types of exercise properties.
12
+ */
13
+ export enum ExercisePropertyType {
14
+ Weight = 'Weight',
15
+ Text = 'Text',
16
+ YesNo = 'Yes/No',
17
+ Number = 'Number'
18
+ }
19
+
20
+ /**
21
+ * Zod schema for {@link ExerciseProperty}.
22
+ */
23
+ export const ExercisePropertySchema = z.object({
24
+ /**
25
+ * The name of the custom property.
26
+ */
27
+ name: z.string(),
28
+ /**
29
+ * The type of the custom property. See {@link ExercisePropertyType} for details.
30
+ */
31
+ type: z.enum(ExercisePropertyType)
32
+ });
33
+
34
+ /**
35
+ * Represents a custom property for an exercise.
36
+ */
37
+ export type ExerciseProperty = z.infer<typeof ExercisePropertySchema>;
38
+
39
+ /**
40
+ * The rep range for an exercise.
41
+ *
42
+ * - Heavy exercises: Normally done in the 5-15 rep range
43
+ * - Medium exercises: Normally done in the 10-20 rep range (This should be the most common)
44
+ * - Light exercises: Normally done in the 15-30 rep range
45
+ */
46
+ export enum ExerciseRepRange {
47
+ Heavy = 'Heavy',
48
+ Medium = 'Medium',
49
+ Light = 'Light'
50
+ }
51
+
52
+ /**
53
+ * The preferred progression type for an exercise.
54
+ *
55
+ * - Rep: Add 2 reps per week (default). When max reps exceeded, increase weight by smallest increment.
56
+ * - Load: Add smallest available increment each week (or 2% of current load, whichever is greater).
57
+ */
58
+ export enum ExerciseProgressionType {
59
+ Rep = 'Rep',
60
+ Load = 'Load'
61
+ }
62
+
63
+ /**
64
+ * The docType value for WorkoutExercise documents.
65
+ */
66
+ export const WorkoutExercise_docType = 'workoutExercise';
67
+
68
+ /**
69
+ * The schema for {@link WorkoutExercise} documents.
70
+ */
71
+ export const WorkoutExerciseSchema = z.object({
72
+ ...BaseDocumentWithTypeSchema.shape,
73
+ ...RequiredUserIdSchema.shape,
74
+ ...BaseDocumentWithUpdatedAndCreatedDatesSchema.shape,
75
+ docType: z.literal(WorkoutExercise_docType).default(WorkoutExercise_docType),
76
+ /**
77
+ * The name of the exercise.
78
+ *
79
+ * WorkoutExercise is meant to be specific to a particular way of doing an
80
+ * exercise. For example there should be separate exercises for:
81
+ * - Barbell Bench Press (Straight Sets)
82
+ * - Barbell Bench Press (Myoreps)
83
+ * - Dumbbell Bench Press (Straight Sets, Eccentric Focus, 3s Down, 1s Pause)
84
+ *
85
+ * It needs to be ultra specific, because even a different hand position will
86
+ * result in a different exercise and should be tracked separately.
87
+ */
88
+ exerciseName: z.string(),
89
+ /**
90
+ * The ID of the equipment type used for this exercise.
91
+ */
92
+ workoutEquipmentTypeId: z.uuidv7().transform((val) => val as UUID),
93
+ /**
94
+ * Optional notes about the exercise.
95
+ */
96
+ notes: z.string().nullish(),
97
+ /**
98
+ * The recommended rest time in seconds between sets.
99
+ *
100
+ * This is used for a timer that will be built into the app for each exercise.
101
+ * No tracking will be done of the timer, it will be purely client-side.
102
+ */
103
+ restSeconds: z.int().positive().nullish(),
104
+ /**
105
+ * Custom properties for this exercise.
106
+ *
107
+ * When customProperties are changed, they should be propagated to all
108
+ * existing WorkoutSet documents with this WorkoutExercise linked to it.
109
+ */
110
+ customProperties: z.array(ExercisePropertySchema).nullish(),
111
+ /**
112
+ * The recommended rep range for this exercise. See {@link ExerciseRepRange} for details.
113
+ */
114
+ repRange: z.enum(ExerciseRepRange),
115
+ /**
116
+ * The preferred progression type for this exercise.
117
+ *
118
+ * Defaults to Rep progression if not specified.
119
+ */
120
+ preferredProgressionType: z.enum(ExerciseProgressionType).default(ExerciseProgressionType.Rep),
121
+ /**
122
+ * The IDs of the primary muscle groups targeted by this exercise.
123
+ */
124
+ primaryMuscleGroups: z.array(z.uuidv7().transform((val) => val as UUID)).default([]),
125
+ /**
126
+ * The IDs of the secondary muscle groups targeted by this exercise.
127
+ */
128
+ secondaryMuscleGroups: z.array(z.uuidv7().transform((val) => val as UUID)).default([]),
129
+ /**
130
+ * An initial guess of the fatigue this exercise produces.
131
+ *
132
+ * This is needed for scheduling algorithms when empirical data isn't yet available.
133
+ */
134
+ initialFatigueGuess: FatigueSchema
135
+ });
136
+
137
+ /**
138
+ * Represents a specific variation of an exercise with all its details.
139
+ *
140
+ * This is intentionally very specific - each variation (different grip, tempo,
141
+ * equipment position, etc.) should be its own exercise for accurate tracking.
142
+ */
143
+ export type WorkoutExercise = z.infer<typeof WorkoutExerciseSchema>;
@@ -0,0 +1,43 @@
1
+ import { z } from 'zod';
2
+ import type { WorkoutExercise } from './WorkoutExercise.js';
3
+ /**
4
+ * The docType value for WorkoutExerciseCalibration documents.
5
+ */
6
+ export declare const WorkoutExerciseCalibration_docType = "workoutExerciseCalibration";
7
+ /**
8
+ * The schema for {@link WorkoutExerciseCalibration} documents.
9
+ */
10
+ export declare const WorkoutExerciseCalibrationSchema: z.ZodObject<{
11
+ docType: z.ZodDefault<z.ZodLiteral<"workoutExerciseCalibration">>;
12
+ workoutExerciseId: z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
13
+ exerciseProperties: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
14
+ reps: z.ZodInt;
15
+ weight: z.ZodNumber;
16
+ dateRecorded: z.ZodDefault<z.ZodDate>;
17
+ createdDate: z.ZodDefault<z.ZodDate>;
18
+ lastUpdatedDate: z.ZodDefault<z.ZodDate>;
19
+ _id: z.ZodPipe<z.ZodDefault<z.ZodUUID>, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
20
+ userId: z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
21
+ }, z.core.$strip>;
22
+ /**
23
+ * Represents a calibration point for an exercise, used to calculate 1RM and
24
+ * track strength progression.
25
+ *
26
+ * These documents store the lowest amount of reps the person can do for an
27
+ * exercise with the highest amount of weight they can handle. This is used
28
+ * for 1RM calculations using the NASM formula:
29
+ * 1RM = (Weight Lifted x Reps / 30.48) + Weight Lifted
30
+ *
31
+ * WorkoutMesocycle documents reference these to lock in which calibration was
32
+ * used, ensuring historical 1RM values remain accurate even if calibrations
33
+ * are updated later.
34
+ */
35
+ export type WorkoutExerciseCalibration = z.infer<typeof WorkoutExerciseCalibrationSchema>;
36
+ /**
37
+ * Represents a calibration paired with its associated exercise definition.
38
+ */
39
+ export type CalibrationExercisePair = {
40
+ calibration: WorkoutExerciseCalibration;
41
+ exercise: WorkoutExercise;
42
+ };
43
+ //# sourceMappingURL=WorkoutExerciseCalibration.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WorkoutExerciseCalibration.d.ts","sourceRoot":"","sources":["../../../src/documents/workout/WorkoutExerciseCalibration.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAMxB,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAE5D;;GAEG;AACH,eAAO,MAAM,kCAAkC,+BAA+B,CAAC;AAE/E;;GAEG;AACH,eAAO,MAAM,gCAAgC;;;;;;;;;;;iBAiC3C,CAAC;AAEH;;;;;;;;;;;;GAYG;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAC;AAE1F;;GAEG;AACH,MAAM,MAAM,uBAAuB,GAAG;IACpC,WAAW,EAAE,0BAA0B,CAAC;IACxC,QAAQ,EAAE,eAAe,CAAC;CAC3B,CAAC"}
@@ -0,0 +1,45 @@
1
+ import { z } from 'zod';
2
+ import { RequiredUserIdSchema } from '../../schemas/required-refs/RequiredUserId.js';
3
+ import { BaseDocumentWithTypeSchema, BaseDocumentWithUpdatedAndCreatedDatesSchema } from '../BaseDocument.js';
4
+ /**
5
+ * The docType value for WorkoutExerciseCalibration documents.
6
+ */
7
+ export const WorkoutExerciseCalibration_docType = 'workoutExerciseCalibration';
8
+ /**
9
+ * The schema for {@link WorkoutExerciseCalibration} documents.
10
+ */
11
+ export const WorkoutExerciseCalibrationSchema = z.object({
12
+ ...BaseDocumentWithTypeSchema.shape,
13
+ ...RequiredUserIdSchema.shape,
14
+ ...BaseDocumentWithUpdatedAndCreatedDatesSchema.shape,
15
+ docType: z
16
+ .literal(WorkoutExerciseCalibration_docType)
17
+ .default(WorkoutExerciseCalibration_docType),
18
+ /**
19
+ * The ID of the exercise this calibration is for.
20
+ */
21
+ workoutExerciseId: z.uuidv7().transform((val) => val),
22
+ /**
23
+ * Custom exercise properties at the time of calibration.
24
+ *
25
+ * This is populated from WorkoutExercise.customProperties at creation time
26
+ * to preserve historical context.
27
+ */
28
+ exerciseProperties: z.record(z.string(), z.unknown()).nullish(),
29
+ /**
30
+ * The number of reps performed at the calibration weight.
31
+ *
32
+ * This should be the lowest amount of reps the person can do with the highest
33
+ * amount of weight they can handle for this exercise.
34
+ */
35
+ reps: z.int().positive(),
36
+ /**
37
+ * The weight used for this calibration.
38
+ */
39
+ weight: z.number(),
40
+ /**
41
+ * The date this calibration was recorded.
42
+ */
43
+ dateRecorded: z.date().default(() => new Date())
44
+ });
45
+ //# sourceMappingURL=WorkoutExerciseCalibration.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WorkoutExerciseCalibration.js","sourceRoot":"","sources":["../../../src/documents/workout/WorkoutExerciseCalibration.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,oBAAoB,EAAE,MAAM,+CAA+C,CAAC;AACrF,OAAO,EACL,0BAA0B,EAC1B,4CAA4C,EAC7C,MAAM,oBAAoB,CAAC;AAG5B;;GAEG;AACH,MAAM,CAAC,MAAM,kCAAkC,GAAG,4BAA4B,CAAC;AAE/E;;GAEG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAG,CAAC,CAAC,MAAM,CAAC;IACvD,GAAG,0BAA0B,CAAC,KAAK;IACnC,GAAG,oBAAoB,CAAC,KAAK;IAC7B,GAAG,4CAA4C,CAAC,KAAK;IACrD,OAAO,EAAE,CAAC;SACP,OAAO,CAAC,kCAAkC,CAAC;SAC3C,OAAO,CAAC,kCAAkC,CAAC;IAC9C;;OAEG;IACH,iBAAiB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,SAAS,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAW,CAAC;IAC7D;;;;;OAKG;IACH,kBAAkB,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE;IAC/D;;;;;OAKG;IACH,IAAI,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE;IACxB;;OAEG;IACH,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE;IAClB;;OAEG;IACH,YAAY,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,IAAI,IAAI,EAAE,CAAC;CACjD,CAAC,CAAC"}
@@ -0,0 +1,74 @@
1
+ import type { UUID } from 'crypto';
2
+ import { z } from 'zod';
3
+ import { RequiredUserIdSchema } from '../../schemas/required-refs/RequiredUserId.js';
4
+ import {
5
+ BaseDocumentWithTypeSchema,
6
+ BaseDocumentWithUpdatedAndCreatedDatesSchema
7
+ } from '../BaseDocument.js';
8
+ import type { WorkoutExercise } from './WorkoutExercise.js';
9
+
10
+ /**
11
+ * The docType value for WorkoutExerciseCalibration documents.
12
+ */
13
+ export const WorkoutExerciseCalibration_docType = 'workoutExerciseCalibration';
14
+
15
+ /**
16
+ * The schema for {@link WorkoutExerciseCalibration} documents.
17
+ */
18
+ export const WorkoutExerciseCalibrationSchema = z.object({
19
+ ...BaseDocumentWithTypeSchema.shape,
20
+ ...RequiredUserIdSchema.shape,
21
+ ...BaseDocumentWithUpdatedAndCreatedDatesSchema.shape,
22
+ docType: z
23
+ .literal(WorkoutExerciseCalibration_docType)
24
+ .default(WorkoutExerciseCalibration_docType),
25
+ /**
26
+ * The ID of the exercise this calibration is for.
27
+ */
28
+ workoutExerciseId: z.uuidv7().transform((val) => val as UUID),
29
+ /**
30
+ * Custom exercise properties at the time of calibration.
31
+ *
32
+ * This is populated from WorkoutExercise.customProperties at creation time
33
+ * to preserve historical context.
34
+ */
35
+ exerciseProperties: z.record(z.string(), z.unknown()).nullish(),
36
+ /**
37
+ * The number of reps performed at the calibration weight.
38
+ *
39
+ * This should be the lowest amount of reps the person can do with the highest
40
+ * amount of weight they can handle for this exercise.
41
+ */
42
+ reps: z.int().positive(),
43
+ /**
44
+ * The weight used for this calibration.
45
+ */
46
+ weight: z.number(),
47
+ /**
48
+ * The date this calibration was recorded.
49
+ */
50
+ dateRecorded: z.date().default(() => new Date())
51
+ });
52
+
53
+ /**
54
+ * Represents a calibration point for an exercise, used to calculate 1RM and
55
+ * track strength progression.
56
+ *
57
+ * These documents store the lowest amount of reps the person can do for an
58
+ * exercise with the highest amount of weight they can handle. This is used
59
+ * for 1RM calculations using the NASM formula:
60
+ * 1RM = (Weight Lifted x Reps / 30.48) + Weight Lifted
61
+ *
62
+ * WorkoutMesocycle documents reference these to lock in which calibration was
63
+ * used, ensuring historical 1RM values remain accurate even if calibrations
64
+ * are updated later.
65
+ */
66
+ export type WorkoutExerciseCalibration = z.infer<typeof WorkoutExerciseCalibrationSchema>;
67
+
68
+ /**
69
+ * Represents a calibration paired with its associated exercise definition.
70
+ */
71
+ export type CalibrationExercisePair = {
72
+ calibration: WorkoutExerciseCalibration;
73
+ exercise: WorkoutExercise;
74
+ };
@@ -0,0 +1,49 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * The type of mesocycle.
4
+ *
5
+ * - MuscleGain: Automatic recommendations will be made for muscle gain
6
+ * - Resensitization: Automatic recommendations for MV training (maintenance)
7
+ * - Cut: Automatic recommendations for fat loss while maintaining muscle
8
+ * - FreeForm: No automatic recommendations, user has full control
9
+ */
10
+ export declare enum CycleType {
11
+ MuscleGain = "MuscleGain",
12
+ Resensitization = "Resensitization",
13
+ Cut = "Cut",
14
+ FreeForm = "FreeForm"
15
+ }
16
+ /**
17
+ * The docType value for WorkoutMesocycle documents.
18
+ */
19
+ export declare const WorkoutMesocycle_docType = "workoutMesocycle";
20
+ /**
21
+ * The schema for {@link WorkoutMesocycle} documents.
22
+ */
23
+ export declare const WorkoutMesocycleSchema: z.ZodObject<{
24
+ docType: z.ZodDefault<z.ZodLiteral<"workoutMesocycle">>;
25
+ title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
26
+ calibratedExercises: z.ZodDefault<z.ZodArray<z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>>>;
27
+ cycleType: z.ZodEnum<typeof CycleType>;
28
+ plannedSessionCountPerMicrocycle: z.ZodInt;
29
+ plannedMicrocycleLengthInDays: z.ZodInt;
30
+ plannedMicrocycleRestDays: z.ZodDefault<z.ZodArray<z.ZodInt>>;
31
+ plannedMicrocycleCount: z.ZodOptional<z.ZodNullable<z.ZodInt>>;
32
+ completedDate: z.ZodOptional<z.ZodNullable<z.ZodDate>>;
33
+ createdDate: z.ZodDefault<z.ZodDate>;
34
+ lastUpdatedDate: z.ZodDefault<z.ZodDate>;
35
+ _id: z.ZodPipe<z.ZodDefault<z.ZodUUID>, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
36
+ userId: z.ZodPipe<z.ZodUUID, z.ZodTransform<`${string}-${string}-${string}-${string}-${string}`, string>>;
37
+ }, z.core.$strip>;
38
+ /**
39
+ * Represents a mesocycle - an organized sequence of microcycles ordered to
40
+ * elicit a set of distinct training adaptations.
41
+ *
42
+ * A typical mesocycle is composed of two distinct phases:
43
+ * 1. Accumulation phase: Progress from MEV towards MRV
44
+ * 2. Deload phase: Shorter recovery period
45
+ *
46
+ * The accumulation phase should last 4-8 weeks, followed by a deload phase.
47
+ */
48
+ export type WorkoutMesocycle = z.infer<typeof WorkoutMesocycleSchema>;
49
+ //# sourceMappingURL=WorkoutMesocycle.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WorkoutMesocycle.d.ts","sourceRoot":"","sources":["../../../src/documents/workout/WorkoutMesocycle.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAOxB;;;;;;;GAOG;AACH,oBAAY,SAAS;IACnB,UAAU,eAAe;IACzB,eAAe,oBAAoB;IACnC,GAAG,QAAQ;IACX,QAAQ,aAAa;CACtB;AAED;;GAEG;AACH,eAAO,MAAM,wBAAwB,qBAAqB,CAAC;AAE3D;;GAEG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;iBA0D/B,CAAC;AAEL;;;;;;;;;GASG;AACH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC"}