fix: compute macro targets dynamically from protein goal and body weight
All checks were successful
CI / update (push) Successful in 4m3s

Fat/carb percentages were stored as absolute values that didn't account
for protein g/kg varying with body weight. Now protein calories are
computed first, and remaining calories are split between fat and carbs
by their stored ratio — guaranteeing all macros sum to the calorie goal.

Exercise burned calories also flow into fat/carb targets via a new
effectiveCalorieGoal derived. Goal editor ring preview and labels
updated to show computed actual percentages.
This commit is contained in:
2026-04-10 08:01:00 +02:00
parent 89b3202dc5
commit 0ad72ddf24
4 changed files with 89 additions and 35 deletions

View File

@@ -1,6 +1,6 @@
{
"name": "homepage",
"version": "1.23.3",
"version": "1.23.4",
"private": true,
"type": "module",
"scripts": {