@burdenoff/microfe-mybodyshield 2026.827.1 → 2026.830.1

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 (90) hide show
  1. package/dist/mybodyshield/MyBodyShieldRoot.d.ts.map +1 -1
  2. package/dist/mybodyshield/MyBodyShieldRoot.js +54 -56
  3. package/dist/mybodyshield/MyBodyShieldRoot.js.map +1 -1
  4. package/dist/mybodyshield/MyBodyShieldRoutes.d.ts.map +1 -1
  5. package/dist/mybodyshield/MyBodyShieldRoutes.js +121 -62
  6. package/dist/mybodyshield/MyBodyShieldRoutes.js.map +1 -1
  7. package/dist/mybodyshield/components/EvidenceUpload.d.ts.map +1 -1
  8. package/dist/mybodyshield/components/EvidenceUpload.js +46 -45
  9. package/dist/mybodyshield/components/EvidenceUpload.js.map +1 -1
  10. package/dist/mybodyshield/components/FileLink.d.ts.map +1 -1
  11. package/dist/mybodyshield/components/FileLink.js +27 -18
  12. package/dist/mybodyshield/components/FileLink.js.map +1 -1
  13. package/dist/mybodyshield/components/MybDiscussion.d.ts +1 -1
  14. package/dist/mybodyshield/components/MybDiscussion.d.ts.map +1 -1
  15. package/dist/mybodyshield/components/MybDiscussion.js +59 -58
  16. package/dist/mybodyshield/components/MybDiscussion.js.map +1 -1
  17. package/dist/mybodyshield/components/MybTags.d.ts +1 -1
  18. package/dist/mybodyshield/components/MybTags.d.ts.map +1 -1
  19. package/dist/mybodyshield/components/MybTags.js +83 -74
  20. package/dist/mybodyshield/components/MybTags.js.map +1 -1
  21. package/dist/mybodyshield/components/PageDisabled.d.ts.map +1 -1
  22. package/dist/mybodyshield/components/PageDisabled.js +16 -11
  23. package/dist/mybodyshield/components/PageDisabled.js.map +1 -1
  24. package/dist/mybodyshield/components/Pagination.d.ts.map +1 -1
  25. package/dist/mybodyshield/components/Pagination.js +36 -27
  26. package/dist/mybodyshield/components/Pagination.js.map +1 -1
  27. package/dist/mybodyshield/components/StateViews.d.ts.map +1 -1
  28. package/dist/mybodyshield/components/StateViews.js +42 -34
  29. package/dist/mybodyshield/components/StateViews.js.map +1 -1
  30. package/dist/mybodyshield/components/UserSearchSelect.d.ts.map +1 -1
  31. package/dist/mybodyshield/components/UserSearchSelect.js +66 -68
  32. package/dist/mybodyshield/components/UserSearchSelect.js.map +1 -1
  33. package/dist/mybodyshield/hooks/index.d.ts +1 -0
  34. package/dist/mybodyshield/hooks/index.d.ts.map +1 -1
  35. package/dist/mybodyshield/hooks/index.js +1 -0
  36. package/dist/mybodyshield/hooks/useTr.d.ts +5 -0
  37. package/dist/mybodyshield/hooks/useTr.d.ts.map +1 -0
  38. package/dist/mybodyshield/hooks/useTr.js +12 -0
  39. package/dist/mybodyshield/hooks/useTr.js.map +1 -0
  40. package/dist/mybodyshield/pages/DashboardPage.d.ts.map +1 -1
  41. package/dist/mybodyshield/pages/DashboardPage.js +157 -136
  42. package/dist/mybodyshield/pages/DashboardPage.js.map +1 -1
  43. package/dist/mybodyshield/pages/SettingsPage.d.ts.map +1 -1
  44. package/dist/mybodyshield/pages/SettingsPage.js +50 -59
  45. package/dist/mybodyshield/pages/SettingsPage.js.map +1 -1
  46. package/dist/mybodyshield/pages/_shared/visuals.d.ts +2 -1
  47. package/dist/mybodyshield/pages/_shared/visuals.d.ts.map +1 -1
  48. package/dist/mybodyshield/pages/_shared/visuals.js +91 -81
  49. package/dist/mybodyshield/pages/_shared/visuals.js.map +1 -1
  50. package/dist/mybodyshield/pages/ai/AiControlsPage.d.ts.map +1 -1
  51. package/dist/mybodyshield/pages/ai/AiControlsPage.js +255 -266
  52. package/dist/mybodyshield/pages/ai/AiControlsPage.js.map +1 -1
  53. package/dist/mybodyshield/pages/coaching/CoachingPage.d.ts.map +1 -1
  54. package/dist/mybodyshield/pages/coaching/CoachingPage.js +321 -301
  55. package/dist/mybodyshield/pages/coaching/CoachingPage.js.map +1 -1
  56. package/dist/mybodyshield/pages/goals/GoalsPage.d.ts.map +1 -1
  57. package/dist/mybodyshield/pages/goals/GoalsPage.js +247 -251
  58. package/dist/mybodyshield/pages/goals/GoalsPage.js.map +1 -1
  59. package/dist/mybodyshield/pages/insights/InsightsCharts.d.ts.map +1 -1
  60. package/dist/mybodyshield/pages/insights/InsightsCharts.js +216 -213
  61. package/dist/mybodyshield/pages/insights/InsightsCharts.js.map +1 -1
  62. package/dist/mybodyshield/pages/insights/InsightsPage.d.ts.map +1 -1
  63. package/dist/mybodyshield/pages/insights/InsightsPage.js +290 -284
  64. package/dist/mybodyshield/pages/insights/InsightsPage.js.map +1 -1
  65. package/dist/mybodyshield/pages/nutrition/NutritionPage.d.ts.map +1 -1
  66. package/dist/mybodyshield/pages/nutrition/NutritionPage.js +575 -529
  67. package/dist/mybodyshield/pages/nutrition/NutritionPage.js.map +1 -1
  68. package/dist/mybodyshield/pages/programs/ProgramDetailPage.d.ts.map +1 -1
  69. package/dist/mybodyshield/pages/programs/ProgramDetailPage.js +333 -275
  70. package/dist/mybodyshield/pages/programs/ProgramDetailPage.js.map +1 -1
  71. package/dist/mybodyshield/pages/programs/ProgramsPage.d.ts.map +1 -1
  72. package/dist/mybodyshield/pages/programs/ProgramsPage.js +258 -253
  73. package/dist/mybodyshield/pages/programs/ProgramsPage.js.map +1 -1
  74. package/dist/mybodyshield/pages/progress/ProgressPage.d.ts.map +1 -1
  75. package/dist/mybodyshield/pages/progress/ProgressPage.js +271 -254
  76. package/dist/mybodyshield/pages/progress/ProgressPage.js.map +1 -1
  77. package/dist/mybodyshield/pages/recovery/RecoveryPage.d.ts.map +1 -1
  78. package/dist/mybodyshield/pages/recovery/RecoveryPage.js +206 -200
  79. package/dist/mybodyshield/pages/recovery/RecoveryPage.js.map +1 -1
  80. package/dist/mybodyshield/pages/train/SessionDetailPage.d.ts.map +1 -1
  81. package/dist/mybodyshield/pages/train/SessionDetailPage.js +327 -294
  82. package/dist/mybodyshield/pages/train/SessionDetailPage.js.map +1 -1
  83. package/dist/mybodyshield/pages/train/SessionsPage.d.ts.map +1 -1
  84. package/dist/mybodyshield/pages/train/SessionsPage.js +180 -163
  85. package/dist/mybodyshield/pages/train/SessionsPage.js.map +1 -1
  86. package/dist/mybodyshield/utils/i18n.d.ts +1 -2
  87. package/dist/mybodyshield/utils/i18n.d.ts.map +1 -1
  88. package/dist/mybodyshield/utils/i18n.js +15 -0
  89. package/dist/mybodyshield/utils/i18n.js.map +1 -0
  90. package/package.json +1 -1
@@ -2,24 +2,25 @@ import { PageLayout as e } from "../../components/PageLayout.js";
2
2
  import { formatDate as t, formatEnumLabel as n, formatGrams as r, formatKcal as ee, formatNumber as i, formatRelativeTime as a } from "../../utils/formatters.js";
3
3
  import { StatusBadge as te } from "../../components/StatusBadge.js";
4
4
  import { EmptyState as o } from "../../components/EmptyState.js";
5
- import { ErrorView as s, LoadingView as c, Section as ne } from "../../components/StateViews.js";
6
- import { DataTable as re } from "../../components/DataTable.js";
7
- import { FilterTabs as l } from "../../components/FilterTabs.js";
8
- import { Tabs as ie } from "../../components/Tabs.js";
9
- import { Pagination as ae } from "../../components/Pagination.js";
10
- import { useMybActivateNutritionPlan as oe, useMybActiveNutritionPlan as se, useMybCreateNutritionPlan as ce, useMybDailyMacros as le, useMybDeleteMeal as ue, useMybFoodByBarcode as de, useMybLogMeal as fe, useMybMeals as pe, useMybSearchFoods as me, useMybUpdateNutritionPlan as he } from "../../hooks/useMyBodyShieldApi.js";
11
- import { useOffsetPager as ge } from "../../hooks/usePager.js";
5
+ import { useMybActivateNutritionPlan as ne, useMybActiveNutritionPlan as s, useMybCreateNutritionPlan as re, useMybDailyMacros as ie, useMybDeleteMeal as ae, useMybFoodByBarcode as oe, useMybLogMeal as se, useMybMeals as ce, useMybSearchFoods as le, useMybUpdateNutritionPlan as ue } from "../../hooks/useMyBodyShieldApi.js";
6
+ import { useOffsetPager as de } from "../../hooks/usePager.js";
7
+ import { useTr as fe } from "../../hooks/useTr.js";
12
8
  import "../../hooks/index.js";
9
+ import { ErrorView as c, LoadingView as l, Section as pe } from "../../components/StateViews.js";
10
+ import { DataTable as me } from "../../components/DataTable.js";
11
+ import { FilterTabs as he } from "../../components/FilterTabs.js";
12
+ import { Tabs as ge } from "../../components/Tabs.js";
13
+ import { Pagination as _e } from "../../components/Pagination.js";
13
14
  import "../../components/index.js";
14
15
  import { motion as u } from "../../../node_modules/framer-motion/dist/es/render/components/motion/proxy.js";
15
- import { useReducedMotion as _e } from "../../../node_modules/framer-motion/dist/es/utils/reduced-motion/use-reduced-motion.js";
16
- import { IconChip as ve, MACRO_HUE as d, MacroBar as ye, Meter as be, ProgressRing as xe } from "../_shared/visuals.js";
17
- import { useMemo as Se, useState as f } from "react";
18
- import { Beef as Ce, Calendar as we, CheckCircle2 as Te, ClipboardList as Ee, Droplet as De, Flame as Oe, Pencil as ke, Plus as p, Salad as Ae, Star as m, Trash2 as je, UtensilsCrossed as Me, Wheat as Ne } from "lucide-react";
19
- import { Fragment as Pe, jsx as h, jsxs as g } from "react/jsx-runtime";
20
- import { Button as _, GlassCard as v, Input as y, Label as b, ResponsiveDialog as Fe, ResponsiveDialogContent as Ie, ResponsiveDialogDescription as Le, ResponsiveDialogFooter as Re, ResponsiveDialogHeader as ze, ResponsiveDialogTitle as Be, Select as Ve, SelectContent as He, SelectItem as Ue, SelectTrigger as We, SelectValue as Ge, Switch as Ke, Textarea as qe } from "@burdenoff/fe-libs/ui";
16
+ import { useReducedMotion as ve } from "../../../node_modules/framer-motion/dist/es/utils/reduced-motion/use-reduced-motion.js";
17
+ import { IconChip as ye, MACRO_HUE as d, MacroBar as be, Meter as xe, ProgressRing as Se } from "../_shared/visuals.js";
18
+ import { useMemo as Ce, useState as f } from "react";
19
+ import { Beef as we, Calendar as Te, CheckCircle2 as p, ClipboardList as Ee, Droplet as De, Flame as Oe, Pencil as ke, Plus as m, Salad as Ae, Star as h, Trash2 as je, UtensilsCrossed as Me, Wheat as Ne } from "lucide-react";
20
+ import { Fragment as Pe, jsx as g, jsxs as _ } from "react/jsx-runtime";
21
+ import { Button as v, GlassCard as y, Input as b, Label as x, ResponsiveDialog as Fe, ResponsiveDialogContent as Ie, ResponsiveDialogDescription as Le, ResponsiveDialogFooter as Re, ResponsiveDialogHeader as ze, ResponsiveDialogTitle as Be, Select as Ve, SelectContent as He, SelectItem as Ue, SelectTrigger as We, SelectValue as Ge, Switch as Ke, Textarea as qe } from "@burdenoff/fe-libs/ui";
21
22
  //#region src/mybodyshield/pages/nutrition/NutritionPage.tsx
22
- var x = 25, Je = [
23
+ var S = 25, Je = [
23
24
  "BREAKFAST",
24
25
  "LUNCH",
25
26
  "DINNER",
@@ -31,38 +32,45 @@ var x = 25, Je = [
31
32
  "ENDURANCE",
32
33
  "MOBILITY",
33
34
  "GENERAL_FITNESS"
34
- ], Xe = [
35
- {
36
- value: "today",
37
- label: "Today",
38
- icon: /* @__PURE__ */ h(Oe, { className: "h-4 w-4" })
39
- },
40
- {
41
- value: "plan",
42
- label: "Plan",
43
- icon: /* @__PURE__ */ h(Ee, { className: "h-4 w-4" })
44
- },
45
- {
46
- value: "meals",
47
- label: "Meals",
48
- icon: /* @__PURE__ */ h(Me, { className: "h-4 w-4" })
49
- }
50
- ], Ze = [{
51
- value: "ALL",
52
- label: "All"
53
- }, ...Je.map((e) => ({
54
- value: e,
55
- label: n(e)
56
- }))], S = (e) => {
35
+ ];
36
+ function Xe(e) {
37
+ return [
38
+ {
39
+ value: "today",
40
+ label: e("mybodyshield.pages.nutrition.today", "Today"),
41
+ icon: /* @__PURE__ */ g(Oe, { className: "h-4 w-4" })
42
+ },
43
+ {
44
+ value: "plan",
45
+ label: e("mybodyshield.pages.nutrition.plan", "Plan"),
46
+ icon: /* @__PURE__ */ g(Ee, { className: "h-4 w-4" })
47
+ },
48
+ {
49
+ value: "meals",
50
+ label: e("mybodyshield.pages.nutrition.meals", "Meals"),
51
+ icon: /* @__PURE__ */ g(Me, { className: "h-4 w-4" })
52
+ }
53
+ ];
54
+ }
55
+ function Ze(e) {
56
+ return [{
57
+ value: "ALL",
58
+ label: e("mybodyshield.common.all", "All")
59
+ }, ...Je.map((e) => ({
60
+ value: e,
61
+ label: n(e)
62
+ }))];
63
+ }
64
+ var C = (e) => {
57
65
  let t = e.trim();
58
66
  if (!t) return;
59
67
  let n = Number(t);
60
68
  return Number.isFinite(n) ? n : void 0;
61
- }, C = (e) => e ? String(e) : "", Qe = (e) => {
69
+ }, w = (e) => e ? String(e) : "", Qe = (e) => {
62
70
  if (!e) return "";
63
71
  let t = new Date(e);
64
72
  return Number.isNaN(t.getTime()) ? "" : t.toISOString().slice(0, 10);
65
- }, $e = (e) => e ? new Date(e).toISOString() : void 0, w = {
73
+ }, $e = (e) => e ? new Date(e).toISOString() : void 0, T = {
66
74
  name: "",
67
75
  mealType: "BREAKFAST",
68
76
  calories: "",
@@ -83,146 +91,146 @@ var x = 25, Je = [
83
91
  endDate: "",
84
92
  notes: ""
85
93
  };
86
- function T() {
87
- let [T, tt] = f("today"), E = _e(), D = le(), O = se(), k = pe({}), [A, nt] = f("ALL"), j = ge(x), M = pe({
88
- mealType: A === "ALL" ? void 0 : A,
94
+ function E() {
95
+ let E = fe(), [D, tt] = f("today"), O = ve(), nt = Xe(E), rt = Ze(E), k = ie(), A = s(), j = ce({}), [M, it] = f("ALL"), N = de(S), P = ce({
96
+ mealType: M === "ALL" ? void 0 : M,
89
97
  pagination: {
90
- limit: x,
91
- offset: j.offset
98
+ limit: S,
99
+ offset: N.offset
92
100
  }
93
- }), N = fe(), rt = ue(), it = ce(), at = he(), P = oe(), [ot, F] = f(null), [st, ct] = f(null), [lt, I] = f(null), [ut, L] = f(!1), [R, z] = f(w), [dt, B] = f(null), [V, ft] = f(""), H = me(V), [pt, mt] = f(""), [ht, U] = f(null), gt = de(), _t = (e) => {
94
- z({
95
- ...R,
101
+ }), F = se(), at = ae(), ot = re(), st = ue(), I = ne(), [ct, L] = f(null), [lt, ut] = f(null), [dt, ft] = f(null), [pt, R] = f(!1), [z, B] = f(T), [mt, V] = f(null), [ht, gt] = f(""), H = le(ht), [_t, vt] = f(""), [yt, U] = f(null), bt = oe(), xt = (e) => {
102
+ B({
103
+ ...z,
96
104
  name: e.name,
97
- calories: C(e.calories),
98
- proteinG: C(e.proteinG),
99
- carbsG: C(e.carbsG),
100
- fatG: C(e.fatG),
101
- servings: R.servings || "1",
105
+ calories: w(e.calories),
106
+ proteinG: w(e.proteinG),
107
+ carbsG: w(e.carbsG),
108
+ fatG: w(e.fatG),
109
+ servings: z.servings || "1",
102
110
  barcode: e.barcode ?? null
103
- }), ft("");
104
- }, vt = async () => {
105
- let e = pt.trim();
111
+ }), gt("");
112
+ }, St = async () => {
113
+ let e = _t.trim();
106
114
  if (e) {
107
115
  U(null);
108
116
  try {
109
- let t = await gt.mutateAsync(e);
117
+ let t = await bt.mutateAsync(e);
110
118
  if (!t) {
111
- U(`No product found for barcode ${e}.`);
119
+ U(E("mybodyshield.pages.nutrition.noProductForBarcode", "No product found for barcode {{barcode}}.", { barcode: e }));
112
120
  return;
113
121
  }
114
- _t(t), mt("");
122
+ xt(t), vt("");
115
123
  } catch (e) {
116
- U(e instanceof Error ? e.message : "Barcode lookup failed.");
124
+ U(e instanceof Error ? e.message : E("mybodyshield.pages.nutrition.barcodeLookupFailed", "Barcode lookup failed."));
117
125
  }
118
126
  }
119
- }, [yt, W] = f(!1), [G, bt] = f("create"), [K, q] = f(et), [xt, J] = f(null), St = O.data ?? null, Y = lt ?? St, X = Se(() => {
120
- let e = k.data?.items ?? [], t = (/* @__PURE__ */ new Date()).toDateString();
127
+ }, [Ct, W] = f(!1), [G, wt] = f("create"), [K, q] = f(et), [Tt, J] = f(null), Et = A.data ?? null, Y = dt ?? Et, Dt = Ce(() => {
128
+ let e = j.data?.items ?? [], t = (/* @__PURE__ */ new Date()).toDateString();
121
129
  return e.filter((e) => {
122
130
  let n = new Date(e.loggedAt);
123
131
  return !Number.isNaN(n.getTime()) && n.toDateString() === t;
124
132
  }).sort((e, t) => new Date(t.loggedAt).getTime() - new Date(e.loggedAt).getTime());
125
- }, [k.data]), Ct = M.data?.items ?? [], wt = (e) => {
126
- nt(e), j.reset();
127
- }, Z = () => {
128
- z(w), B(null), ft(""), mt(""), U(null), L(!0);
129
- }, Tt = () => {
130
- bt("create"), q(et), J(null), W(!0);
131
- }, Et = () => {
132
- Y && (bt("edit"), q({
133
+ }, [j.data]), Ot = P.data?.items ?? [], kt = (e) => {
134
+ it(e), N.reset();
135
+ }, X = () => {
136
+ B(T), V(null), gt(""), vt(""), U(null), R(!0);
137
+ }, At = () => {
138
+ wt("create"), q(et), J(null), W(!0);
139
+ }, jt = () => {
140
+ Y && (wt("edit"), q({
133
141
  name: Y.name,
134
142
  goalType: Y.goalType,
135
- calorieTarget: C(Y.calorieTarget),
136
- proteinTarget: C(Y.proteinTarget),
137
- carbsTarget: C(Y.carbsTarget),
138
- fatTarget: C(Y.fatTarget),
143
+ calorieTarget: w(Y.calorieTarget),
144
+ proteinTarget: w(Y.proteinTarget),
145
+ carbsTarget: w(Y.carbsTarget),
146
+ fatTarget: w(Y.fatTarget),
139
147
  startDate: Qe(Y.startDate),
140
148
  endDate: Qe(Y.endDate),
141
149
  notes: Y.notes ?? ""
142
150
  }), J(null), W(!0));
143
- }, Dt = async () => {
144
- if (!R.name.trim()) {
145
- B("Meal name is required.");
151
+ }, Mt = async () => {
152
+ if (!z.name.trim()) {
153
+ V(E("mybodyshield.pages.nutrition.mealNameRequired", "Meal name is required."));
146
154
  return;
147
155
  }
148
- B(null);
156
+ V(null);
149
157
  try {
150
- await N.mutateAsync({
151
- name: R.name.trim(),
152
- mealType: R.mealType,
153
- calories: S(R.calories),
154
- proteinG: S(R.proteinG),
155
- carbsG: S(R.carbsG),
156
- fatG: S(R.fatG),
157
- servings: S(R.servings),
158
- isFavorite: R.isFavorite,
158
+ await F.mutateAsync({
159
+ name: z.name.trim(),
160
+ mealType: z.mealType,
161
+ calories: C(z.calories),
162
+ proteinG: C(z.proteinG),
163
+ carbsG: C(z.carbsG),
164
+ fatG: C(z.fatG),
165
+ servings: C(z.servings),
166
+ isFavorite: z.isFavorite,
159
167
  planId: Y?.id ?? void 0,
160
168
  loggedAt: (/* @__PURE__ */ new Date()).toISOString(),
161
- barcode: R.barcode ?? void 0
162
- }), L(!1), z(w);
169
+ barcode: z.barcode ?? void 0
170
+ }), R(!1), B(T);
163
171
  } catch (e) {
164
- B(e instanceof Error ? e.message : "Failed to log meal.");
172
+ V(e instanceof Error ? e.message : E("mybodyshield.pages.nutrition.failedToLogMeal", "Failed to log meal."));
165
173
  }
166
- }, Ot = async () => {
174
+ }, Nt = async () => {
167
175
  if (!K.name.trim()) {
168
- J("Plan name is required.");
176
+ J(E("mybodyshield.pages.nutrition.planNameRequired", "Plan name is required."));
169
177
  return;
170
178
  }
171
179
  J(null);
172
180
  let e = {
173
181
  goalType: K.goalType,
174
- calorieTarget: S(K.calorieTarget),
175
- proteinTarget: S(K.proteinTarget),
176
- carbsTarget: S(K.carbsTarget),
177
- fatTarget: S(K.fatTarget),
182
+ calorieTarget: C(K.calorieTarget),
183
+ proteinTarget: C(K.proteinTarget),
184
+ carbsTarget: C(K.carbsTarget),
185
+ fatTarget: C(K.fatTarget),
178
186
  startDate: $e(K.startDate),
179
187
  endDate: $e(K.endDate),
180
188
  notes: K.notes.trim() || void 0
181
189
  };
182
190
  try {
183
191
  if (G === "edit" && Y) {
184
- let t = await at.mutateAsync({
192
+ let t = await st.mutateAsync({
185
193
  id: Y.id,
186
194
  input: {
187
195
  name: K.name.trim(),
188
196
  ...e
189
197
  }
190
198
  });
191
- I((e) => e && e.id === t.id ? t : e);
192
- } else I(await it.mutateAsync({
199
+ ft((e) => e && e.id === t.id ? t : e);
200
+ } else ft(await ot.mutateAsync({
193
201
  name: K.name.trim(),
194
202
  ...e
195
203
  })), tt("plan");
196
204
  W(!1);
197
205
  } catch (e) {
198
- J(e instanceof Error ? e.message : "Failed to save plan.");
206
+ J(e instanceof Error ? e.message : E("mybodyshield.pages.nutrition.failedToSavePlan", "Failed to save plan."));
199
207
  }
200
- }, kt = async (e) => {
201
- F(null);
208
+ }, Pt = async (e) => {
209
+ L(null);
202
210
  try {
203
- await P.mutateAsync(e), I(null);
211
+ await I.mutateAsync(e), ft(null);
204
212
  } catch (e) {
205
- F(e instanceof Error ? e.message : "Failed to activate plan.");
213
+ L(e instanceof Error ? e.message : E("mybodyshield.pages.nutrition.failedToActivatePlan", "Failed to activate plan."));
206
214
  }
207
- }, At = async (e) => {
208
- if (window.confirm("Delete this meal log? This cannot be undone.")) {
209
- ct(e), F(null);
215
+ }, Ft = async (e) => {
216
+ if (window.confirm(E("mybodyshield.pages.nutrition.deleteMealConfirm", "Delete this meal log? This cannot be undone."))) {
217
+ ut(e), L(null);
210
218
  try {
211
- await rt.mutateAsync(e);
219
+ await at.mutateAsync(e);
212
220
  } catch (e) {
213
- F(e instanceof Error ? e.message : "Failed to delete meal.");
221
+ L(e instanceof Error ? e.message : E("mybodyshield.pages.nutrition.failedToDeleteMeal", "Failed to delete meal."));
214
222
  } finally {
215
- ct(null);
223
+ ut(null);
216
224
  }
217
225
  }
218
- }, jt = G === "edit" ? at.isPending : it.isPending, Q = {
226
+ }, Z = G === "edit" ? st.isPending : ot.isPending, Q = {
219
227
  hidden: {},
220
228
  show: { transition: {
221
- staggerChildren: E ? 0 : .06,
222
- delayChildren: E ? 0 : .03
229
+ staggerChildren: O ? 0 : .06,
230
+ delayChildren: O ? 0 : .03
223
231
  } }
224
232
  }, $ = {
225
- hidden: E ? { opacity: 0 } : {
233
+ hidden: O ? { opacity: 0 } : {
226
234
  opacity: 0,
227
235
  y: 14
228
236
  },
@@ -230,100 +238,100 @@ function T() {
230
238
  opacity: 1,
231
239
  y: 0,
232
240
  transition: {
233
- duration: E ? .2 : .45,
241
+ duration: O ? .2 : .45,
234
242
  ease: "easeOut"
235
243
  }
236
244
  }
237
- }, Mt = [
245
+ }, It = [
238
246
  {
239
247
  key: "favorite",
240
- header: /* @__PURE__ */ h(m, {
248
+ header: /* @__PURE__ */ g(h, {
241
249
  className: "h-3.5 w-3.5 text-action-primary-bg",
242
250
  "aria-hidden": "true"
243
251
  }),
244
252
  align: "center",
245
253
  sortValue: (e) => +!!e.isFavorite,
246
- render: (e) => /* @__PURE__ */ g("span", {
254
+ render: (e) => /* @__PURE__ */ _("span", {
247
255
  className: "inline-flex",
248
- title: e.isFavorite ? "Favorite meal" : "Not a favorite",
249
- children: [/* @__PURE__ */ h(m, { className: `h-4 w-4 transition-colors ${e.isFavorite ? "fill-current text-action-primary-bg" : "text-text-tertiary"}` }), /* @__PURE__ */ h("span", {
256
+ title: e.isFavorite ? E("mybodyshield.pages.nutrition.favoriteMeal", "Favorite meal") : E("mybodyshield.pages.nutrition.notFavorite", "Not a favorite"),
257
+ children: [/* @__PURE__ */ g(h, { className: `h-4 w-4 transition-colors ${e.isFavorite ? "fill-current text-action-primary-bg" : "text-text-tertiary"}` }), /* @__PURE__ */ g("span", {
250
258
  className: "sr-only",
251
- children: e.isFavorite ? "Favorite" : "Not favorite"
259
+ children: e.isFavorite ? E("mybodyshield.pages.nutrition.favorite", "Favorite") : E("mybodyshield.pages.nutrition.notFavoriteShort", "Not favorite")
252
260
  })]
253
261
  })
254
262
  },
255
263
  {
256
264
  key: "name",
257
- header: "Meal",
258
- render: (e) => /* @__PURE__ */ h("span", {
265
+ header: E("mybodyshield.pages.nutrition.meal", "Meal"),
266
+ render: (e) => /* @__PURE__ */ g("span", {
259
267
  className: "font-medium text-text-primary",
260
268
  children: e.name
261
269
  })
262
270
  },
263
271
  {
264
272
  key: "mealType",
265
- header: "Type",
266
- render: (e) => /* @__PURE__ */ h(te, { status: e.mealType })
273
+ header: E("mybodyshield.pages.nutrition.mealType", "Type"),
274
+ render: (e) => /* @__PURE__ */ g(te, { status: e.mealType })
267
275
  },
268
276
  {
269
277
  key: "calories",
270
- header: "Calories",
278
+ header: E("mybodyshield.pages.nutrition.calories", "Calories"),
271
279
  align: "right",
272
280
  sortValue: (e) => e.calories,
273
- render: (e) => /* @__PURE__ */ h("span", {
281
+ render: (e) => /* @__PURE__ */ g("span", {
274
282
  className: "font-semibold tabular-nums text-text-primary",
275
283
  children: ee(e.calories)
276
284
  })
277
285
  },
278
286
  {
279
287
  key: "proteinG",
280
- header: "Protein",
288
+ header: E("mybodyshield.pages.nutrition.protein", "Protein"),
281
289
  align: "right",
282
290
  hideOnMobile: !0,
283
291
  sortValue: (e) => e.proteinG,
284
- render: (e) => /* @__PURE__ */ h("span", {
292
+ render: (e) => /* @__PURE__ */ g("span", {
285
293
  className: "tabular-nums text-text-secondary",
286
294
  children: r(e.proteinG)
287
295
  })
288
296
  },
289
297
  {
290
298
  key: "carbsG",
291
- header: "Carbs",
299
+ header: E("mybodyshield.pages.nutrition.carbs", "Carbs"),
292
300
  align: "right",
293
301
  hideOnMobile: !0,
294
302
  sortValue: (e) => e.carbsG,
295
- render: (e) => /* @__PURE__ */ h("span", {
303
+ render: (e) => /* @__PURE__ */ g("span", {
296
304
  className: "tabular-nums text-text-secondary",
297
305
  children: r(e.carbsG)
298
306
  })
299
307
  },
300
308
  {
301
309
  key: "fatG",
302
- header: "Fat",
310
+ header: E("mybodyshield.pages.nutrition.fat", "Fat"),
303
311
  align: "right",
304
312
  hideOnMobile: !0,
305
313
  sortValue: (e) => e.fatG,
306
- render: (e) => /* @__PURE__ */ h("span", {
314
+ render: (e) => /* @__PURE__ */ g("span", {
307
315
  className: "tabular-nums text-text-secondary",
308
316
  children: r(e.fatG)
309
317
  })
310
318
  },
311
319
  {
312
320
  key: "servings",
313
- header: "Servings",
321
+ header: E("mybodyshield.pages.nutrition.servingsLabel", "Servings"),
314
322
  align: "right",
315
323
  sortValue: (e) => e.servings,
316
- render: (e) => /* @__PURE__ */ h("span", {
324
+ render: (e) => /* @__PURE__ */ g("span", {
317
325
  className: "tabular-nums",
318
326
  children: i(e.servings)
319
327
  })
320
328
  },
321
329
  {
322
330
  key: "loggedAt",
323
- header: "Logged",
331
+ header: E("mybodyshield.pages.nutrition.logged", "Logged"),
324
332
  hideOnMobile: !0,
325
333
  sortValue: (e) => new Date(e.loggedAt).getTime(),
326
- render: (e) => /* @__PURE__ */ h("span", {
334
+ render: (e) => /* @__PURE__ */ g("span", {
327
335
  className: "text-text-secondary",
328
336
  children: a(e.loggedAt)
329
337
  })
@@ -332,121 +340,137 @@ function T() {
332
340
  key: "actions",
333
341
  header: "",
334
342
  align: "right",
335
- render: (e) => /* @__PURE__ */ h(_, {
343
+ render: (e) => /* @__PURE__ */ g(v, {
336
344
  variant: "ghost",
337
345
  size: "icon-sm",
338
- onClick: () => At(e.id),
339
- disabled: st === e.id,
340
- "aria-label": "Delete meal",
341
- children: /* @__PURE__ */ h(je, { className: "h-4 w-4 text-status-error-text" })
346
+ onClick: () => Ft(e.id),
347
+ disabled: lt === e.id,
348
+ "aria-label": E("mybodyshield.pages.nutrition.deleteMeal", "Delete meal"),
349
+ children: /* @__PURE__ */ g(je, { className: "h-4 w-4 text-status-error-text" })
342
350
  })
343
351
  }
344
- ];
345
- return /* @__PURE__ */ g(e, {
346
- title: "Nutrition",
347
- description: "Plans, meal logging and daily macro targets.",
348
- actions: T === "plan" ? /* @__PURE__ */ g("div", {
349
- className: "flex flex-wrap items-center gap-2",
350
- children: [Y && /* @__PURE__ */ g(_, {
351
- variant: "outline",
352
- onClick: Et,
353
- children: [/* @__PURE__ */ h(ke, { className: "mr-1.5 h-4 w-4" }), " Edit targets"]
354
- }), /* @__PURE__ */ g(_, {
355
- onClick: Tt,
356
- children: [/* @__PURE__ */ h(p, { className: "mr-1.5 h-4 w-4" }), " Create plan"]
357
- })]
358
- }) : /* @__PURE__ */ g(_, {
359
- onClick: Z,
360
- children: [/* @__PURE__ */ h(p, { className: "mr-1.5 h-4 w-4" }), " Log meal"]
361
- }),
352
+ ], Lt = D === "plan" ? /* @__PURE__ */ _("div", {
353
+ className: "flex flex-wrap items-center gap-2",
354
+ children: [Y && /* @__PURE__ */ _(v, {
355
+ variant: "outline",
356
+ onClick: jt,
357
+ children: [
358
+ /* @__PURE__ */ g(ke, { className: "mr-1.5 h-4 w-4" }),
359
+ " ",
360
+ E("mybodyshield.pages.nutrition.editTargets", "Edit targets")
361
+ ]
362
+ }), /* @__PURE__ */ _(v, {
363
+ onClick: At,
364
+ children: [
365
+ /* @__PURE__ */ g(m, { className: "mr-1.5 h-4 w-4" }),
366
+ " ",
367
+ E("mybodyshield.pages.nutrition.createPlan", "Create plan")
368
+ ]
369
+ })]
370
+ }) : /* @__PURE__ */ _(v, {
371
+ onClick: X,
362
372
  children: [
363
- /* @__PURE__ */ h(ie, {
364
- items: Xe,
365
- value: T,
373
+ /* @__PURE__ */ g(m, { className: "mr-1.5 h-4 w-4" }),
374
+ " ",
375
+ E("mybodyshield.pages.nutrition.logMeal", "Log meal")
376
+ ]
377
+ });
378
+ return /* @__PURE__ */ _(e, {
379
+ title: E("mybodyshield.pages.nutrition.title", "Nutrition"),
380
+ description: E("mybodyshield.pages.nutrition.description", "Plans, meal logging and daily macro targets."),
381
+ actions: Lt,
382
+ children: [
383
+ /* @__PURE__ */ g(ge, {
384
+ items: nt,
385
+ value: D,
366
386
  onChange: tt,
367
387
  className: "mb-6"
368
388
  }),
369
- ot && /* @__PURE__ */ h("div", {
389
+ ct && /* @__PURE__ */ g("div", {
370
390
  className: "mb-4 rounded-lg border border-status-error-text/40 bg-status-error-bg-subtle px-4 py-2 text-sm text-status-error-text",
371
- children: ot
391
+ children: ct
372
392
  }),
373
- T === "today" && (() => {
374
- if (D.isLoading) return /* @__PURE__ */ h(c, { label: "Loading today's nutrition…" });
375
- if (D.isError) return /* @__PURE__ */ h(s, {
376
- message: "We couldn't load your daily macros.",
377
- onRetry: () => D.refetch()
393
+ D === "today" && (() => {
394
+ if (k.isLoading) return /* @__PURE__ */ g(l, { label: E("mybodyshield.pages.nutrition.loadingToday", "Loading today's nutrition…") });
395
+ if (k.isError) return /* @__PURE__ */ g(c, {
396
+ message: E("mybodyshield.pages.nutrition.errorToday", "We couldn't load your daily macros."),
397
+ onRetry: () => k.refetch()
378
398
  });
379
- let e = D.data;
380
- if (!e) return /* @__PURE__ */ h(c, { label: "Loading today's nutrition…" });
381
- let t = e.calorieTarget > 0, n = e.calories > 0 || X.length > 0;
382
- if (!t && !n) return /* @__PURE__ */ h(o, {
399
+ let e = k.data;
400
+ if (!e) return /* @__PURE__ */ g(l, { label: E("mybodyshield.pages.nutrition.loadingToday", "Loading today's nutrition…") });
401
+ let t = e.calorieTarget > 0, n = e.calories > 0 || Dt.length > 0;
402
+ if (!t && !n) return /* @__PURE__ */ g(o, {
383
403
  illustration: "empty-data",
384
- icon: /* @__PURE__ */ h(Ae, { className: "h-10 w-10" }),
385
- title: "No nutrition tracked yet",
386
- description: "Activate a nutrition plan or log your first meal to start tracking daily macros.",
387
- action: /* @__PURE__ */ g(_, {
388
- onClick: Z,
389
- children: [/* @__PURE__ */ h(p, { className: "mr-1.5 h-4 w-4" }), " Log meal"]
404
+ icon: /* @__PURE__ */ g(Ae, { className: "h-10 w-10" }),
405
+ title: E("mybodyshield.pages.nutrition.noNutritionData", "No nutrition tracked yet"),
406
+ description: E("mybodyshield.pages.nutrition.noNutritionDescription", "Activate a nutrition plan or log your first meal to start tracking daily macros."),
407
+ action: /* @__PURE__ */ _(v, {
408
+ onClick: X,
409
+ children: [
410
+ /* @__PURE__ */ g(m, { className: "mr-1.5 h-4 w-4" }),
411
+ " ",
412
+ E("mybodyshield.pages.nutrition.logMeal", "Log meal")
413
+ ]
390
414
  })
391
415
  });
392
- let a = e.calorieTarget ? e.calories / e.calorieTarget * 100 : 0, re = Math.round(Math.max(0, Math.min(100, a))), l = [
416
+ let a = e.calorieTarget ? e.calories / e.calorieTarget * 100 : 0, ne = Math.round(Math.max(0, Math.min(100, a))), s = [
393
417
  {
394
- label: "Protein",
418
+ label: E("mybodyshield.pages.nutrition.protein", "Protein"),
395
419
  value: e.proteinG,
396
420
  target: e.proteinTarget,
397
421
  color: d.protein
398
422
  },
399
423
  {
400
- label: "Carbs",
424
+ label: E("mybodyshield.pages.nutrition.carbs", "Carbs"),
401
425
  value: e.carbsG,
402
426
  target: e.carbsTarget,
403
427
  color: d.carbs
404
428
  },
405
429
  {
406
- label: "Fat",
430
+ label: E("mybodyshield.pages.nutrition.fat", "Fat"),
407
431
  value: e.fatG,
408
432
  target: e.fatTarget,
409
433
  color: d.fat
410
434
  }
411
435
  ];
412
- return /* @__PURE__ */ g(u.div, {
436
+ return /* @__PURE__ */ _(u.div, {
413
437
  initial: "hidden",
414
438
  animate: "show",
415
439
  variants: Q,
416
440
  className: "space-y-6",
417
441
  children: [
418
- /* @__PURE__ */ h(u.div, {
442
+ /* @__PURE__ */ g(u.div, {
419
443
  variants: $,
420
- children: /* @__PURE__ */ g(v, {
444
+ children: /* @__PURE__ */ _(y, {
421
445
  treatment: "glass",
422
446
  glow: !0,
423
447
  className: "p-6 sm:p-7",
424
- children: [/* @__PURE__ */ g("div", {
448
+ children: [/* @__PURE__ */ _("div", {
425
449
  className: "mb-5",
426
- children: [/* @__PURE__ */ h("h2", {
450
+ children: [/* @__PURE__ */ g("h2", {
427
451
  className: "text-base font-semibold text-text-primary",
428
- children: "Today's macros"
429
- }), /* @__PURE__ */ h("p", {
452
+ children: E("mybodyshield.pages.nutrition.todaysMacros", "Today's macros")
453
+ }), /* @__PURE__ */ g("p", {
430
454
  className: "mt-0.5 text-sm text-text-secondary",
431
- children: "Calories & macros logged against your active plan."
455
+ children: E("mybodyshield.pages.nutrition.macrosDescription", "Calories & macros logged against your active plan.")
432
456
  })]
433
- }), /* @__PURE__ */ g("div", {
457
+ }), /* @__PURE__ */ _("div", {
434
458
  className: "flex flex-col items-center gap-6 sm:flex-row sm:items-center sm:gap-8",
435
- children: [/* @__PURE__ */ g("div", {
459
+ children: [/* @__PURE__ */ _("div", {
436
460
  className: "relative flex shrink-0 items-center justify-center",
437
- children: [/* @__PURE__ */ h("div", {
461
+ children: [/* @__PURE__ */ g("div", {
438
462
  "aria-hidden": "true",
439
463
  className: "pointer-events-none absolute inset-3 rounded-full blur-2xl",
440
464
  style: { background: "radial-gradient(circle, color-mix(in srgb, var(--color-action-primary-bg) 30%, transparent), transparent 68%)" }
441
- }), /* @__PURE__ */ g(xe, {
465
+ }), /* @__PURE__ */ _(Se, {
442
466
  value: a,
443
467
  size: 168,
444
468
  stroke: 14,
445
469
  className: "relative",
446
- children: [/* @__PURE__ */ h("span", {
470
+ children: [/* @__PURE__ */ g("span", {
447
471
  className: "text-3xl font-bold tabular-nums text-text-primary",
448
472
  children: i(e.calories)
449
- }), /* @__PURE__ */ g("span", {
473
+ }), /* @__PURE__ */ _("span", {
450
474
  className: "mt-0.5 text-xs text-text-tertiary",
451
475
  children: [
452
476
  "/ ",
@@ -455,45 +479,45 @@ function T() {
455
479
  ]
456
480
  })]
457
481
  })]
458
- }), /* @__PURE__ */ g("div", {
482
+ }), /* @__PURE__ */ _("div", {
459
483
  className: "flex w-full flex-1 flex-col gap-4",
460
- children: [/* @__PURE__ */ h(ye, {
484
+ children: [/* @__PURE__ */ g(be, {
461
485
  proteinG: e.proteinG,
462
486
  carbsG: e.carbsG,
463
487
  fatG: e.fatG,
464
488
  height: 12
465
- }), /* @__PURE__ */ g("div", {
489
+ }), /* @__PURE__ */ _("div", {
466
490
  className: "flex flex-col gap-4 sm:flex-row sm:items-stretch",
467
- children: [/* @__PURE__ */ h("div", {
491
+ children: [/* @__PURE__ */ g("div", {
468
492
  className: "flex-1 space-y-2.5",
469
- children: l.map((e) => /* @__PURE__ */ g("div", {
493
+ children: s.map((e) => /* @__PURE__ */ _("div", {
470
494
  className: "flex items-center justify-between gap-3",
471
- children: [/* @__PURE__ */ g("span", {
495
+ children: [/* @__PURE__ */ _("span", {
472
496
  className: "inline-flex items-center gap-2 text-sm text-text-secondary",
473
- children: [/* @__PURE__ */ h("span", {
497
+ children: [/* @__PURE__ */ g("span", {
474
498
  className: "h-2.5 w-2.5 rounded-full",
475
499
  style: { backgroundColor: e.color }
476
500
  }), e.label]
477
- }), /* @__PURE__ */ h("span", {
501
+ }), /* @__PURE__ */ g("span", {
478
502
  className: "text-sm font-semibold tabular-nums text-text-primary",
479
503
  children: r(e.value)
480
504
  })]
481
505
  }, e.label))
482
- }), /* @__PURE__ */ g("div", {
506
+ }), /* @__PURE__ */ _("div", {
483
507
  className: "flex flex-col justify-center rounded-2xl px-4 py-3 sm:min-w-[9rem]",
484
508
  style: { backgroundColor: "color-mix(in srgb, var(--color-action-primary-bg) 12%, transparent)" },
485
509
  children: [
486
- /* @__PURE__ */ h("span", {
510
+ /* @__PURE__ */ g("span", {
487
511
  className: "text-xs font-medium text-text-tertiary",
488
- children: "Calorie ring"
512
+ children: E("mybodyshield.pages.nutrition.calorieRing", "Calorie ring")
489
513
  }),
490
- /* @__PURE__ */ g("span", {
514
+ /* @__PURE__ */ _("span", {
491
515
  className: "text-2xl font-bold tabular-nums text-action-primary-bg",
492
- children: [re, "%"]
516
+ children: [ne, "%"]
493
517
  }),
494
- /* @__PURE__ */ h("span", {
518
+ /* @__PURE__ */ g("span", {
495
519
  className: "text-xs text-text-secondary",
496
- children: "of daily target"
520
+ children: E("mybodyshield.pages.nutrition.ofDailyTarget", "of daily target")
497
521
  })
498
522
  ]
499
523
  })]
@@ -502,26 +526,26 @@ function T() {
502
526
  })]
503
527
  })
504
528
  }),
505
- /* @__PURE__ */ h(u.div, {
529
+ /* @__PURE__ */ g(u.div, {
506
530
  variants: Q,
507
531
  className: "grid grid-cols-1 gap-3 sm:grid-cols-3 sm:gap-4",
508
- children: l.map((e) => /* @__PURE__ */ h(u.div, {
532
+ children: s.map((e) => /* @__PURE__ */ g(u.div, {
509
533
  variants: $,
510
- children: /* @__PURE__ */ g(v, {
534
+ children: /* @__PURE__ */ _(y, {
511
535
  treatment: "metric",
512
536
  className: "p-4",
513
- children: [/* @__PURE__ */ g("div", {
537
+ children: [/* @__PURE__ */ _("div", {
514
538
  className: "flex flex-wrap items-center justify-between gap-2",
515
- children: [/* @__PURE__ */ g("span", {
539
+ children: [/* @__PURE__ */ _("span", {
516
540
  className: "inline-flex items-center gap-2 text-sm font-medium text-text-primary",
517
- children: [/* @__PURE__ */ h("span", {
541
+ children: [/* @__PURE__ */ g("span", {
518
542
  className: "h-2.5 w-2.5 rounded-full",
519
543
  style: { backgroundColor: e.color }
520
544
  }), e.label]
521
- }), /* @__PURE__ */ g("span", {
545
+ }), /* @__PURE__ */ _("span", {
522
546
  className: "text-sm tabular-nums text-text-secondary",
523
547
  children: [
524
- /* @__PURE__ */ h("span", {
548
+ /* @__PURE__ */ g("span", {
525
549
  className: "font-semibold text-text-primary",
526
550
  children: i(e.value)
527
551
  }),
@@ -531,7 +555,7 @@ function T() {
531
555
  " g"
532
556
  ]
533
557
  })]
534
- }), /* @__PURE__ */ h(be, {
558
+ }), /* @__PURE__ */ g(xe, {
535
559
  value: e.target ? e.value / e.target * 100 : 0,
536
560
  color: e.color,
537
561
  height: 8,
@@ -540,69 +564,81 @@ function T() {
540
564
  })
541
565
  }, e.label))
542
566
  }),
543
- /* @__PURE__ */ h(u.div, {
567
+ /* @__PURE__ */ g(u.div, {
544
568
  variants: $,
545
- children: /* @__PURE__ */ h(ne, {
546
- title: "Today's meals",
547
- description: "Everything you've logged today.",
548
- children: k.isLoading ? /* @__PURE__ */ h(c, { label: "Loading meals…" }) : k.isError ? /* @__PURE__ */ h(s, {
549
- message: "We couldn't load today's meals.",
550
- onRetry: () => k.refetch()
551
- }) : X.length === 0 ? /* @__PURE__ */ h(o, {
569
+ children: /* @__PURE__ */ g(pe, {
570
+ title: E("mybodyshield.pages.nutrition.todaysMeals", "Today's meals"),
571
+ description: E("mybodyshield.pages.nutrition.todaysMealsDescription", "Everything you've logged today."),
572
+ children: j.isLoading ? /* @__PURE__ */ g(l, { label: E("mybodyshield.common.loadingWithName", "Loading {{name}}…", { name: E("mybodyshield.pages.nutrition.meals", "Meals") }) }) : j.isError ? /* @__PURE__ */ g(c, {
573
+ message: E("mybodyshield.pages.nutrition.errorMeals", "We couldn't load today's meals."),
574
+ onRetry: () => j.refetch()
575
+ }) : Dt.length === 0 ? /* @__PURE__ */ g(o, {
552
576
  illustration: "empty-data",
553
- icon: /* @__PURE__ */ h(Ae, { className: "h-10 w-10" }),
554
- title: "No meals logged today",
555
- description: "Use “Log meal” to record what you've eaten and keep your macros current.",
556
- action: /* @__PURE__ */ g(_, {
557
- onClick: Z,
558
- children: [/* @__PURE__ */ h(p, { className: "mr-1.5 h-4 w-4" }), " Log meal"]
577
+ icon: /* @__PURE__ */ g(Ae, { className: "h-10 w-10" }),
578
+ title: E("mybodyshield.pages.nutrition.noMealsToday", "No meals logged today"),
579
+ description: E("mybodyshield.pages.nutrition.noMealsTodayDescription", "Use \"Log meal\" to record what you've eaten and keep your macros current."),
580
+ action: /* @__PURE__ */ _(v, {
581
+ onClick: X,
582
+ children: [
583
+ /* @__PURE__ */ g(m, { className: "mr-1.5 h-4 w-4" }),
584
+ " ",
585
+ E("mybodyshield.pages.nutrition.logMeal", "Log meal")
586
+ ]
559
587
  })
560
- }) : /* @__PURE__ */ h(v, {
588
+ }) : /* @__PURE__ */ g(y, {
561
589
  treatment: "plain",
562
590
  className: "divide-y divide-border-seam/60 px-2 sm:px-3",
563
- children: X.map((e) => /* @__PURE__ */ g("div", {
591
+ children: Dt.map((e) => /* @__PURE__ */ _("div", {
564
592
  className: "flex items-center gap-3 rounded-xl px-2 py-3 transition-colors hover:bg-bg-sunken/40",
565
593
  children: [
566
- /* @__PURE__ */ h(te, { status: e.mealType }),
567
- /* @__PURE__ */ g("div", {
594
+ /* @__PURE__ */ g(te, { status: e.mealType }),
595
+ /* @__PURE__ */ _("div", {
568
596
  className: "min-w-0 flex-1",
569
- children: [/* @__PURE__ */ g("div", {
597
+ children: [/* @__PURE__ */ _("div", {
570
598
  className: "flex items-center gap-1.5",
571
- children: [/* @__PURE__ */ h("p", {
599
+ children: [/* @__PURE__ */ g("p", {
572
600
  className: "truncate text-sm font-medium text-text-primary",
573
601
  children: e.name
574
- }), e.isFavorite && /* @__PURE__ */ h(m, {
602
+ }), e.isFavorite && /* @__PURE__ */ g(h, {
575
603
  className: "h-3.5 w-3.5 shrink-0 fill-current text-action-primary-bg",
576
- "aria-label": "Favorite meal"
604
+ "aria-label": E("mybodyshield.pages.nutrition.favoriteMeal", "Favorite meal")
577
605
  })]
578
- }), /* @__PURE__ */ g("p", {
606
+ }), /* @__PURE__ */ _("p", {
579
607
  className: "text-xs text-text-tertiary",
580
608
  children: [
581
609
  r(e.proteinG),
582
- " P · ",
610
+ " ",
611
+ E("mybodyshield.pages.nutrition.proteinShort", "P"),
612
+ " ·",
613
+ " ",
583
614
  r(e.carbsG),
584
- " C ·",
585
615
  " ",
616
+ E("mybodyshield.pages.nutrition.carbsShort", "C"),
617
+ " ",
618
+ "· ",
586
619
  r(e.fatG),
587
- " F · ",
620
+ " ",
621
+ E("mybodyshield.pages.nutrition.fatShort", "F"),
622
+ " ·",
623
+ " ",
588
624
  i(e.servings),
589
- " serving",
590
- e.servings === 1 ? "" : "s"
625
+ " ",
626
+ e.servings === 1 ? E("mybodyshield.pages.nutrition.serving", "serving") : E("mybodyshield.pages.nutrition.servings", "servings")
591
627
  ]
592
628
  })]
593
629
  }),
594
- /* @__PURE__ */ h("span", {
630
+ /* @__PURE__ */ g("span", {
595
631
  className: "shrink-0 text-sm font-semibold tabular-nums text-text-primary",
596
632
  children: ee(e.calories)
597
633
  }),
598
- /* @__PURE__ */ h(_, {
634
+ /* @__PURE__ */ g(v, {
599
635
  variant: "ghost",
600
636
  size: "icon-sm",
601
- onClick: () => At(e.id),
602
- disabled: st === e.id,
603
- "aria-label": "Delete meal",
637
+ onClick: () => Ft(e.id),
638
+ disabled: lt === e.id,
639
+ "aria-label": E("mybodyshield.pages.nutrition.deleteMeal", "Delete meal"),
604
640
  className: "shrink-0",
605
- children: /* @__PURE__ */ h(je, { className: "h-4 w-4 text-status-error-text" })
641
+ children: /* @__PURE__ */ g(je, { className: "h-4 w-4 text-status-error-text" })
606
642
  })
607
643
  ]
608
644
  }, e.id))
@@ -612,154 +648,162 @@ function T() {
612
648
  ]
613
649
  });
614
650
  })(),
615
- T === "plan" && (() => {
616
- if (O.isLoading) return /* @__PURE__ */ h(c, { label: "Loading your nutrition plan…" });
617
- if (O.isError) return /* @__PURE__ */ h(s, {
618
- message: "We couldn't load your active nutrition plan.",
619
- onRetry: () => O.refetch()
651
+ D === "plan" && (() => {
652
+ if (A.isLoading) return /* @__PURE__ */ g(l, { label: E("mybodyshield.pages.nutrition.loadingPlan", "Loading your nutrition plan…") });
653
+ if (A.isError) return /* @__PURE__ */ g(c, {
654
+ message: E("mybodyshield.pages.nutrition.errorPlan", "We couldn't load your active nutrition plan."),
655
+ onRetry: () => A.refetch()
620
656
  });
621
- if (!Y) return /* @__PURE__ */ h(o, {
657
+ if (!Y) return /* @__PURE__ */ g(o, {
622
658
  illustration: "empty-data",
623
- icon: /* @__PURE__ */ h(Ee, { className: "h-10 w-10" }),
624
- title: "No active nutrition plan",
625
- description: "Create a nutrition plan to set your daily calorie and macro targets.",
626
- action: /* @__PURE__ */ g(_, {
627
- onClick: Tt,
628
- children: [/* @__PURE__ */ h(p, { className: "mr-1.5 h-4 w-4" }), " Create plan"]
659
+ icon: /* @__PURE__ */ g(Ee, { className: "h-10 w-10" }),
660
+ title: E("mybodyshield.pages.nutrition.noActivePlan", "No active nutrition plan"),
661
+ description: E("mybodyshield.pages.nutrition.noActivePlanDescription", "Create a nutrition plan to set your daily calorie and macro targets."),
662
+ action: /* @__PURE__ */ _(v, {
663
+ onClick: At,
664
+ children: [
665
+ /* @__PURE__ */ g(m, { className: "mr-1.5 h-4 w-4" }),
666
+ " ",
667
+ E("mybodyshield.pages.nutrition.createPlan", "Create plan")
668
+ ]
629
669
  })
630
670
  });
631
671
  let e = [
632
672
  {
633
- icon: /* @__PURE__ */ h(Oe, { className: "h-5 w-5" }),
634
- label: "Calorie target",
673
+ icon: /* @__PURE__ */ g(Oe, { className: "h-5 w-5" }),
674
+ label: E("mybodyshield.pages.nutrition.calorieTarget", "Calorie target"),
635
675
  value: Y.calorieTarget ? `${i(Y.calorieTarget)} kcal` : "—",
636
676
  tint: "var(--color-action-primary-bg)"
637
677
  },
638
678
  {
639
- icon: /* @__PURE__ */ h(Ce, { className: "h-5 w-5" }),
640
- label: "Protein target",
679
+ icon: /* @__PURE__ */ g(we, { className: "h-5 w-5" }),
680
+ label: E("mybodyshield.pages.nutrition.proteinTarget", "Protein target"),
641
681
  value: Y.proteinTarget ? r(Y.proteinTarget) : "—",
642
682
  tint: d.protein
643
683
  },
644
684
  {
645
- icon: /* @__PURE__ */ h(Ne, { className: "h-5 w-5" }),
646
- label: "Carbs target",
685
+ icon: /* @__PURE__ */ g(Ne, { className: "h-5 w-5" }),
686
+ label: E("mybodyshield.pages.nutrition.carbsTarget", "Carbs target"),
647
687
  value: Y.carbsTarget ? r(Y.carbsTarget) : "—",
648
688
  tint: d.carbs
649
689
  },
650
690
  {
651
- icon: /* @__PURE__ */ h(De, { className: "h-5 w-5" }),
652
- label: "Fat target",
691
+ icon: /* @__PURE__ */ g(De, { className: "h-5 w-5" }),
692
+ label: E("mybodyshield.pages.nutrition.fatTarget", "Fat target"),
653
693
  value: Y.fatTarget ? r(Y.fatTarget) : "—",
654
694
  tint: d.fat
655
695
  }
656
696
  ];
657
- return /* @__PURE__ */ g(u.div, {
697
+ return /* @__PURE__ */ _(u.div, {
658
698
  initial: "hidden",
659
699
  animate: "show",
660
700
  variants: Q,
661
701
  className: "space-y-6",
662
702
  children: [
663
- !Y.isActive && /* @__PURE__ */ g(u.div, {
703
+ !Y.isActive && /* @__PURE__ */ _(u.div, {
664
704
  variants: $,
665
705
  className: "flex flex-wrap items-center justify-between gap-3 rounded-2xl border p-4",
666
706
  style: {
667
707
  borderColor: "color-mix(in srgb, var(--color-action-primary-bg) 32%, transparent)",
668
708
  backgroundColor: "color-mix(in srgb, var(--color-action-primary-bg) 8%, transparent)"
669
709
  },
670
- children: [/* @__PURE__ */ g("div", {
710
+ children: [/* @__PURE__ */ _("div", {
671
711
  className: "flex min-w-0 items-center gap-3",
672
- children: [/* @__PURE__ */ h(ve, { icon: /* @__PURE__ */ h(Te, { className: "h-5 w-5" }) }), /* @__PURE__ */ g("div", {
712
+ children: [/* @__PURE__ */ g(ye, { icon: /* @__PURE__ */ g(p, { className: "h-5 w-5" }) }), /* @__PURE__ */ _("div", {
673
713
  className: "min-w-0",
674
- children: [/* @__PURE__ */ h("p", {
714
+ children: [/* @__PURE__ */ g("p", {
675
715
  className: "text-sm font-medium text-text-primary",
676
- children: "This plan isn't active yet"
677
- }), /* @__PURE__ */ h("p", {
716
+ children: E("mybodyshield.pages.nutrition.planNotActive", "This plan isn't active yet")
717
+ }), /* @__PURE__ */ g("p", {
678
718
  className: "text-xs text-text-secondary",
679
- children: "Activate it to track today's macros against these targets."
719
+ children: E("mybodyshield.pages.nutrition.planNotActiveDescription", "Activate it to track today's macros against these targets.")
680
720
  })]
681
721
  })]
682
- }), /* @__PURE__ */ g(_, {
683
- onClick: () => kt(Y.id),
684
- disabled: P.isPending,
685
- children: [/* @__PURE__ */ h(Te, { className: "mr-1.5 h-4 w-4" }), P.isPending ? "Activating…" : "Activate this plan"]
722
+ }), /* @__PURE__ */ _(v, {
723
+ onClick: () => Pt(Y.id),
724
+ disabled: I.isPending,
725
+ children: [/* @__PURE__ */ g(p, { className: "mr-1.5 h-4 w-4" }), I.isPending ? E("mybodyshield.common.activating", "Activating…") : E("mybodyshield.common.activate", "Activate this plan")]
686
726
  })]
687
727
  }),
688
- /* @__PURE__ */ h(u.div, {
728
+ /* @__PURE__ */ g(u.div, {
689
729
  variants: $,
690
- children: /* @__PURE__ */ g(v, {
730
+ children: /* @__PURE__ */ _(y, {
691
731
  treatment: "glass",
692
732
  glow: !0,
693
733
  className: "relative overflow-hidden p-6 sm:p-7",
694
734
  children: [
695
- /* @__PURE__ */ h("div", {
735
+ /* @__PURE__ */ g("div", {
696
736
  "aria-hidden": "true",
697
737
  className: "pointer-events-none absolute inset-0",
698
738
  style: { background: "radial-gradient(120% 120% at 0% 0%, color-mix(in srgb, var(--color-action-primary-bg) 13%, transparent), transparent 55%)" }
699
739
  }),
700
- /* @__PURE__ */ g("div", {
740
+ /* @__PURE__ */ _("div", {
701
741
  className: "relative flex flex-wrap items-start justify-between gap-4",
702
- children: [/* @__PURE__ */ g("div", {
742
+ children: [/* @__PURE__ */ _("div", {
703
743
  className: "min-w-0",
704
744
  children: [
705
- /* @__PURE__ */ h("p", {
745
+ /* @__PURE__ */ g("p", {
706
746
  className: "text-xs font-semibold uppercase tracking-wide text-action-primary-bg",
707
- children: Y.isActive ? "Active plan" : "Nutrition plan"
747
+ children: Y.isActive ? E("mybodyshield.pages.nutrition.activePlan", "Active plan") : E("mybodyshield.pages.nutrition.nutritionPlan", "Nutrition plan")
708
748
  }),
709
- /* @__PURE__ */ g("div", {
749
+ /* @__PURE__ */ _("div", {
710
750
  className: "mt-1.5 flex flex-wrap items-baseline gap-x-2 gap-y-1",
711
751
  children: [
712
- /* @__PURE__ */ h("h2", {
752
+ /* @__PURE__ */ g("h2", {
713
753
  className: "text-2xl font-bold text-text-primary",
714
754
  children: Y.name
715
755
  }),
716
- Y.calorieTarget > 0 && /* @__PURE__ */ g("span", {
756
+ Y.calorieTarget > 0 && /* @__PURE__ */ _("span", {
717
757
  className: "text-lg font-semibold tabular-nums text-text-tertiary",
718
758
  children: [i(Y.calorieTarget), " kcal"]
719
759
  }),
720
- Y.isActive ? /* @__PURE__ */ g("span", {
760
+ Y.isActive ? /* @__PURE__ */ _("span", {
721
761
  className: "inline-flex items-center gap-1 rounded-full bg-status-success-bg-subtle px-2.5 py-0.5 text-xs font-medium text-status-success-text",
722
- children: [/* @__PURE__ */ h(Te, { className: "h-3.5 w-3.5" }), " Active"]
723
- }) : /* @__PURE__ */ h("span", {
762
+ children: [
763
+ /* @__PURE__ */ g(p, { className: "h-3.5 w-3.5" }),
764
+ " ",
765
+ E("mybodyshield.common.active", "Active")
766
+ ]
767
+ }) : /* @__PURE__ */ g("span", {
724
768
  className: "inline-flex items-center gap-1 rounded-full bg-bg-sunken px-2.5 py-0.5 text-xs font-medium text-text-secondary",
725
- children: "Inactive"
769
+ children: E("mybodyshield.common.inactive", "Inactive")
726
770
  })
727
771
  ]
728
772
  }),
729
- (Y.startDate || Y.endDate) && /* @__PURE__ */ g("p", {
773
+ (Y.startDate || Y.endDate) && /* @__PURE__ */ _("p", {
730
774
  className: "mt-2 inline-flex items-center gap-1.5 text-sm text-text-secondary",
731
775
  children: [
732
- /* @__PURE__ */ h(we, { className: "h-4 w-4 text-text-tertiary" }),
776
+ /* @__PURE__ */ g(Te, { className: "h-4 w-4 text-text-tertiary" }),
733
777
  t(Y.startDate),
734
778
  " – ",
735
779
  t(Y.endDate)
736
780
  ]
737
781
  })
738
782
  ]
739
- }), /* @__PURE__ */ g("div", {
783
+ }), /* @__PURE__ */ _("div", {
740
784
  className: "flex shrink-0 items-center gap-2",
741
- children: [/* @__PURE__ */ h("span", {
785
+ children: [/* @__PURE__ */ g("span", {
742
786
  className: "text-sm text-text-tertiary",
743
- children: "Goal"
744
- }), /* @__PURE__ */ h(te, { status: Y.goalType })]
787
+ children: E("mybodyshield.common.goal", "Goal")
788
+ }), /* @__PURE__ */ g(te, { status: Y.goalType })]
745
789
  })]
746
790
  }),
747
- /* @__PURE__ */ h(u.div, {
791
+ /* @__PURE__ */ g(u.div, {
748
792
  variants: Q,
749
793
  className: "relative mt-6 grid grid-cols-2 gap-3 sm:gap-4 lg:grid-cols-4",
750
- children: e.map((e) => /* @__PURE__ */ g(u.div, {
794
+ children: e.map((e) => /* @__PURE__ */ _(u.div, {
751
795
  variants: $,
752
796
  className: "rounded-2xl border border-border-seam bg-bg-sunken/40 p-4 transition-shadow duration-200 hover:shadow-elevation-2",
753
797
  children: [
754
- /* @__PURE__ */ h(ve, {
798
+ /* @__PURE__ */ g(ye, {
755
799
  icon: e.icon,
756
800
  tint: e.tint
757
801
  }),
758
- /* @__PURE__ */ h("p", {
802
+ /* @__PURE__ */ g("p", {
759
803
  className: "mt-3 text-xs text-text-tertiary",
760
804
  children: e.label
761
805
  }),
762
- /* @__PURE__ */ h("p", {
806
+ /* @__PURE__ */ g("p", {
763
807
  className: "mt-1 text-xl font-bold tabular-nums text-text-primary",
764
808
  children: e.value
765
809
  })
@@ -769,14 +813,14 @@ function T() {
769
813
  ]
770
814
  })
771
815
  }),
772
- Y.notes && /* @__PURE__ */ h(u.div, {
816
+ Y.notes && /* @__PURE__ */ g(u.div, {
773
817
  variants: $,
774
- children: /* @__PURE__ */ h(ne, {
775
- title: "Notes",
776
- children: /* @__PURE__ */ h(v, {
818
+ children: /* @__PURE__ */ g(pe, {
819
+ title: E("mybodyshield.pages.nutrition.planNotes", "Notes"),
820
+ children: /* @__PURE__ */ g(y, {
777
821
  treatment: "plain",
778
822
  className: "p-4",
779
- children: /* @__PURE__ */ h("p", {
823
+ children: /* @__PURE__ */ g("p", {
780
824
  className: "whitespace-pre-wrap text-sm text-text-secondary",
781
825
  children: Y.notes
782
826
  })
@@ -786,362 +830,364 @@ function T() {
786
830
  ]
787
831
  });
788
832
  })(),
789
- T === "meals" && (M.isLoading ? /* @__PURE__ */ h(c, { label: "Loading meal log…" }) : M.isError ? /* @__PURE__ */ h(s, {
790
- message: "We couldn't load your meal log.",
791
- onRetry: () => M.refetch()
792
- }) : /* @__PURE__ */ g(u.div, {
833
+ D === "meals" && (P.isLoading ? /* @__PURE__ */ g(l, { label: E("mybodyshield.pages.nutrition.loadingMeals", "Loading meal log…") }) : P.isError ? /* @__PURE__ */ g(c, {
834
+ message: E("mybodyshield.pages.nutrition.errorMeals", "We couldn't load your meal log."),
835
+ onRetry: () => P.refetch()
836
+ }) : /* @__PURE__ */ _(u.div, {
793
837
  initial: "hidden",
794
838
  animate: "show",
795
839
  variants: Q,
796
840
  className: "space-y-4",
797
- children: [/* @__PURE__ */ h(u.div, {
841
+ children: [/* @__PURE__ */ g(u.div, {
798
842
  variants: $,
799
- children: /* @__PURE__ */ h(l, {
800
- options: Ze,
801
- value: A,
802
- onChange: wt
843
+ children: /* @__PURE__ */ g(he, {
844
+ options: rt,
845
+ value: M,
846
+ onChange: kt
803
847
  })
804
- }), Ct.length === 0 ? /* @__PURE__ */ h(u.div, {
848
+ }), Ot.length === 0 ? /* @__PURE__ */ g(u.div, {
805
849
  variants: $,
806
- children: /* @__PURE__ */ h(o, {
850
+ children: /* @__PURE__ */ g(o, {
807
851
  illustration: "empty-data",
808
- icon: /* @__PURE__ */ h(Me, { className: "h-10 w-10" }),
809
- title: A === "ALL" ? "No meals logged yet" : "No meals for this filter",
810
- description: A === "ALL" ? "Log meals from the Today tab to build up your nutrition history." : "Try a different meal type, or log a meal to get started.",
811
- action: /* @__PURE__ */ g(_, {
812
- onClick: Z,
813
- children: [/* @__PURE__ */ h(p, { className: "mr-1.5 h-4 w-4" }), " Log meal"]
852
+ icon: /* @__PURE__ */ g(Me, { className: "h-10 w-10" }),
853
+ title: M === "ALL" ? E("mybodyshield.pages.nutrition.emptyMealsTitle", "No meals logged yet") : E("mybodyshield.pages.nutrition.emptyMealsFilteredTitle", "No meals for this filter"),
854
+ description: M === "ALL" ? E("mybodyshield.pages.nutrition.emptyMealsDescription", "Log meals from the Today tab to build up your nutrition history.") : E("mybodyshield.pages.nutrition.emptyMealsFilteredDescription", "Try a different meal type, or log a meal to get started."),
855
+ action: /* @__PURE__ */ _(v, {
856
+ onClick: X,
857
+ children: [
858
+ /* @__PURE__ */ g(m, { className: "mr-1.5 h-4 w-4" }),
859
+ " ",
860
+ E("mybodyshield.pages.nutrition.logMeal", "Log meal")
861
+ ]
814
862
  })
815
863
  })
816
- }) : /* @__PURE__ */ g(Pe, { children: [/* @__PURE__ */ h(u.div, {
864
+ }) : /* @__PURE__ */ _(Pe, { children: [/* @__PURE__ */ g(u.div, {
817
865
  variants: $,
818
- children: /* @__PURE__ */ h(re, {
819
- columns: Mt,
820
- rows: Ct,
866
+ children: /* @__PURE__ */ g(me, {
867
+ columns: It,
868
+ rows: Ot,
821
869
  rowKey: (e) => e.id,
822
870
  defaultSort: {
823
871
  key: "loggedAt",
824
872
  dir: "desc"
825
873
  }
826
874
  })
827
- }), /* @__PURE__ */ h(u.div, {
875
+ }), /* @__PURE__ */ g(u.div, {
828
876
  variants: $,
829
- children: /* @__PURE__ */ h(ae, {
830
- page: j.page,
831
- pageSize: x,
832
- itemCount: Ct.length,
833
- hasMore: M.data?.pageInfo?.hasMore ?? !1,
834
- onPageChange: (e) => j.onPageChange(e)
877
+ children: /* @__PURE__ */ g(_e, {
878
+ page: N.page,
879
+ pageSize: S,
880
+ itemCount: Ot.length,
881
+ hasMore: P.data?.pageInfo?.hasMore ?? !1,
882
+ onPageChange: (e) => N.onPageChange(e)
835
883
  })
836
884
  })] })]
837
885
  })),
838
- /* @__PURE__ */ h(Fe, {
839
- open: ut,
840
- onOpenChange: L,
841
- children: /* @__PURE__ */ g(Ie, {
886
+ /* @__PURE__ */ g(Fe, {
887
+ open: pt,
888
+ onOpenChange: R,
889
+ children: /* @__PURE__ */ _(Ie, {
842
890
  className: "sm:max-w-lg",
843
891
  children: [
844
- /* @__PURE__ */ g(ze, { children: [/* @__PURE__ */ h(Be, { children: "Log a meal" }), /* @__PURE__ */ h(Le, { children: "Record what you ate to update today's macros." })] }),
845
- /* @__PURE__ */ g("div", {
892
+ /* @__PURE__ */ _(ze, { children: [/* @__PURE__ */ g(Be, { children: E("mybodyshield.pages.nutrition.logMealDialogTitle", "Log a meal") }), /* @__PURE__ */ g(Le, { children: E("mybodyshield.pages.nutrition.logMealDialogDescription", "Record what you ate to update today's macros.") })] }),
893
+ /* @__PURE__ */ _("div", {
846
894
  className: "space-y-4 py-2",
847
895
  children: [
848
- dt && /* @__PURE__ */ h("div", {
896
+ mt && /* @__PURE__ */ g("div", {
849
897
  className: "rounded-lg border border-status-error-text/40 bg-status-error-bg-subtle px-3 py-2 text-sm text-status-error-text",
850
- children: dt
898
+ children: mt
851
899
  }),
852
- /* @__PURE__ */ g("div", {
900
+ /* @__PURE__ */ _("div", {
853
901
  className: "space-y-2 rounded-xl border border-seam bg-surface p-3",
854
902
  children: [
855
- /* @__PURE__ */ h(b, {
903
+ /* @__PURE__ */ g(x, {
856
904
  htmlFor: "meal-food-search",
857
- children: "Quick-log from food database"
905
+ children: E("mybodyshield.pages.nutrition.foodSearchHint", "Quick-log from food database")
858
906
  }),
859
- /* @__PURE__ */ h(y, {
907
+ /* @__PURE__ */ g(b, {
860
908
  id: "meal-food-search",
861
- value: V,
862
- onChange: (e) => ft(e.target.value),
863
- placeholder: "Search foods (e.g. grilled chicken)"
909
+ value: ht,
910
+ onChange: (e) => gt(e.target.value),
911
+ placeholder: E("mybodyshield.pages.nutrition.foodSearchPlaceholder", "Search foods (e.g. grilled chicken)")
864
912
  }),
865
- H.isFetching && /* @__PURE__ */ h("p", {
913
+ H.isFetching && /* @__PURE__ */ g("p", {
866
914
  className: "text-xs text-text-tertiary",
867
- children: "Searching…"
915
+ children: E("mybodyshield.common.loading", "Loading…")
868
916
  }),
869
- !H.isFetching && V.trim().length >= 2 && (H.data?.length ?? 0) === 0 && /* @__PURE__ */ h("p", {
917
+ !H.isFetching && ht.trim().length >= 2 && (H.data?.length ?? 0) === 0 && /* @__PURE__ */ g("p", {
870
918
  className: "text-xs text-text-tertiary",
871
- children: "No matches found."
919
+ children: E("mybodyshield.common.noResults", "No matches found.")
872
920
  }),
873
- (H.data?.length ?? 0) > 0 && /* @__PURE__ */ h("ul", {
921
+ (H.data?.length ?? 0) > 0 && /* @__PURE__ */ g("ul", {
874
922
  className: "max-h-40 space-y-1 overflow-y-auto",
875
- children: H.data.map((e, t) => /* @__PURE__ */ h("li", { children: /* @__PURE__ */ g("button", {
923
+ children: H.data.map((e, t) => /* @__PURE__ */ g("li", { children: /* @__PURE__ */ _("button", {
876
924
  type: "button",
877
- onClick: () => _t(e),
925
+ onClick: () => xt(e),
878
926
  className: "flex w-full items-center justify-between rounded-lg px-2 py-1.5 text-left text-sm hover:bg-surface-hover",
879
- children: [/* @__PURE__ */ g("span", {
927
+ children: [/* @__PURE__ */ _("span", {
880
928
  className: "truncate",
881
- children: [e.name, e.brand ? /* @__PURE__ */ g("span", {
929
+ children: [e.name, e.brand ? /* @__PURE__ */ _("span", {
882
930
  className: "text-text-tertiary",
883
931
  children: [" · ", e.brand]
884
932
  }) : null]
885
933
  }), /* @__PURE__ */ g("span", {
886
934
  className: "ml-2 shrink-0 text-xs text-text-tertiary",
887
- children: [
888
- e.calories,
889
- " kcal / ",
890
- e.servingG,
891
- "g"
892
- ]
935
+ children: E("mybodyshield.pages.nutrition.foodSearchMeta", "{{calories}} kcal / {{servingG}}g", {
936
+ calories: e.calories,
937
+ servingG: e.servingG
938
+ })
893
939
  })]
894
940
  }) }, `${e.barcode ?? e.name}-${t}`))
895
941
  }),
896
- /* @__PURE__ */ g("div", {
942
+ /* @__PURE__ */ _("div", {
897
943
  className: "flex items-end gap-2 pt-1",
898
- children: [/* @__PURE__ */ g("div", {
944
+ children: [/* @__PURE__ */ _("div", {
899
945
  className: "flex-1 space-y-1.5",
900
- children: [/* @__PURE__ */ h(b, {
946
+ children: [/* @__PURE__ */ g(x, {
901
947
  htmlFor: "meal-barcode",
902
- children: "Or scan/enter a barcode"
903
- }), /* @__PURE__ */ h(y, {
948
+ children: E("mybodyshield.pages.nutrition.barcodePlaceholder", "Or scan/enter a barcode")
949
+ }), /* @__PURE__ */ g(b, {
904
950
  id: "meal-barcode",
905
- value: pt,
906
- onChange: (e) => mt(e.target.value),
907
- placeholder: "e.g. 3017620422003"
951
+ value: _t,
952
+ onChange: (e) => vt(e.target.value),
953
+ placeholder: E("mybodyshield.pages.nutrition.barcodeExample", "e.g. 3017620422003")
908
954
  })]
909
- }), /* @__PURE__ */ h(_, {
955
+ }), /* @__PURE__ */ g(v, {
910
956
  type: "button",
911
957
  variant: "outline",
912
- onClick: vt,
913
- disabled: gt.isPending || !pt.trim(),
914
- children: gt.isPending ? "Looking up…" : "Look up"
958
+ onClick: St,
959
+ disabled: bt.isPending || !_t.trim(),
960
+ children: bt.isPending ? E("mybodyshield.common.loading", "Loading…") : E("mybodyshield.pages.nutrition.barcodeLookup", "Look up")
915
961
  })]
916
962
  }),
917
- ht && /* @__PURE__ */ h("p", {
963
+ yt && /* @__PURE__ */ g("p", {
918
964
  className: "text-xs text-status-error-text",
919
- children: ht
965
+ children: yt
920
966
  })
921
967
  ]
922
968
  }),
923
- /* @__PURE__ */ g("div", {
969
+ /* @__PURE__ */ _("div", {
924
970
  className: "space-y-1.5",
925
- children: [/* @__PURE__ */ h(b, {
971
+ children: [/* @__PURE__ */ g(x, {
926
972
  htmlFor: "meal-name",
927
- children: "Name"
928
- }), /* @__PURE__ */ h(y, {
973
+ children: E("mybodyshield.common.name", "Name")
974
+ }), /* @__PURE__ */ g(b, {
929
975
  id: "meal-name",
930
- value: R.name,
931
- onChange: (e) => z({
932
- ...R,
976
+ value: z.name,
977
+ onChange: (e) => B({
978
+ ...z,
933
979
  name: e.target.value
934
980
  }),
935
- placeholder: "Grilled chicken salad"
981
+ placeholder: E("mybodyshield.pages.nutrition.mealNamePlaceholder", "Grilled chicken salad")
936
982
  })]
937
983
  }),
938
- /* @__PURE__ */ g("div", {
984
+ /* @__PURE__ */ _("div", {
939
985
  className: "grid grid-cols-2 gap-3",
940
- children: [/* @__PURE__ */ g("div", {
986
+ children: [/* @__PURE__ */ _("div", {
941
987
  className: "space-y-1.5",
942
- children: [/* @__PURE__ */ h(b, {
988
+ children: [/* @__PURE__ */ g(x, {
943
989
  htmlFor: "meal-type",
944
- children: "Meal type"
945
- }), /* @__PURE__ */ g(Ve, {
946
- value: R.mealType,
947
- onValueChange: (e) => z({
948
- ...R,
990
+ children: E("mybodyshield.common.type", "Type")
991
+ }), /* @__PURE__ */ _(Ve, {
992
+ value: z.mealType,
993
+ onValueChange: (e) => B({
994
+ ...z,
949
995
  mealType: e
950
996
  }),
951
- children: [/* @__PURE__ */ h(We, {
997
+ children: [/* @__PURE__ */ g(We, {
952
998
  id: "meal-type",
953
- children: /* @__PURE__ */ h(Ge, {})
954
- }), /* @__PURE__ */ h(He, { children: Je.map((e) => /* @__PURE__ */ h(Ue, {
999
+ children: /* @__PURE__ */ g(Ge, {})
1000
+ }), /* @__PURE__ */ g(He, { children: Je.map((e) => /* @__PURE__ */ g(Ue, {
955
1001
  value: e,
956
1002
  children: n(e)
957
1003
  }, e)) })]
958
1004
  })]
959
- }), /* @__PURE__ */ g("div", {
1005
+ }), /* @__PURE__ */ _("div", {
960
1006
  className: "space-y-1.5",
961
- children: [/* @__PURE__ */ h(b, {
1007
+ children: [/* @__PURE__ */ g(x, {
962
1008
  htmlFor: "meal-servings",
963
- children: "Servings"
964
- }), /* @__PURE__ */ h(y, {
1009
+ children: E("mybodyshield.pages.nutrition.servingsLabel", "Servings")
1010
+ }), /* @__PURE__ */ g(b, {
965
1011
  id: "meal-servings",
966
1012
  type: "number",
967
1013
  min: 0,
968
1014
  step: "0.5",
969
- value: R.servings,
970
- onChange: (e) => z({
971
- ...R,
1015
+ value: z.servings,
1016
+ onChange: (e) => B({
1017
+ ...z,
972
1018
  servings: e.target.value
973
1019
  }),
974
- placeholder: "1"
1020
+ placeholder: E("mybodyshield.pages.nutrition.servingsPlaceholder", "1")
975
1021
  })]
976
1022
  })]
977
1023
  }),
978
- /* @__PURE__ */ g("div", {
1024
+ /* @__PURE__ */ _("div", {
979
1025
  className: "grid grid-cols-2 gap-3",
980
1026
  children: [
981
- /* @__PURE__ */ g("div", {
1027
+ /* @__PURE__ */ _("div", {
982
1028
  className: "space-y-1.5",
983
- children: [/* @__PURE__ */ h(b, {
1029
+ children: [/* @__PURE__ */ _(x, {
984
1030
  htmlFor: "meal-calories",
985
- children: "Calories (kcal)"
986
- }), /* @__PURE__ */ h(y, {
1031
+ children: [E("mybodyshield.pages.nutrition.calories", "Calories"), " (kcal)"]
1032
+ }), /* @__PURE__ */ g(b, {
987
1033
  id: "meal-calories",
988
1034
  type: "number",
989
1035
  min: 0,
990
- value: R.calories,
991
- onChange: (e) => z({
992
- ...R,
1036
+ value: z.calories,
1037
+ onChange: (e) => B({
1038
+ ...z,
993
1039
  calories: e.target.value
994
1040
  }),
995
- placeholder: "0"
1041
+ placeholder: E("mybodyshield.pages.nutrition.caloriesPlaceholder", "0")
996
1042
  })]
997
1043
  }),
998
- /* @__PURE__ */ g("div", {
1044
+ /* @__PURE__ */ _("div", {
999
1045
  className: "space-y-1.5",
1000
- children: [/* @__PURE__ */ h(b, {
1046
+ children: [/* @__PURE__ */ _(x, {
1001
1047
  htmlFor: "meal-protein",
1002
- children: "Protein (g)"
1003
- }), /* @__PURE__ */ h(y, {
1048
+ children: [E("mybodyshield.pages.nutrition.protein", "Protein"), " (g)"]
1049
+ }), /* @__PURE__ */ g(b, {
1004
1050
  id: "meal-protein",
1005
1051
  type: "number",
1006
1052
  min: 0,
1007
- value: R.proteinG,
1008
- onChange: (e) => z({
1009
- ...R,
1053
+ value: z.proteinG,
1054
+ onChange: (e) => B({
1055
+ ...z,
1010
1056
  proteinG: e.target.value
1011
1057
  }),
1012
- placeholder: "0"
1058
+ placeholder: E("mybodyshield.pages.nutrition.proteinPlaceholder", "0")
1013
1059
  })]
1014
1060
  }),
1015
- /* @__PURE__ */ g("div", {
1061
+ /* @__PURE__ */ _("div", {
1016
1062
  className: "space-y-1.5",
1017
- children: [/* @__PURE__ */ h(b, {
1063
+ children: [/* @__PURE__ */ _(x, {
1018
1064
  htmlFor: "meal-carbs",
1019
- children: "Carbs (g)"
1020
- }), /* @__PURE__ */ h(y, {
1065
+ children: [E("mybodyshield.pages.nutrition.carbs", "Carbs"), " (g)"]
1066
+ }), /* @__PURE__ */ g(b, {
1021
1067
  id: "meal-carbs",
1022
1068
  type: "number",
1023
1069
  min: 0,
1024
- value: R.carbsG,
1025
- onChange: (e) => z({
1026
- ...R,
1070
+ value: z.carbsG,
1071
+ onChange: (e) => B({
1072
+ ...z,
1027
1073
  carbsG: e.target.value
1028
1074
  }),
1029
- placeholder: "0"
1075
+ placeholder: E("mybodyshield.pages.nutrition.carbsPlaceholder", "0")
1030
1076
  })]
1031
1077
  }),
1032
- /* @__PURE__ */ g("div", {
1078
+ /* @__PURE__ */ _("div", {
1033
1079
  className: "space-y-1.5",
1034
- children: [/* @__PURE__ */ h(b, {
1080
+ children: [/* @__PURE__ */ _(x, {
1035
1081
  htmlFor: "meal-fat",
1036
- children: "Fat (g)"
1037
- }), /* @__PURE__ */ h(y, {
1082
+ children: [E("mybodyshield.pages.nutrition.fat", "Fat"), " (g)"]
1083
+ }), /* @__PURE__ */ g(b, {
1038
1084
  id: "meal-fat",
1039
1085
  type: "number",
1040
1086
  min: 0,
1041
- value: R.fatG,
1042
- onChange: (e) => z({
1043
- ...R,
1087
+ value: z.fatG,
1088
+ onChange: (e) => B({
1089
+ ...z,
1044
1090
  fatG: e.target.value
1045
1091
  }),
1046
- placeholder: "0"
1092
+ placeholder: E("mybodyshield.pages.nutrition.fatPlaceholder", "0")
1047
1093
  })]
1048
1094
  })
1049
1095
  ]
1050
1096
  }),
1051
- /* @__PURE__ */ g("div", {
1097
+ /* @__PURE__ */ _("div", {
1052
1098
  className: "flex items-center justify-between gap-4 rounded-xl bg-bg-sunken/60 p-3",
1053
- children: [/* @__PURE__ */ g("div", {
1099
+ children: [/* @__PURE__ */ _("div", {
1054
1100
  className: "min-w-0",
1055
- children: [/* @__PURE__ */ h(b, {
1101
+ children: [/* @__PURE__ */ g(x, {
1056
1102
  htmlFor: "meal-favorite",
1057
1103
  className: "cursor-pointer",
1058
- children: "Favorite"
1059
- }), /* @__PURE__ */ h("p", {
1104
+ children: E("mybodyshield.pages.nutrition.favorite", "Favorite")
1105
+ }), /* @__PURE__ */ g("p", {
1060
1106
  className: "text-xs text-text-tertiary",
1061
- children: "Save for quick re-log"
1107
+ children: E("mybodyshield.pages.nutrition.favoriteHint", "Save for quick re-log")
1062
1108
  })]
1063
- }), /* @__PURE__ */ h(Ke, {
1109
+ }), /* @__PURE__ */ g(Ke, {
1064
1110
  id: "meal-favorite",
1065
- checked: R.isFavorite,
1066
- onCheckedChange: (e) => z({
1067
- ...R,
1111
+ checked: z.isFavorite,
1112
+ onCheckedChange: (e) => B({
1113
+ ...z,
1068
1114
  isFavorite: e
1069
1115
  })
1070
1116
  })]
1071
1117
  })
1072
1118
  ]
1073
1119
  }),
1074
- /* @__PURE__ */ g(Re, { children: [/* @__PURE__ */ h(_, {
1120
+ /* @__PURE__ */ _(Re, { children: [/* @__PURE__ */ g(v, {
1075
1121
  variant: "outline",
1076
- onClick: () => L(!1),
1077
- disabled: N.isPending,
1078
- children: "Cancel"
1079
- }), /* @__PURE__ */ h(_, {
1080
- onClick: Dt,
1081
- disabled: N.isPending,
1082
- children: N.isPending ? "Logging…" : "Log meal"
1122
+ onClick: () => R(!1),
1123
+ disabled: F.isPending,
1124
+ children: E("mybodyshield.common.cancel", "Cancel")
1125
+ }), /* @__PURE__ */ g(v, {
1126
+ onClick: Mt,
1127
+ disabled: F.isPending,
1128
+ children: F.isPending ? E("mybodyshield.common.logging", "Logging…") : E("mybodyshield.pages.nutrition.logMeal", "Log meal")
1083
1129
  })] })
1084
1130
  ]
1085
1131
  })
1086
1132
  }),
1087
- /* @__PURE__ */ h(Fe, {
1088
- open: yt,
1133
+ /* @__PURE__ */ g(Fe, {
1134
+ open: Ct,
1089
1135
  onOpenChange: W,
1090
- children: /* @__PURE__ */ g(Ie, {
1136
+ children: /* @__PURE__ */ _(Ie, {
1091
1137
  className: "sm:max-w-lg",
1092
1138
  children: [
1093
- /* @__PURE__ */ g(ze, { children: [/* @__PURE__ */ h(Be, { children: G === "edit" ? "Edit nutrition targets" : "Create nutrition plan" }), /* @__PURE__ */ h(Le, { children: G === "edit" ? "Update your calorie and macro targets for this plan." : "Set your daily calorie and macro targets." })] }),
1094
- /* @__PURE__ */ g("div", {
1139
+ /* @__PURE__ */ _(ze, { children: [/* @__PURE__ */ g(Be, { children: G === "edit" ? E("mybodyshield.pages.nutrition.editTargetsDialogTitle", "Edit nutrition targets") : E("mybodyshield.pages.nutrition.createPlanDialogTitle", "Create nutrition plan") }), /* @__PURE__ */ g(Le, { children: G === "edit" ? E("mybodyshield.pages.nutrition.editTargetsDescription", "Update your calorie and macro targets for this plan.") : E("mybodyshield.pages.nutrition.createPlanDescription", "Set your daily calorie and macro targets.") })] }),
1140
+ /* @__PURE__ */ _("div", {
1095
1141
  className: "space-y-4 py-2",
1096
1142
  children: [
1097
- xt && /* @__PURE__ */ h("div", {
1143
+ Tt && /* @__PURE__ */ g("div", {
1098
1144
  className: "rounded-lg border border-status-error-text/40 bg-status-error-bg-subtle px-3 py-2 text-sm text-status-error-text",
1099
- children: xt
1145
+ children: Tt
1100
1146
  }),
1101
- /* @__PURE__ */ g("div", {
1147
+ /* @__PURE__ */ _("div", {
1102
1148
  className: "space-y-1.5",
1103
- children: [/* @__PURE__ */ h(b, {
1149
+ children: [/* @__PURE__ */ g(x, {
1104
1150
  htmlFor: "plan-name",
1105
- children: "Name"
1106
- }), /* @__PURE__ */ h(y, {
1151
+ children: E("mybodyshield.common.name", "Name")
1152
+ }), /* @__PURE__ */ g(b, {
1107
1153
  id: "plan-name",
1108
1154
  value: K.name,
1109
1155
  onChange: (e) => q({
1110
1156
  ...K,
1111
1157
  name: e.target.value
1112
1158
  }),
1113
- placeholder: "Lean bulk — Q3"
1159
+ placeholder: E("mybodyshield.pages.nutrition.planNamePlaceholder", "Lean bulk — Q3")
1114
1160
  })]
1115
1161
  }),
1116
- /* @__PURE__ */ g("div", {
1162
+ /* @__PURE__ */ _("div", {
1117
1163
  className: "space-y-1.5",
1118
- children: [/* @__PURE__ */ h(b, {
1164
+ children: [/* @__PURE__ */ g(x, {
1119
1165
  htmlFor: "plan-goal",
1120
- children: "Goal type"
1121
- }), /* @__PURE__ */ g(Ve, {
1166
+ children: E("mybodyshield.common.goalType", "Goal type")
1167
+ }), /* @__PURE__ */ _(Ve, {
1122
1168
  value: K.goalType,
1123
1169
  onValueChange: (e) => q({
1124
1170
  ...K,
1125
1171
  goalType: e
1126
1172
  }),
1127
- children: [/* @__PURE__ */ h(We, {
1173
+ children: [/* @__PURE__ */ g(We, {
1128
1174
  id: "plan-goal",
1129
- children: /* @__PURE__ */ h(Ge, {})
1130
- }), /* @__PURE__ */ h(He, { children: Ye.map((e) => /* @__PURE__ */ h(Ue, {
1175
+ children: /* @__PURE__ */ g(Ge, {})
1176
+ }), /* @__PURE__ */ g(He, { children: Ye.map((e) => /* @__PURE__ */ g(Ue, {
1131
1177
  value: e,
1132
1178
  children: n(e)
1133
1179
  }, e)) })]
1134
1180
  })]
1135
1181
  }),
1136
- /* @__PURE__ */ g("div", {
1182
+ /* @__PURE__ */ _("div", {
1137
1183
  className: "grid grid-cols-2 gap-3",
1138
1184
  children: [
1139
- /* @__PURE__ */ g("div", {
1185
+ /* @__PURE__ */ _("div", {
1140
1186
  className: "space-y-1.5",
1141
- children: [/* @__PURE__ */ h(b, {
1187
+ children: [/* @__PURE__ */ _(x, {
1142
1188
  htmlFor: "plan-calories",
1143
- children: "Calorie target (kcal)"
1144
- }), /* @__PURE__ */ h(y, {
1189
+ children: [E("mybodyshield.pages.nutrition.calorieTarget", "Calorie target"), " (kcal)"]
1190
+ }), /* @__PURE__ */ g(b, {
1145
1191
  id: "plan-calories",
1146
1192
  type: "number",
1147
1193
  min: 0,
@@ -1150,15 +1196,15 @@ function T() {
1150
1196
  ...K,
1151
1197
  calorieTarget: e.target.value
1152
1198
  }),
1153
- placeholder: "2400"
1199
+ placeholder: E("mybodyshield.pages.nutrition.calorieTargetPlaceholder", "2400")
1154
1200
  })]
1155
1201
  }),
1156
- /* @__PURE__ */ g("div", {
1202
+ /* @__PURE__ */ _("div", {
1157
1203
  className: "space-y-1.5",
1158
- children: [/* @__PURE__ */ h(b, {
1204
+ children: [/* @__PURE__ */ _(x, {
1159
1205
  htmlFor: "plan-protein",
1160
- children: "Protein target (g)"
1161
- }), /* @__PURE__ */ h(y, {
1206
+ children: [E("mybodyshield.pages.nutrition.proteinTarget", "Protein target"), " (g)"]
1207
+ }), /* @__PURE__ */ g(b, {
1162
1208
  id: "plan-protein",
1163
1209
  type: "number",
1164
1210
  min: 0,
@@ -1167,15 +1213,15 @@ function T() {
1167
1213
  ...K,
1168
1214
  proteinTarget: e.target.value
1169
1215
  }),
1170
- placeholder: "180"
1216
+ placeholder: E("mybodyshield.pages.nutrition.proteinTargetPlaceholder", "180")
1171
1217
  })]
1172
1218
  }),
1173
- /* @__PURE__ */ g("div", {
1219
+ /* @__PURE__ */ _("div", {
1174
1220
  className: "space-y-1.5",
1175
- children: [/* @__PURE__ */ h(b, {
1221
+ children: [/* @__PURE__ */ _(x, {
1176
1222
  htmlFor: "plan-carbs",
1177
- children: "Carbs target (g)"
1178
- }), /* @__PURE__ */ h(y, {
1223
+ children: [E("mybodyshield.pages.nutrition.carbsTarget", "Carbs target"), " (g)"]
1224
+ }), /* @__PURE__ */ g(b, {
1179
1225
  id: "plan-carbs",
1180
1226
  type: "number",
1181
1227
  min: 0,
@@ -1184,15 +1230,15 @@ function T() {
1184
1230
  ...K,
1185
1231
  carbsTarget: e.target.value
1186
1232
  }),
1187
- placeholder: "250"
1233
+ placeholder: E("mybodyshield.pages.nutrition.carbsTargetPlaceholder", "250")
1188
1234
  })]
1189
1235
  }),
1190
- /* @__PURE__ */ g("div", {
1236
+ /* @__PURE__ */ _("div", {
1191
1237
  className: "space-y-1.5",
1192
- children: [/* @__PURE__ */ h(b, {
1238
+ children: [/* @__PURE__ */ _(x, {
1193
1239
  htmlFor: "plan-fat",
1194
- children: "Fat target (g)"
1195
- }), /* @__PURE__ */ h(y, {
1240
+ children: [E("mybodyshield.pages.nutrition.fatTarget", "Fat target"), " (g)"]
1241
+ }), /* @__PURE__ */ g(b, {
1196
1242
  id: "plan-fat",
1197
1243
  type: "number",
1198
1244
  min: 0,
@@ -1201,19 +1247,19 @@ function T() {
1201
1247
  ...K,
1202
1248
  fatTarget: e.target.value
1203
1249
  }),
1204
- placeholder: "70"
1250
+ placeholder: E("mybodyshield.pages.nutrition.fatTargetPlaceholder", "70")
1205
1251
  })]
1206
1252
  })
1207
1253
  ]
1208
1254
  }),
1209
- /* @__PURE__ */ g("div", {
1255
+ /* @__PURE__ */ _("div", {
1210
1256
  className: "grid grid-cols-2 gap-3",
1211
- children: [/* @__PURE__ */ g("div", {
1257
+ children: [/* @__PURE__ */ _("div", {
1212
1258
  className: "space-y-1.5",
1213
- children: [/* @__PURE__ */ h(b, {
1259
+ children: [/* @__PURE__ */ g(x, {
1214
1260
  htmlFor: "plan-start",
1215
- children: "Start date"
1216
- }), /* @__PURE__ */ h(y, {
1261
+ children: E("mybodyshield.common.startDate", "Start date")
1262
+ }), /* @__PURE__ */ g(b, {
1217
1263
  id: "plan-start",
1218
1264
  type: "date",
1219
1265
  value: K.startDate,
@@ -1222,12 +1268,12 @@ function T() {
1222
1268
  startDate: e.target.value
1223
1269
  })
1224
1270
  })]
1225
- }), /* @__PURE__ */ g("div", {
1271
+ }), /* @__PURE__ */ _("div", {
1226
1272
  className: "space-y-1.5",
1227
- children: [/* @__PURE__ */ h(b, {
1273
+ children: [/* @__PURE__ */ g(x, {
1228
1274
  htmlFor: "plan-end",
1229
- children: "End date"
1230
- }), /* @__PURE__ */ h(y, {
1275
+ children: E("mybodyshield.common.endDate", "End date")
1276
+ }), /* @__PURE__ */ g(b, {
1231
1277
  id: "plan-end",
1232
1278
  type: "date",
1233
1279
  value: K.endDate,
@@ -1238,33 +1284,33 @@ function T() {
1238
1284
  })]
1239
1285
  })]
1240
1286
  }),
1241
- /* @__PURE__ */ g("div", {
1287
+ /* @__PURE__ */ _("div", {
1242
1288
  className: "space-y-1.5",
1243
- children: [/* @__PURE__ */ h(b, {
1289
+ children: [/* @__PURE__ */ g(x, {
1244
1290
  htmlFor: "plan-notes",
1245
- children: "Notes"
1246
- }), /* @__PURE__ */ h(qe, {
1291
+ children: E("mybodyshield.common.notes", "Notes")
1292
+ }), /* @__PURE__ */ g(qe, {
1247
1293
  id: "plan-notes",
1248
1294
  value: K.notes,
1249
1295
  onChange: (e) => q({
1250
1296
  ...K,
1251
1297
  notes: e.target.value
1252
1298
  }),
1253
- placeholder: "Coaching notes, refeed schedule, supplements…",
1299
+ placeholder: E("mybodyshield.pages.nutrition.planNotesPlaceholder", "Coaching notes, refeed schedule, supplements…"),
1254
1300
  rows: 3
1255
1301
  })]
1256
1302
  })
1257
1303
  ]
1258
1304
  }),
1259
- /* @__PURE__ */ g(Re, { children: [/* @__PURE__ */ h(_, {
1305
+ /* @__PURE__ */ _(Re, { children: [/* @__PURE__ */ g(v, {
1260
1306
  variant: "outline",
1261
1307
  onClick: () => W(!1),
1262
- disabled: jt,
1263
- children: "Cancel"
1264
- }), /* @__PURE__ */ h(_, {
1265
- onClick: Ot,
1266
- disabled: jt,
1267
- children: jt ? "Saving…" : G === "edit" ? "Save targets" : "Create plan"
1308
+ disabled: Z,
1309
+ children: E("mybodyshield.common.cancel", "Cancel")
1310
+ }), /* @__PURE__ */ g(v, {
1311
+ onClick: Nt,
1312
+ disabled: Z,
1313
+ children: Z ? E("mybodyshield.common.saving", "Saving…") : G === "edit" ? E("mybodyshield.pages.nutrition.saveTargets", "Save targets") : E("mybodyshield.pages.nutrition.createPlan", "Create plan")
1268
1314
  })] })
1269
1315
  ]
1270
1316
  })
@@ -1273,6 +1319,6 @@ function T() {
1273
1319
  });
1274
1320
  }
1275
1321
  //#endregion
1276
- export { T as NutritionPage };
1322
+ export { E as NutritionPage };
1277
1323
 
1278
1324
  //# sourceMappingURL=NutritionPage.js.map