react-native-spike-sdk 4.3.203 → 4.3.223
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.
- package/lib/commonjs/index.js +0 -36
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/v3/DataModels/MetricType.js +6 -0
- package/lib/commonjs/v3/DataModels/MetricType.js.map +1 -1
- package/lib/commonjs/v3/Utils/NutritionRecordIngredientUtils.js +68 -74
- package/lib/commonjs/v3/Utils/NutritionRecordIngredientUtils.js.map +1 -1
- package/lib/commonjs/v3/Utils/NutritionRecordUtils.js +47 -53
- package/lib/commonjs/v3/Utils/NutritionRecordUtils.js.map +1 -1
- package/lib/commonjs/version.js +1 -1
- package/lib/module/index.js +4 -4
- package/lib/module/index.js.map +1 -1
- package/lib/module/v3/DataModels/MetricType.js +6 -0
- package/lib/module/v3/DataModels/MetricType.js.map +1 -1
- package/lib/module/v3/Utils/NutritionRecordIngredientUtils.js +68 -71
- package/lib/module/v3/Utils/NutritionRecordIngredientUtils.js.map +1 -1
- package/lib/module/v3/Utils/NutritionRecordUtils.js +47 -50
- package/lib/module/v3/Utils/NutritionRecordUtils.js.map +1 -1
- package/lib/module/version.js +1 -1
- package/lib/typescript/index.d.ts +3 -3
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/v3/DataModels/MetricType.d.ts +10 -0
- package/lib/typescript/v3/DataModels/MetricType.d.ts.map +1 -1
- package/lib/typescript/v3/Utils/NutritionRecordIngredientUtils.d.ts +29 -29
- package/lib/typescript/v3/Utils/NutritionRecordIngredientUtils.d.ts.map +1 -1
- package/lib/typescript/v3/Utils/NutritionRecordUtils.d.ts +35 -35
- package/lib/typescript/v3/Utils/NutritionRecordUtils.d.ts.map +1 -1
- package/lib/typescript/version.d.ts +1 -1
- package/package.json +2 -2
- package/src/index.ts +0 -12
- package/src/v3/DataModels/MetricType.ts +141 -0
- package/src/v3/Utils/NutritionRecordIngredientUtils.ts +74 -75
- package/src/v3/Utils/NutritionRecordUtils.ts +60 -61
- package/src/version.ts +1 -1
package/lib/commonjs/index.js
CHANGED
|
@@ -226,42 +226,6 @@ Object.defineProperty(exports, "Unit", {
|
|
|
226
226
|
}
|
|
227
227
|
});
|
|
228
228
|
exports.default = void 0;
|
|
229
|
-
Object.defineProperty(exports, "withIngredient", {
|
|
230
|
-
enumerable: true,
|
|
231
|
-
get: function () {
|
|
232
|
-
return _NutritionRecordUtils.withIngredient;
|
|
233
|
-
}
|
|
234
|
-
});
|
|
235
|
-
Object.defineProperty(exports, "withNutritionalField", {
|
|
236
|
-
enumerable: true,
|
|
237
|
-
get: function () {
|
|
238
|
-
return _NutritionRecordIngredientUtils.withNutritionalField;
|
|
239
|
-
}
|
|
240
|
-
});
|
|
241
|
-
Object.defineProperty(exports, "withScaledServingSize", {
|
|
242
|
-
enumerable: true,
|
|
243
|
-
get: function () {
|
|
244
|
-
return _NutritionRecordIngredientUtils.withScaledServingSize;
|
|
245
|
-
}
|
|
246
|
-
});
|
|
247
|
-
Object.defineProperty(exports, "withServingSize", {
|
|
248
|
-
enumerable: true,
|
|
249
|
-
get: function () {
|
|
250
|
-
return _NutritionRecordUtils.withServingSize;
|
|
251
|
-
}
|
|
252
|
-
});
|
|
253
|
-
Object.defineProperty(exports, "withoutIngredient", {
|
|
254
|
-
enumerable: true,
|
|
255
|
-
get: function () {
|
|
256
|
-
return _NutritionRecordUtils.withoutIngredient;
|
|
257
|
-
}
|
|
258
|
-
});
|
|
259
|
-
Object.defineProperty(exports, "withoutNutritionalField", {
|
|
260
|
-
enumerable: true,
|
|
261
|
-
get: function () {
|
|
262
|
-
return _NutritionRecordIngredientUtils.withoutNutritionalField;
|
|
263
|
-
}
|
|
264
|
-
});
|
|
265
229
|
var _SpikeDataTypes = require("./DataModels/SpikeDataTypes");
|
|
266
230
|
var _Spike = require("./Spike");
|
|
267
231
|
var _SpikeConnection = require("./SpikeConnection");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_SpikeDataTypes","require","_Spike","_SpikeConnection","_SpikeException","_SpikeRNConnectionAPIv","_ActivityTag","_ActivityType","_ActivityCategory","_InputMethod","_MetricType","_Provider","_ProviderSource","_StatisticsType","_StatisticsInterval","_Unit","_StatisticsFilter","_HealthConnectAvailabilityStatus","_HealthConnectFeature","_SamsungHealthDataAvailabilityStatus","_ActivityAdditionalData","_ActivityConfig","_SleepConfig","_LogLevel","_NutritionRecordStatus","_NutritionRecordAnalysisMode","_NutritionalField","_NutritionalUnit","_NutritionRecordUtils","_NutritionRecordIngredientUtils","_default","exports","default","createConnection","getBackgroundConnections","ensurePermissionsAreGranted","isPackageInstalled","isHealthDataAvailable","createConnectionAPIv3","createConnectionAPIv3Legacy","setLogCallback"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":"
|
|
1
|
+
{"version":3,"names":["_SpikeDataTypes","require","_Spike","_SpikeConnection","_SpikeException","_SpikeRNConnectionAPIv","_ActivityTag","_ActivityType","_ActivityCategory","_InputMethod","_MetricType","_Provider","_ProviderSource","_StatisticsType","_StatisticsInterval","_Unit","_StatisticsFilter","_HealthConnectAvailabilityStatus","_HealthConnectFeature","_SamsungHealthDataAvailabilityStatus","_ActivityAdditionalData","_ActivityConfig","_SleepConfig","_LogLevel","_NutritionRecordStatus","_NutritionRecordAnalysisMode","_NutritionalField","_NutritionalUnit","_NutritionRecordUtils","_NutritionRecordIngredientUtils","_default","exports","default","createConnection","getBackgroundConnections","ensurePermissionsAreGranted","isPackageInstalled","isHealthDataAvailable","createConnectionAPIv3","createConnectionAPIv3Legacy","setLogCallback"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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,EAArBA,4BAAqB;EACrB;EACAC,qBAAqB,EAArBA,4BAAqB;EACrBC,2BAA2B,EAA3BA,kCAA2B;EAC3BC,cAAc,EAAdA;AACF,CAAC,EAoCD","ignoreList":[]}
|
|
@@ -97,4 +97,10 @@ let MetricType = exports.MetricType = /*#__PURE__*/function (MetricType) {
|
|
|
97
97
|
MetricType["unknown"] = "_unknown";
|
|
98
98
|
return MetricType;
|
|
99
99
|
}({});
|
|
100
|
+
(function (_MetricType) {
|
|
101
|
+
const availableForRecordsRequest = _MetricType.availableForRecordsRequest = [MetricType.stepsTotal, MetricType.caloriesBurnedActive, MetricType.caloriesBurnedBasal, MetricType.caloriesBurned, MetricType.distanceTotal, MetricType.distanceWalking, MetricType.distanceCycling, MetricType.distanceRunning, MetricType.weight, MetricType.height, MetricType.vo2Max, MetricType.heartrateMax, MetricType.heartrateMin, MetricType.heartrate, MetricType.heartrateResting, MetricType.heartrateRestingMin, MetricType.heartrateRestingMax, MetricType.hrvSdnn, MetricType.hrvRmssd, MetricType.spo2, MetricType.spo2Max, MetricType.spo2Min, MetricType.bodyTemperature, MetricType.bodyTemperatureMin, MetricType.bodyTemperatureMax, MetricType.skinTemperature, MetricType.skinTemperatureMin, MetricType.skinTemperatureMax, MetricType.basalBodyTemperature, MetricType.basalBodyTemperatureMin, MetricType.basalBodyTemperatureMax, MetricType.bodyMassIndex, MetricType.bodyBoneMass, MetricType.bodyFat, MetricType.bodyFatMax, MetricType.bodyFatMin, MetricType.bloodPressureSystolic, MetricType.bloodPressureSystolicMin, MetricType.bloodPressureSystolicMax, MetricType.bloodPressureDiastolic, MetricType.bloodPressureDiastolicMin, MetricType.bloodPressureDiastolicMax, MetricType.glucose, MetricType.cadence, MetricType.cadenceMin, MetricType.cadenceMax, MetricType.sleepSkinTemperatureDeviation];
|
|
102
|
+
const availableForActivitiesRequest = _MetricType.availableForActivitiesRequest = [MetricType.stepsTotal, MetricType.caloriesBurnedActive, MetricType.caloriesBurnedBasal, MetricType.caloriesBurned, MetricType.distanceTotal, MetricType.distanceWalking, MetricType.distanceCycling, MetricType.distanceRunning, MetricType.distanceSwimming, MetricType.heartrateMax, MetricType.heartrateMin, MetricType.heartrate, MetricType.heartrateResting, MetricType.hrvSdnn, MetricType.hrvRmssd, MetricType.elevationMax, MetricType.elevationMin, MetricType.elevationGain, MetricType.elevationLoss, MetricType.ascent, MetricType.descent, MetricType.floorsClimbed, MetricType.speed, MetricType.speedMax, MetricType.speedMin, MetricType.airTemperatureMax, MetricType.airTemperatureMin, MetricType.spo2, MetricType.spo2Max, MetricType.spo2Min, MetricType.longitude, MetricType.latitude, MetricType.elevation, MetricType.durationActive, MetricType.swimmingLengths, MetricType.swimmingDistancePerStroke, MetricType.vo2Max, MetricType.cadence, MetricType.cadenceMin, MetricType.cadenceMax, MetricType.pace];
|
|
103
|
+
const availableForSleepRequest = _MetricType.availableForSleepRequest = [MetricType.heartrate, MetricType.heartrateMin, MetricType.heartrateMax, MetricType.hrvSdnn, MetricType.hrvRmssd, MetricType.spo2, MetricType.spo2Max, MetricType.spo2Min, MetricType.breathingRate, MetricType.breathingRateMin, MetricType.breathingRateMax, MetricType.skinTemperature, MetricType.skinTemperatureMin, MetricType.skinTemperatureMax, MetricType.sleepScore, MetricType.sleepLatency, MetricType.sleepDuration, MetricType.sleepEfficiency, MetricType.sleepInterruptions, MetricType.sleepDurationNap, MetricType.sleepDurationRem, MetricType.sleepDurationDeep, MetricType.sleepDurationAwake, MetricType.sleepDurationLight];
|
|
104
|
+
const availableForPersonRequest = _MetricType.availableForPersonRequest = [MetricType.birthYear, MetricType.birthDate, MetricType.height, MetricType.weight, MetricType.timezone, MetricType.gender, MetricType.bodyFat, MetricType.bodyBoneMass, MetricType.bodyMassIndex];
|
|
105
|
+
})(MetricType || (exports.MetricType = MetricType = {}));
|
|
100
106
|
//# sourceMappingURL=MetricType.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["MetricType","exports"],"sourceRoot":"../../../../src","sources":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VA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAA,OAAVA,UAAU;AAAA","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["MetricType","exports","_MetricType","availableForRecordsRequest","stepsTotal","caloriesBurnedActive","caloriesBurnedBasal","caloriesBurned","distanceTotal","distanceWalking","distanceCycling","distanceRunning","weight","height","vo2Max","heartrateMax","heartrateMin","heartrate","heartrateResting","heartrateRestingMin","heartrateRestingMax","hrvSdnn","hrvRmssd","spo2","spo2Max","spo2Min","bodyTemperature","bodyTemperatureMin","bodyTemperatureMax","skinTemperature","skinTemperatureMin","skinTemperatureMax","basalBodyTemperature","basalBodyTemperatureMin","basalBodyTemperatureMax","bodyMassIndex","bodyBoneMass","bodyFat","bodyFatMax","bodyFatMin","bloodPressureSystolic","bloodPressureSystolicMin","bloodPressureSystolicMax","bloodPressureDiastolic","bloodPressureDiastolicMin","bloodPressureDiastolicMax","glucose","cadence","cadenceMin","cadenceMax","sleepSkinTemperatureDeviation","availableForActivitiesRequest","distanceSwimming","elevationMax","elevationMin","elevationGain","elevationLoss","ascent","descent","floorsClimbed","speed","speedMax","speedMin","airTemperatureMax","airTemperatureMin","longitude","latitude","elevation","durationActive","swimmingLengths","swimmingDistancePerStroke","pace","availableForSleepRequest","breathingRate","breathingRateMin","breathingRateMax","sleepScore","sleepLatency","sleepDuration","sleepEfficiency","sleepInterruptions","sleepDurationNap","sleepDurationRem","sleepDurationDeep","sleepDurationAwake","sleepDurationLight","availableForPersonRequest","birthYear","birthDate","timezone","gender"],"sourceRoot":"../../../../src","sources":["v3/DataModels/MetricType.ts"],"mappings":";;;;;;AACA;AACA;AAAA,IACYA,UAAU,GAAAC,OAAA,CAAAD,UAAA,0BAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EA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
|
exports.NutritionRecordIngredientUtils = void 0;
|
|
7
|
-
exports.withNutritionalField = withNutritionalField;
|
|
8
|
-
exports.withScaledServingSize = withScaledServingSize;
|
|
9
|
-
exports.withoutNutritionalField = withoutNutritionalField;
|
|
10
7
|
/**
|
|
11
8
|
* Options for creating a new NutritionRecordIngredient.
|
|
12
9
|
*/
|
|
@@ -29,80 +26,77 @@ const NutritionRecordIngredientUtils = exports.NutritionRecordIngredientUtils =
|
|
|
29
26
|
unit: options.unit,
|
|
30
27
|
nutritionalFields: null
|
|
31
28
|
};
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
[nutritionalField]: value
|
|
47
|
-
};
|
|
48
|
-
return {
|
|
49
|
-
...ingredient,
|
|
50
|
-
nutritionalFields: updatedFields
|
|
51
|
-
};
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
/**
|
|
55
|
-
* Removes a nutritional field from the ingredient.
|
|
56
|
-
*
|
|
57
|
-
* @param ingredient - The ingredient to update.
|
|
58
|
-
* @param nutritionalField - The nutritional field to remove.
|
|
59
|
-
* @returns A new NutritionRecordIngredient with the nutritional field removed.
|
|
60
|
-
*/
|
|
61
|
-
function withoutNutritionalField(ingredient, nutritionalField) {
|
|
62
|
-
if (!ingredient.nutritionalFields) {
|
|
63
|
-
return ingredient;
|
|
64
|
-
}
|
|
65
|
-
const updatedFields = {
|
|
66
|
-
...ingredient.nutritionalFields
|
|
67
|
-
};
|
|
68
|
-
delete updatedFields[nutritionalField];
|
|
69
|
-
return {
|
|
70
|
-
...ingredient,
|
|
71
|
-
nutritionalFields: Object.keys(updatedFields).length > 0 ? updatedFields : null
|
|
72
|
-
};
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Updates the serving size and proportionally scales all nutritional field values.
|
|
77
|
-
*
|
|
78
|
-
* If the current serving size is zero or negative, only the serving size is updated
|
|
79
|
-
* without scaling nutritional values. Otherwise, all nutritional field values are
|
|
80
|
-
* scaled by the ratio of the new serving size to the old serving size.
|
|
81
|
-
*
|
|
82
|
-
* @param ingredient - The ingredient to update.
|
|
83
|
-
* @param newServingSize - The new serving size in metric units.
|
|
84
|
-
* @returns A new NutritionRecordIngredient with the updated serving size and scaled nutritional fields.
|
|
85
|
-
*/
|
|
86
|
-
function withScaledServingSize(ingredient, newServingSize) {
|
|
87
|
-
const oldServingSize = ingredient.servingSize;
|
|
88
|
-
if (oldServingSize <= 0) {
|
|
29
|
+
},
|
|
30
|
+
/**
|
|
31
|
+
* Sets the value for a specific nutritional field.
|
|
32
|
+
*
|
|
33
|
+
* @param ingredient - The ingredient to update.
|
|
34
|
+
* @param nutritionalField - The nutritional field to set.
|
|
35
|
+
* @param value - The value to set for the nutritional field.
|
|
36
|
+
* @returns A new NutritionRecordIngredient with the nutritional field set.
|
|
37
|
+
*/
|
|
38
|
+
withNutritionalField(ingredient, nutritionalField, value) {
|
|
39
|
+
const updatedFields = {
|
|
40
|
+
...(ingredient.nutritionalFields ?? {}),
|
|
41
|
+
[nutritionalField]: value
|
|
42
|
+
};
|
|
89
43
|
return {
|
|
90
44
|
...ingredient,
|
|
91
|
-
|
|
45
|
+
nutritionalFields: updatedFields
|
|
92
46
|
};
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
47
|
+
},
|
|
48
|
+
/**
|
|
49
|
+
* Removes a nutritional field from the ingredient.
|
|
50
|
+
*
|
|
51
|
+
* @param ingredient - The ingredient to update.
|
|
52
|
+
* @param nutritionalField - The nutritional field to remove.
|
|
53
|
+
* @returns A new NutritionRecordIngredient with the nutritional field removed.
|
|
54
|
+
*/
|
|
55
|
+
withoutNutritionalField(ingredient, nutritionalField) {
|
|
56
|
+
if (!ingredient.nutritionalFields) {
|
|
57
|
+
return ingredient;
|
|
100
58
|
}
|
|
59
|
+
const updatedFields = {
|
|
60
|
+
...ingredient.nutritionalFields
|
|
61
|
+
};
|
|
62
|
+
delete updatedFields[nutritionalField];
|
|
63
|
+
return {
|
|
64
|
+
...ingredient,
|
|
65
|
+
nutritionalFields: Object.keys(updatedFields).length > 0 ? updatedFields : null
|
|
66
|
+
};
|
|
67
|
+
},
|
|
68
|
+
/**
|
|
69
|
+
* Updates the serving size and proportionally scales all nutritional field values.
|
|
70
|
+
*
|
|
71
|
+
* If the current serving size is zero or negative, only the serving size is updated
|
|
72
|
+
* without scaling nutritional values. Otherwise, all nutritional field values are
|
|
73
|
+
* scaled by the ratio of the new serving size to the old serving size.
|
|
74
|
+
*
|
|
75
|
+
* @param ingredient - The ingredient to update.
|
|
76
|
+
* @param newServingSize - The new serving size in metric units.
|
|
77
|
+
* @returns A new NutritionRecordIngredient with the updated serving size and scaled nutritional fields.
|
|
78
|
+
*/
|
|
79
|
+
withScaledServingSize(ingredient, newServingSize) {
|
|
80
|
+
const oldServingSize = ingredient.servingSize;
|
|
81
|
+
if (oldServingSize <= 0) {
|
|
82
|
+
return {
|
|
83
|
+
...ingredient,
|
|
84
|
+
servingSize: newServingSize
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
const ratio = newServingSize / oldServingSize;
|
|
88
|
+
let scaledFields = null;
|
|
89
|
+
if (ingredient.nutritionalFields) {
|
|
90
|
+
scaledFields = {};
|
|
91
|
+
for (const [key, value] of Object.entries(ingredient.nutritionalFields)) {
|
|
92
|
+
scaledFields[key] = value * ratio;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
return {
|
|
96
|
+
...ingredient,
|
|
97
|
+
servingSize: newServingSize,
|
|
98
|
+
nutritionalFields: scaledFields
|
|
99
|
+
};
|
|
101
100
|
}
|
|
102
|
-
|
|
103
|
-
...ingredient,
|
|
104
|
-
servingSize: newServingSize,
|
|
105
|
-
nutritionalFields: scaledFields
|
|
106
|
-
};
|
|
107
|
-
}
|
|
101
|
+
};
|
|
108
102
|
//# sourceMappingURL=NutritionRecordIngredientUtils.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NutritionRecordIngredientUtils","exports","create","options","name","nameTranslated","servingSize","unit","nutritionalFields","withNutritionalField","ingredient","nutritionalField","value","updatedFields","withoutNutritionalField","Object","keys","length","withScaledServingSize","newServingSize","oldServingSize","ratio","scaledFields","key","entries"],"sourceRoot":"../../../../src","sources":["v3/Utils/NutritionRecordIngredientUtils.ts"],"mappings":"
|
|
1
|
+
{"version":3,"names":["NutritionRecordIngredientUtils","exports","create","options","name","nameTranslated","servingSize","unit","nutritionalFields","withNutritionalField","ingredient","nutritionalField","value","updatedFields","withoutNutritionalField","Object","keys","length","withScaledServingSize","newServingSize","oldServingSize","ratio","scaledFields","key","entries"],"sourceRoot":"../../../../src","sources":["v3/Utils/NutritionRecordIngredientUtils.ts"],"mappings":";;;;;;AAIA;AACA;AACA;;AAYA;AACA;AACA;AACO,MAAMA,8BAA8B,GAAAC,OAAA,CAAAD,8BAAA,GAAG;EAC1C;AACJ;AACA;AACA;AACA;AACA;EACIE,MAAMA,CAACC,OAA+C,EAA6B;IAC/E,OAAO;MACHC,IAAI,EAAED,OAAO,CAACC,IAAI;MAClBC,cAAc,EAAEF,OAAO,CAACE,cAAc,IAAI,IAAI;MAC9CC,WAAW,EAAEH,OAAO,CAACG,WAAW;MAChCC,IAAI,EAAEJ,OAAO,CAACI,IAAI;MAClBC,iBAAiB,EAAE;IACvB,CAAC;EACL,CAAC;EAED;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;EACIC,oBAAoBA,CAChBC,UAAqC,EACrCC,gBAAkC,EAClCC,KAAa,EACY;IACzB,MAAMC,aAAa,GAAG;MAAE,IAAIH,UAAU,CAACF,iBAAiB,IAAI,CAAC,CAAC,CAAC;MAAE,CAACG,gBAAgB,GAAGC;IAAM,CAAC;IAC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perty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.NutritionRecordUtils = void 0;
|
|
7
|
-
exports.withIngredient = withIngredient;
|
|
8
|
-
exports.withServingSize = withServingSize;
|
|
9
|
-
exports.withoutIngredient = withoutIngredient;
|
|
10
7
|
/**
|
|
11
8
|
* Generates a random UUID v4 string.
|
|
12
9
|
* This is a simple implementation that doesn't require external dependencies.
|
|
@@ -56,59 +53,56 @@ const NutritionRecordUtils = exports.NutritionRecordUtils = {
|
|
|
56
53
|
consumedAt: options.consumedAt ?? null,
|
|
57
54
|
userTimeOffsetMinutes: null
|
|
58
55
|
};
|
|
56
|
+
},
|
|
57
|
+
/**
|
|
58
|
+
* Adds an ingredient to the nutrition record.
|
|
59
|
+
*
|
|
60
|
+
* After adding the ingredient, the nutritional fields and serving size are automatically
|
|
61
|
+
* recalculated based on all ingredients.
|
|
62
|
+
*
|
|
63
|
+
* @param record - The nutrition record to add the ingredient to.
|
|
64
|
+
* @param ingredient - The ingredient to add.
|
|
65
|
+
* @returns A new NutritionRecord with the ingredient added and values recalculated.
|
|
66
|
+
*/
|
|
67
|
+
withIngredient(record, ingredient) {
|
|
68
|
+
const updatedIngredients = [...(record.ingredients ?? []), ingredient];
|
|
69
|
+
return recalculateValuesFromIngredients(record, updatedIngredients);
|
|
70
|
+
},
|
|
71
|
+
/**
|
|
72
|
+
* Removes an ingredient from the nutrition record.
|
|
73
|
+
*
|
|
74
|
+
* All matching ingredients (based on deep equality) are removed.
|
|
75
|
+
* After removing the ingredient, the nutritional fields and serving size are automatically
|
|
76
|
+
* recalculated based on the remaining ingredients.
|
|
77
|
+
*
|
|
78
|
+
* @param record - The nutrition record to remove the ingredient from.
|
|
79
|
+
* @param ingredient - The ingredient to remove.
|
|
80
|
+
* @returns A new NutritionRecord with the ingredient removed and values recalculated.
|
|
81
|
+
*/
|
|
82
|
+
withoutIngredient(record, ingredient) {
|
|
83
|
+
const updatedIngredients = (record.ingredients ?? []).filter(ing => !isIngredientEqual(ing, ingredient));
|
|
84
|
+
return recalculateValuesFromIngredients(record, updatedIngredients);
|
|
85
|
+
},
|
|
86
|
+
/**
|
|
87
|
+
* Updates the serving size and unit for the nutrition record.
|
|
88
|
+
*
|
|
89
|
+
* This will not recalculate serving sizes nor nutritional fields in ingredients.
|
|
90
|
+
* This will not recalculate nutritionalFields (use `SpikeRNConnectionAPIv3.updateNutritionRecordServingSize()` instead).
|
|
91
|
+
*
|
|
92
|
+
* @param record - The nutrition record to update.
|
|
93
|
+
* @param servingSize - The new serving size in metric units.
|
|
94
|
+
* @param unit - The new metric unit (g for solids, ml for liquids).
|
|
95
|
+
* @returns A new NutritionRecord with the updated serving size and unit.
|
|
96
|
+
*/
|
|
97
|
+
withServingSize(record, servingSize, unit) {
|
|
98
|
+
return {
|
|
99
|
+
...record,
|
|
100
|
+
servingSize,
|
|
101
|
+
unit
|
|
102
|
+
};
|
|
59
103
|
}
|
|
60
104
|
};
|
|
61
105
|
|
|
62
|
-
/**
|
|
63
|
-
* Adds an ingredient to the nutrition record.
|
|
64
|
-
*
|
|
65
|
-
* After adding the ingredient, the nutritional fields and serving size are automatically
|
|
66
|
-
* recalculated based on all ingredients.
|
|
67
|
-
*
|
|
68
|
-
* @param record - The nutrition record to add the ingredient to.
|
|
69
|
-
* @param ingredient - The ingredient to add.
|
|
70
|
-
* @returns A new NutritionRecord with the ingredient added and values recalculated.
|
|
71
|
-
*/
|
|
72
|
-
function withIngredient(record, ingredient) {
|
|
73
|
-
const updatedIngredients = [...(record.ingredients ?? []), ingredient];
|
|
74
|
-
return recalculateValuesFromIngredients(record, updatedIngredients);
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
/**
|
|
78
|
-
* Removes an ingredient from the nutrition record.
|
|
79
|
-
*
|
|
80
|
-
* All matching ingredients (based on deep equality) are removed.
|
|
81
|
-
* After removing the ingredient, the nutritional fields and serving size are automatically
|
|
82
|
-
* recalculated based on the remaining ingredients.
|
|
83
|
-
*
|
|
84
|
-
* @param record - The nutrition record to remove the ingredient from.
|
|
85
|
-
* @param ingredient - The ingredient to remove.
|
|
86
|
-
* @returns A new NutritionRecord with the ingredient removed and values recalculated.
|
|
87
|
-
*/
|
|
88
|
-
function withoutIngredient(record, ingredient) {
|
|
89
|
-
const updatedIngredients = (record.ingredients ?? []).filter(ing => !isIngredientEqual(ing, ingredient));
|
|
90
|
-
return recalculateValuesFromIngredients(record, updatedIngredients);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* Updates the serving size and unit for the nutrition record.
|
|
95
|
-
*
|
|
96
|
-
* This will not recalculate serving sizes nor nutritional fields in ingredients.
|
|
97
|
-
* This will not recalculate nutritionalFields (use `SpikeRNConnectionAPIv3.updateNutritionRecordServingSize()` instead).
|
|
98
|
-
*
|
|
99
|
-
* @param record - The nutrition record to update.
|
|
100
|
-
* @param servingSize - The new serving size in metric units.
|
|
101
|
-
* @param unit - The new metric unit (g for solids, ml for liquids).
|
|
102
|
-
* @returns A new NutritionRecord with the updated serving size and unit.
|
|
103
|
-
*/
|
|
104
|
-
function withServingSize(record, servingSize, unit) {
|
|
105
|
-
return {
|
|
106
|
-
...record,
|
|
107
|
-
servingSize,
|
|
108
|
-
unit
|
|
109
|
-
};
|
|
110
|
-
}
|
|
111
|
-
|
|
112
106
|
/**
|
|
113
107
|
* Recalculates nutritional fields and serving size based on all ingredients.
|
|
114
108
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["generateUUID","replace","c","r","Math","random","v","toString","NutritionRecordUtils","exports","create","options","now","Date","toISOString","recordId","dishName","dishDescription","dishNameTranslated","dishDescriptionTranslated","nutriScore","servingSize","unit","nutritionalFields","ingredients","uploadedAt","modifiedAt","consumedAt","userTimeOffsetMinutes","withIngredient","record","ingredient","updatedIngredients","recalculateValuesFromIngredients","withoutIngredient","filter","ing","isIngredientEqual","withServingSize","length","summedFields","totalServingSize","key","value","Object","entries","keys","a","b","name","nameTranslated","JSON","stringify"],"sourceRoot":"../../../../src","sources":["v3/Utils/NutritionRecordUtils.ts"],"mappings":"
|
|
1
|
+
{"version":3,"names":["generateUUID","replace","c","r","Math","random","v","toString","NutritionRecordUtils","exports","create","options","now","Date","toISOString","recordId","dishName","dishDescription","dishNameTranslated","dishDescriptionTranslated","nutriScore","servingSize","unit","nutritionalFields","ingredients","uploadedAt","modifiedAt","consumedAt","userTimeOffsetMinutes","withIngredient","record","ingredient","updatedIngredients","recalculateValuesFromIngredients","withoutIngredient","filter","ing","isIngredientEqual","withServingSize","length","summedFields","totalServingSize","key","value","Object","entries","keys","a","b","name","nameTranslated","JSON","stringify"],"sourceRoot":"../../../../src","sources":["v3/Utils/NutritionRecordUtils.ts"],"mappings":";;;;;;AAIA;AACA;AACA;AACA;AACA,SAASA,YAAYA,CAAA,EAAW;EAC5B,OAAO,sCAAsC,CAACC,OAAO,CAAC,OAAO,EAAGC,CAAC,IAAK;IAClE,MAAMC,CAAC,GAAIC,IAAI,CAACC,MAAM,CAAC,CAAC,GAAG,EAAE,GAAI,CAAC;IAClC,MAAMC,CAAC,GAAGJ,CAAC,KAAK,GAAG,GAAGC,CAAC,GAAIA,CAAC,GAAG,GAAG,GAAI,GAAG;IACzC,OAAOG,CAAC,CAACC,QAAQ,CAAC,EAAE,CAAC;EACzB,CAAC,CAAC;AACN;;AAEA;AACA;AACA;;AAkBA;AACA;AACA;AACO,MAAMC,oBAAoB,GAAAC,OAAA,CAAAD,oBAAA,GAAG;EAChC;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACIE,MAAMA,CAACC,OAAqC,GAAG,CAAC,CAAC,EAAmB;IAChE,MAAMC,GAAG,GAAG,IAAIC,IAAI,CAAC,CAAC,CAACC,WAAW,CAAC,CAAC;IACpC,OAAO;MACHC,QAAQ,EAAEf,YAAY,CAAC,CAAC;MAAE;MAC1BgB,QAAQ,EAAEL,OAAO,CAACK,QAAQ,IAAI,IAAI;MAClCC,eAAe,E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CAAC3B,WAAW,IAC/B0B,CAAC,CAACzB,IAAI,KAAK0B,CAAC,CAAC1B,IAAI,IACjB6B,IAAI,CAACC,SAAS,CAACL,CAAC,CAACxB,iBAAiB,CAAC,KAAK4B,IAAI,CAACC,SAAS,CAACJ,CAAC,CAACzB,iBAAiB,CAAC;AAEnF","ignoreList":[]}
|
package/lib/commonjs/version.js
CHANGED
|
@@ -5,5 +5,5 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.SPIKE_SDK_VERSION = void 0;
|
|
7
7
|
// This file is auto-generated. Do not edit manually.
|
|
8
|
-
const SPIKE_SDK_VERSION = exports.SPIKE_SDK_VERSION = "4.3.
|
|
8
|
+
const SPIKE_SDK_VERSION = exports.SPIKE_SDK_VERSION = "4.3.223";
|
|
9
9
|
//# sourceMappingURL=version.js.map
|
package/lib/module/index.js
CHANGED
|
@@ -40,13 +40,13 @@ import { NutritionRecordStatus } from './v3/DataModels/NutritionRecordStatus';
|
|
|
40
40
|
import { NutritionRecordAnalysisMode } from './v3/DataModels/NutritionRecordAnalysisMode';
|
|
41
41
|
import { NutritionalField } from './v3/DataModels/NutritionalField';
|
|
42
42
|
import { NutritionalUnit } from './v3/DataModels/NutritionalUnit';
|
|
43
|
-
import { NutritionRecordUtils
|
|
44
|
-
import { NutritionRecordIngredientUtils
|
|
43
|
+
import { NutritionRecordUtils } from './v3/Utils/NutritionRecordUtils';
|
|
44
|
+
import { NutritionRecordIngredientUtils } from './v3/Utils/NutritionRecordIngredientUtils';
|
|
45
45
|
export { SpikeRNConnectionAPIv3, StatisticsFilter, ActivityAdditionalData, ActivityCategory, ActivityConfig, ActivityTag, ActivityType, HealthConnectAvailabilityStatus, HealthConnectFeature, SamsungHealthDataAvailabilityStatus, InputMethod, LogLevel, MetricType, Provider, ProviderSource, SleepConfig, StatisticsInterval, StatisticsType, Unit,
|
|
46
46
|
// Nutrition AI
|
|
47
47
|
NutritionRecordStatus, NutritionRecordAnalysisMode, NutritionalField, NutritionalUnit,
|
|
48
48
|
// Nutrition Record Utils
|
|
49
|
-
NutritionRecordUtils,
|
|
49
|
+
NutritionRecordUtils,
|
|
50
50
|
// Nutrition Record Ingredient Utils
|
|
51
|
-
NutritionRecordIngredientUtils
|
|
51
|
+
NutritionRecordIngredientUtils };
|
|
52
52
|
//# sourceMappingURL=index.js.map
|
package/lib/module/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["SpikeDataTypes","createConnection","getBackgroundConnections","ensurePermissionsAreGranted","isPackageInstalled","isHealthDataAvailable","setLogCallback","createConnectionAPIv3","createConnectionAPIv3Legacy","SpikeConnection","SpikeException","SpikeConnectionIsClosedException","SpikeInvalidCredentialsException","SpikeInvalidDateRangeException","SpikeInvalidCallbackUrlException","SpikePackException","SpikePermissionsNotGrantedException","SpikeServerException","SpikeUnpackException","SpikeCallbackURLNotProvidedException","SpikeRNConnectionAPIv3","ActivityTag","ActivityType","ActivityCategory","InputMethod","MetricType","Provider","ProviderSource","StatisticsType","StatisticsInterval","Unit","StatisticsFilter","HealthConnectAvailabilityStatus","HealthConnectFeature","SamsungHealthDataAvailabilityStatus","ActivityAdditionalData","ActivityConfig","SleepConfig","LogLevel","NutritionRecordStatus","NutritionRecordAnalysisMode","NutritionalField","NutritionalUnit","NutritionRecordUtils","
|
|
1
|
+
{"version":3,"names":["SpikeDataTypes","createConnection","getBackgroundConnections","ensurePermissionsAreGranted","isPackageInstalled","isHealthDataAvailable","setLogCallback","createConnectionAPIv3","createConnectionAPIv3Legacy","SpikeConnection","SpikeException","SpikeConnectionIsClosedException","SpikeInvalidCredentialsException","SpikeInvalidDateRangeException","SpikeInvalidCallbackUrlException","SpikePackException","SpikePermissionsNotGrantedException","SpikeServerException","SpikeUnpackException","SpikeCallbackURLNotProvidedException","SpikeRNConnectionAPIv3","ActivityTag","ActivityType","ActivityCategory","InputMethod","MetricType","Provider","ProviderSource","StatisticsType","StatisticsInterval","Unit","StatisticsFilter","HealthConnectAvailabilityStatus","HealthConnectFeature","SamsungHealthDataAvailabilityStatus","ActivityAdditionalData","ActivityConfig","SleepConfig","LogLevel","NutritionRecordStatus","NutritionRecordAnalysisMode","NutritionalField","NutritionalUnit","NutritionRecordUtils","NutritionRecordIngredientUtils"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;AAAA,SAASA,cAAc,QAAQ,6BAA6B;AAE5D,SACEC,gBAAgB,EAChBC,wBAAwB,EACxBC,2BAA2B,EAC3BC,kBAAkB,EAClBC,qBAAqB,EACrBC,cAAc,EAGdC,qBAAqB,EACrBC,2BAA2B,QACtB,SAAS;AAChB,SAASC,eAAe,QAAQ,mBAAmB;AAInD,SACEC,cAAc,EACdC,gCAAgC,EAChCC,gCAAgC,EAChCC,8BAA8B,EAC9BC,gCAAgC,EAChCC,kBAAkB,EAClBC,mCAAmC,EACnCC,oBAAoB,EACpBC,oBAAoB,EACpBC,oCAAoC,QAC/B,kBAAkB;AAazB,eAAe;EACblB,gBAAgB;EAChBC,wBAAwB;EACxBC,2BAA2B;EAC3BC,kBAAkB;EAClBC,qBAAqB;EACrB;EACAE,qBAAqB;EACrBC,2BAA2B;EAC3BF;AACF,CAAC;AACD,SACEG,eAAe,EACfT,cAAc,EAKdU,cAAc,EACdC,gCAAgC,EAChCC,gCAAgC,EAChCC,8BAA8B,EAC9BC,gCAAgC,EAChCC,kBAAkB,EAClBC,mCAAmC,EACnCC,oBAAoB,EACpBC,oBAAoB,EACpBC,oCAAoC;AAmBtC;AACA,SAASC,sBAAsB,QAAgD,6BAA6B;AAC5G,SAASC,WAAW,QAAQ,6BAA6B;AACzD,SAASC,YAAY,QAAQ,8BAA8B;AAC3D,SAASC,gBAAgB,QAAQ,kCAAkC;AACnE,SAASC,WAAW,QAAQ,6BAA6B;AACzD,SAASC,UAAU,QAAQ,4BAA4B;AACvD,SAASC,QAAQ,QAAQ,0BAA0B;AACnD,SAASC,cAAc,QAAQ,gCAAgC;AAC/D,SAASC,cAAc,QAAQ,gCAAgC;AAC/D,SAASC,kBAAkB,QAAQ,oCAAoC;AACvE,SAASC,IAAI,QAAQ,sBAAsB;AAC3C,SAASC,gBAAgB,QAA+C,uBAAuB;AAC/F,SAASC,+BAA+B,QAAQ,iDAAiD;AACjG,SAASC,oBAAoB,QAAQ,sCAAsC;AAC3E,SAASC,mCAAmC,QAAQ,qDAAqD;AACzG,SAASC,sBAAsB,QAAQ,wCAAwC;AAC/E,SAASC,cAAc,QAA4C,gCAAgC;AAInG,SAASC,WAAW,QAAyC,6BAA6B;AAQ1F,SAASC,QAAQ,QAAQ,0BAA0B;AAInD,SAASC,qBAAqB,QAAQ,uCAAuC;AAC7E,SAASC,2BAA2B,QAAQ,6CAA6C;AAEzF,SAASC,gBAAgB,QAAQ,kCAAkC;AACnE,SAASC,eAAe,QAAQ,iCAAiC;AAGjE,SACEC,oBAAoB,QAEf,iCAAiC;AACxC,SACEC,8BAA8B,QAEzB,2CAA2C;AAElD,SACExB,sBAAsB,EACtBW,gBAAgB,EAChBI,sBAAsB,EACtBZ,gBAAgB,EAChBa,cAAc,EAGdf,WAAW,EACXC,YAAY,EACZU,+BAA+B,EAC/BC,oBAAoB,EACpBC,mCAAmC,EACnCV,WAAW,EACXc,QAAQ,EACRb,UAAU,EACVC,QAAQ,EACRC,cAAc,EAEdU,WAAW,EAGXR,kBAAkB,EAClBD,cAAc,EACdE,IAAI;AAIJ;AACAS,qBAAqB,EACrBC,2BAA2B,EAC3BC,gBAAgB,EAChBC,eAAe;AACf;AACAC,oBAAoB;AACpB;AACAC,8BAA8B","ignoreList":[]}
|
|
@@ -93,4 +93,10 @@ export let MetricType = /*#__PURE__*/function (MetricType) {
|
|
|
93
93
|
MetricType["unknown"] = "_unknown";
|
|
94
94
|
return MetricType;
|
|
95
95
|
}({});
|
|
96
|
+
(function (_MetricType) {
|
|
97
|
+
const availableForRecordsRequest = _MetricType.availableForRecordsRequest = [MetricType.stepsTotal, MetricType.caloriesBurnedActive, MetricType.caloriesBurnedBasal, MetricType.caloriesBurned, MetricType.distanceTotal, MetricType.distanceWalking, MetricType.distanceCycling, MetricType.distanceRunning, MetricType.weight, MetricType.height, MetricType.vo2Max, MetricType.heartrateMax, MetricType.heartrateMin, MetricType.heartrate, MetricType.heartrateResting, MetricType.heartrateRestingMin, MetricType.heartrateRestingMax, MetricType.hrvSdnn, MetricType.hrvRmssd, MetricType.spo2, MetricType.spo2Max, MetricType.spo2Min, MetricType.bodyTemperature, MetricType.bodyTemperatureMin, MetricType.bodyTemperatureMax, MetricType.skinTemperature, MetricType.skinTemperatureMin, MetricType.skinTemperatureMax, MetricType.basalBodyTemperature, MetricType.basalBodyTemperatureMin, MetricType.basalBodyTemperatureMax, MetricType.bodyMassIndex, MetricType.bodyBoneMass, MetricType.bodyFat, MetricType.bodyFatMax, MetricType.bodyFatMin, MetricType.bloodPressureSystolic, MetricType.bloodPressureSystolicMin, MetricType.bloodPressureSystolicMax, MetricType.bloodPressureDiastolic, MetricType.bloodPressureDiastolicMin, MetricType.bloodPressureDiastolicMax, MetricType.glucose, MetricType.cadence, MetricType.cadenceMin, MetricType.cadenceMax, MetricType.sleepSkinTemperatureDeviation];
|
|
98
|
+
const availableForActivitiesRequest = _MetricType.availableForActivitiesRequest = [MetricType.stepsTotal, MetricType.caloriesBurnedActive, MetricType.caloriesBurnedBasal, MetricType.caloriesBurned, MetricType.distanceTotal, MetricType.distanceWalking, MetricType.distanceCycling, MetricType.distanceRunning, MetricType.distanceSwimming, MetricType.heartrateMax, MetricType.heartrateMin, MetricType.heartrate, MetricType.heartrateResting, MetricType.hrvSdnn, MetricType.hrvRmssd, MetricType.elevationMax, MetricType.elevationMin, MetricType.elevationGain, MetricType.elevationLoss, MetricType.ascent, MetricType.descent, MetricType.floorsClimbed, MetricType.speed, MetricType.speedMax, MetricType.speedMin, MetricType.airTemperatureMax, MetricType.airTemperatureMin, MetricType.spo2, MetricType.spo2Max, MetricType.spo2Min, MetricType.longitude, MetricType.latitude, MetricType.elevation, MetricType.durationActive, MetricType.swimmingLengths, MetricType.swimmingDistancePerStroke, MetricType.vo2Max, MetricType.cadence, MetricType.cadenceMin, MetricType.cadenceMax, MetricType.pace];
|
|
99
|
+
const availableForSleepRequest = _MetricType.availableForSleepRequest = [MetricType.heartrate, MetricType.heartrateMin, MetricType.heartrateMax, MetricType.hrvSdnn, MetricType.hrvRmssd, MetricType.spo2, MetricType.spo2Max, MetricType.spo2Min, MetricType.breathingRate, MetricType.breathingRateMin, MetricType.breathingRateMax, MetricType.skinTemperature, MetricType.skinTemperatureMin, MetricType.skinTemperatureMax, MetricType.sleepScore, MetricType.sleepLatency, MetricType.sleepDuration, MetricType.sleepEfficiency, MetricType.sleepInterruptions, MetricType.sleepDurationNap, MetricType.sleepDurationRem, MetricType.sleepDurationDeep, MetricType.sleepDurationAwake, MetricType.sleepDurationLight];
|
|
100
|
+
const availableForPersonRequest = _MetricType.availableForPersonRequest = [MetricType.birthYear, MetricType.birthDate, MetricType.height, MetricType.weight, MetricType.timezone, MetricType.gender, MetricType.bodyFat, MetricType.bodyBoneMass, MetricType.bodyMassIndex];
|
|
101
|
+
})(MetricType || (MetricType = {}));
|
|
96
102
|
//# sourceMappingURL=MetricType.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["MetricType"],"sourceRoot":"../../../../src","sources":["v3/DataModels/MetricType.ts"],"mappings":";;AACA;AACA;AACA,WAAYA,UAAU,0BAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAA,OAAVA,UAAU;AAAA","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["MetricType","_MetricType","availableForRecordsRequest","stepsTotal","caloriesBurnedActive","caloriesBurnedBasal","caloriesBurned","distanceTotal","distanceWalking","distanceCycling","distanceRunning","weight","height","vo2Max","heartrateMax","heartrateMin","heartrate","heartrateResting","heartrateRestingMin","heartrateRestingMax","hrvSdnn","hrvRmssd","spo2","spo2Max","spo2Min","bodyTemperature","bodyTemperatureMin","bodyTemperatureMax","skinTemperature","skinTemperatureMin","skinTemperatureMax","basalBodyTemperature","basalBodyTemperatureMin","basalBodyTemperatureMax","bodyMassIndex","bodyBoneMass","bodyFat","bodyFatMax","bodyFatMin","bloodPressureSystolic","bloodPressureSystolicMin","bloodPressureSystolicMax","bloodPressureDiastolic","bloodPressureDiastolicMin","bloodPressureDiastolicMax","glucose","cadence","cadenceMin","cadenceMax","sleepSkinTemperatureDeviation","availableForActivitiesRequest","distanceSwimming","elevationMax","elevationMin","elevationGain","elevationLoss","ascent","descent","floorsClimbed","speed","speedMax","speedMin","airTemperatureMax","airTemperatureMin","longitude","latitude","elevation","durationActive","swimmingLengths","swimmingDistancePerStroke","pace","availableForSleepRequest","breathingRate","breathingRateMin","breathingRateMax","sleepScore","sleepLatency","sleepDuration","sleepEfficiency","sleepInterruptions","sleepDurationNap","sleepDurationRem","sleepDurationDeep","sleepDurationAwake","sleepDurationLight","availableForPersonRequest","birthYear","birthDate","timezone","gender"],"sourceRoot":"../../../../src","sources":["v3/DataModels/MetricType.ts"],"mappings":";;AACA;AACA;AACA,WAAYA,UAAU,0BAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAAU;EAAVA,UAA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