@burdenoff/microfe-healthybowl 2026.625.2 → 2026.625.3

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.
@@ -9,17 +9,18 @@ import { ToastContainer as re } from "../../components/Toast.js";
9
9
  import { useConfirm as ie } from "../../components/ConfirmDialog.js";
10
10
  import { PageLoader as ae } from "../../components/PageLoader.js";
11
11
  import { Modal as oe } from "../../components/Modal.js";
12
- import { HBEntityImages as a } from "../../components/HBEntityImages.js";
12
+ import { HBEntityImages as se } from "../../components/HBEntityImages.js";
13
13
  import "../../components/index.js";
14
- import { useHealthyBowlData as se } from "../../hooks/useHealthyBowlData.js";
15
- import { useToast as ce } from "../../hooks/useToast.js";
16
- import { useMemo as o, useState as s } from "react";
17
- import { useI18n as le } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
18
- import { ArrowLeft as ue, Calendar as de, ChevronRight as fe, Edit as pe, Heart as c, Milk as l, Plus as u, Stethoscope as me, Syringe as he, Trash2 as ge, TrendingUp as _e, Weight as ve } from "lucide-react";
19
- import { useNavigate as ye, useParams as be } from "react-router-dom";
20
- import { Fragment as xe, jsx as d, jsxs as f } from "react/jsx-runtime";
14
+ import { useHealthyBowlData as ce } from "../../hooks/useHealthyBowlData.js";
15
+ import { useToast as le } from "../../hooks/useToast.js";
16
+ import { useMemo as a, useState as o } from "react";
17
+ import { useI18n as ue } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
18
+ import { ArrowLeft as de, Calendar as fe, ChevronRight as pe, Edit as me, Heart as he, Milk as s, Plus as c, Stethoscope as ge, Syringe as _e, Trash2 as ve, TrendingUp as ye, Weight as be } from "lucide-react";
19
+ import { useNavigate as xe, useParams as Se } from "react-router-dom";
20
+ import { Fragment as Ce, jsx as l, jsxs as u } from "react/jsx-runtime";
21
+ import { Button as d, Select as f, SelectContent as p, SelectItem as m, SelectTrigger as h, SelectValue as g } from "@burdenoff/fe-libs/ui";
21
22
  //#region src/healthybowl/pages/livestock/AnimalDetailsPage.tsx
22
- var p = (e) => {
23
+ var _ = (e) => {
23
24
  switch (e) {
24
25
  case "healthy": return "success";
25
26
  case "pregnant": return "info";
@@ -28,7 +29,7 @@ var p = (e) => {
28
29
  case "quarantine": return "error";
29
30
  default: return "muted";
30
31
  }
31
- }, Se = (e) => {
32
+ }, we = (e) => {
32
33
  switch (e) {
33
34
  case "cattle":
34
35
  case "buffalo": return "🐄";
@@ -38,82 +39,82 @@ var p = (e) => {
38
39
  case "poultry": return "🐔";
39
40
  default: return "🐾";
40
41
  }
41
- }, m = () => {
42
- let { animals: m, healthRecords: h, vaccinations: g, breedingRecords: _, productionRecords: Ce, updateAnimal: we, deleteAnimal: Te, errors: Ee, loadings: De, refetch: Oe } = se(), { t: v } = le(), ke = ie(), { animalId: Ae } = be(), y = ye(), { buildPath: b } = ee(), [x, je] = s("overview"), [Me, S] = s(!1), [C, w] = s(!1), { toasts: Ne, toast: T, dismiss: Pe } = ce(), E = m.find((e) => e.id === Ae), [D, O] = s(""), [k, A] = s(""), [j, M] = s(""), [N, P] = s(""), [F, I] = s(""), [L, R] = s(""), [z, B] = s(""), [V, H] = s(""), [U, W] = s(""), [G, K] = s(""), [q, Fe] = s(""), [Ie, Le] = s([]), Re = () => {
43
- E && (O(E.name), A(E.type), M(E.breed), P(E.gender), I(E.healthStatus), R(E.tagNumber), B(String(E.vaccinations ?? 0)), H(String(E.weight ?? 0)), W(E.dateOfBirth ?? ""), K(E.lastCheckup ?? ""), Fe(E.productionType ?? ""), Le(E.imageIds ?? []), S(!0));
44
- }, ze = async () => {
45
- if (E) {
46
- if (!D.trim() || !L.trim()) {
47
- T({
48
- title: v("healthybowl.livestock.animalDetails.toast.missingFields.title", "Missing required fields"),
49
- description: v("healthybowl.livestock.animalDetails.toast.missingFields.description", "Name and tag number are required."),
42
+ }, v = () => {
43
+ let { animals: v, healthRecords: Te, vaccinations: Ee, breedingRecords: De, productionRecords: Oe, updateAnimal: ke, deleteAnimal: Ae, errors: je, loadings: Me, refetch: Ne } = ce(), { t: y } = ue(), Pe = ie(), { animalId: Fe } = Se(), b = xe(), { buildPath: x } = ee(), [S, C] = o("overview"), [Ie, w] = o(!1), [T, E] = o(!1), { toasts: Le, toast: D, dismiss: Re } = le(), O = v.find((e) => e.id === Fe), [k, A] = o(""), [j, M] = o(""), [N, P] = o(""), [F, I] = o(""), [L, R] = o(""), [z, B] = o(""), [V, H] = o(""), [U, W] = o(""), [G, ze] = o(""), [K, Be] = o(""), [q, Ve] = o(""), [He, Ue] = o([]), We = () => {
44
+ O && (A(O.name), M(O.type), P(O.breed), I(O.gender), R(O.healthStatus), B(O.tagNumber), H(String(O.vaccinations ?? 0)), W(String(O.weight ?? 0)), ze(O.dateOfBirth ?? ""), Be(O.lastCheckup ?? ""), Ve(O.productionType ?? ""), Ue(O.imageIds ?? []), w(!0));
45
+ }, Ge = async () => {
46
+ if (O) {
47
+ if (!k.trim() || !z.trim()) {
48
+ D({
49
+ title: y("healthybowl.livestock.animalDetails.toast.missingFields.title", "Missing required fields"),
50
+ description: y("healthybowl.livestock.animalDetails.toast.missingFields.description", "Name and tag number are required."),
50
51
  variant: "warning"
51
52
  });
52
53
  return;
53
54
  }
54
- w(!0);
55
+ E(!0);
55
56
  try {
56
- await we({
57
- id: E.id,
58
- name: D.trim(),
59
- type: k.trim() || "unknown",
60
- breed: j.trim() || "Unknown",
61
- gender: N.trim() || "unknown",
62
- healthStatus: F.trim() || "healthy",
63
- tagNumber: L.trim(),
64
- vaccinations: Number(z) || 0,
65
- weight: Number(V) || 0,
66
- imageIds: Ie,
67
- ...U ? { dateOfBirth: U } : {},
68
- ...G ? { lastCheckup: G } : {},
57
+ await ke({
58
+ id: O.id,
59
+ name: k.trim(),
60
+ type: j.trim() || "unknown",
61
+ breed: N.trim() || "Unknown",
62
+ gender: F.trim() || "unknown",
63
+ healthStatus: L.trim() || "healthy",
64
+ tagNumber: z.trim(),
65
+ vaccinations: Number(V) || 0,
66
+ weight: Number(U) || 0,
67
+ imageIds: He,
68
+ ...G ? { dateOfBirth: G } : {},
69
+ ...K ? { lastCheckup: K } : {},
69
70
  ...q.trim() ? { productionType: q.trim() } : {}
70
- }), T({
71
- title: v("healthybowl.livestock.animalDetails.toast.updated.title", "Animal updated"),
72
- description: v("healthybowl.livestock.animalDetails.toast.updated.description", "{{name}} has been saved.", { name: D.trim() }),
71
+ }), D({
72
+ title: y("healthybowl.livestock.animalDetails.toast.updated.title", "Animal updated"),
73
+ description: y("healthybowl.livestock.animalDetails.toast.updated.description", "{{name}} has been saved.", { name: k.trim() }),
73
74
  variant: "success"
74
- }), S(!1);
75
+ }), w(!1);
75
76
  } catch (e) {
76
- T({
77
- title: v("healthybowl.livestock.animalDetails.toast.updateFailed.title", "Update failed"),
77
+ D({
78
+ title: y("healthybowl.livestock.animalDetails.toast.updateFailed.title", "Update failed"),
78
79
  description: String(e),
79
80
  variant: "error"
80
81
  });
81
82
  } finally {
82
- w(!1);
83
+ E(!1);
83
84
  }
84
85
  }
85
- }, Be = async () => {
86
- if (E && await ke({
87
- title: v("healthybowl.livestock.animalDetails.confirmDelete.title", "Delete animal?"),
88
- message: v("healthybowl.livestock.animalDetails.confirmDelete.message", "{{name}} ({{tagNumber}}) will be permanently removed.", {
89
- name: E.name,
90
- tagNumber: E.tagNumber
86
+ }, Ke = async () => {
87
+ if (O && await Pe({
88
+ title: y("healthybowl.livestock.animalDetails.confirmDelete.title", "Delete animal?"),
89
+ message: y("healthybowl.livestock.animalDetails.confirmDelete.message", "{{name}} ({{tagNumber}}) will be permanently removed.", {
90
+ name: O.name,
91
+ tagNumber: O.tagNumber
91
92
  }),
92
- okButtonTitle: v("healthybowl.common.delete", "Delete"),
93
- cancelButtonTitle: v("healthybowl.common.cancel", "Cancel")
93
+ okButtonTitle: y("healthybowl.common.delete", "Delete"),
94
+ cancelButtonTitle: y("healthybowl.common.cancel", "Cancel")
94
95
  }) !== !1) {
95
- w(!0);
96
+ E(!0);
96
97
  try {
97
- await Te(E.id), T({
98
- title: v("healthybowl.livestock.animalDetails.toast.deleted.title", "Animal deleted"),
99
- description: v("healthybowl.livestock.animalDetails.toast.deleted.description", "{{name}} has been removed.", { name: E.name }),
98
+ await Ae(O.id), D({
99
+ title: y("healthybowl.livestock.animalDetails.toast.deleted.title", "Animal deleted"),
100
+ description: y("healthybowl.livestock.animalDetails.toast.deleted.description", "{{name}} has been removed.", { name: O.name }),
100
101
  variant: "success"
101
- }), y(b("livestock/animals"));
102
+ }), b(x("livestock/animals"));
102
103
  } catch (e) {
103
- T({
104
- title: v("healthybowl.livestock.animalDetails.toast.deleteFailed.title", "Delete failed"),
104
+ D({
105
+ title: y("healthybowl.livestock.animalDetails.toast.deleteFailed.title", "Delete failed"),
105
106
  description: String(e),
106
107
  variant: "error"
107
- }), w(!1);
108
+ }), E(!1);
108
109
  }
109
110
  }
110
- }, J = o(() => E ? h.filter((e) => e.animalId === E.id) : [], [h, E]), Y = o(() => E ? g.filter((e) => e.animalId === E.id) : [], [g, E]), X = o(() => E ? _.filter((e) => e.femaleId === E.id || e.maleId === E.id) : [], [_, E]), Z = o(() => E ? Ce.filter((e) => e.animalId === E.id) : [], [Ce, E]), Q = Z.filter((e) => e.type === "milk"), Ve = Q.length > 0 ? Q.reduce((e, t) => e + t.quantity, 0) / Q.length : 0, He = J.length > 0 ? Math.max(0, 100 - J.filter((e) => e.status === "active" || e.status === "monitoring").length * 15) : 100, $ = Z.length > 0 ? Z[0] : null, Ue = o(() => {
111
+ }, J = a(() => O ? Te.filter((e) => e.animalId === O.id) : [], [Te, O]), Y = a(() => O ? Ee.filter((e) => e.animalId === O.id) : [], [Ee, O]), X = a(() => O ? De.filter((e) => e.femaleId === O.id || e.maleId === O.id) : [], [De, O]), Z = a(() => O ? Oe.filter((e) => e.animalId === O.id) : [], [Oe, O]), Q = Z.filter((e) => e.type === "milk"), qe = Q.length > 0 ? Q.reduce((e, t) => e + t.quantity, 0) / Q.length : 0, Je = J.length > 0 ? Math.max(0, 100 - J.filter((e) => e.status === "active" || e.status === "monitoring").length * 15) : 100, $ = Z.length > 0 ? Z[0] : null, Ye = a(() => {
111
112
  let e = [];
112
113
  for (let t of J) e.push({
113
114
  id: t.id,
114
115
  date: t.date,
115
116
  category: "Health",
116
- categoryLabel: v("healthybowl.livestock.animalDetails.timeline.category.health", "Health"),
117
+ categoryLabel: y("healthybowl.livestock.animalDetails.timeline.category.health", "Health"),
117
118
  title: `${t.type} - ${t.diagnosis}`,
118
119
  detail: t.veterinarian
119
120
  });
@@ -121,7 +122,7 @@ var p = (e) => {
121
122
  id: t.id,
122
123
  date: t.administrationDate,
123
124
  category: "Vaccination",
124
- categoryLabel: v("healthybowl.livestock.animalDetails.timeline.category.vaccination", "Vaccination"),
125
+ categoryLabel: y("healthybowl.livestock.animalDetails.timeline.category.vaccination", "Vaccination"),
125
126
  title: t.vaccineName,
126
127
  detail: t.veterinarian
127
128
  });
@@ -129,7 +130,7 @@ var p = (e) => {
129
130
  id: t.id,
130
131
  date: t.date,
131
132
  category: "Production",
132
- categoryLabel: v("healthybowl.livestock.animalDetails.timeline.category.production", "Production"),
133
+ categoryLabel: y("healthybowl.livestock.animalDetails.timeline.category.production", "Production"),
133
134
  title: `${t.type} - ${t.quantity} ${t.unit}`,
134
135
  detail: t.quality
135
136
  });
@@ -138,211 +139,212 @@ var p = (e) => {
138
139
  J,
139
140
  Y,
140
141
  Z,
141
- v
142
+ y
142
143
  ]);
143
- if (!E) return /* @__PURE__ */ d(n, {
144
- title: v("healthybowl.livestock.animalDetails.notFound.pageTitle", "Animal Not Found"),
145
- children: De.livestock ? /* @__PURE__ */ d(ae, {}) : Ee.livestock ? /* @__PURE__ */ d(ne, { onRetry: Oe }) : /* @__PURE__ */ d(te, {
146
- title: v("healthybowl.livestock.animalDetails.notFound.title", "Animal not found"),
147
- description: v("healthybowl.livestock.animalDetails.notFound.description", "The animal you are looking for does not exist."),
148
- action: /* @__PURE__ */ d("button", {
149
- onClick: () => y(b("livestock/animals")),
150
- className: "rounded-md bg-action-primary-bg px-4 py-2 text-sm text-action-primary-text",
151
- children: v("healthybowl.livestock.animalDetails.notFound.backToRegistry", "Back to Registry")
144
+ if (!O) return /* @__PURE__ */ l(n, {
145
+ title: y("healthybowl.livestock.animalDetails.notFound.pageTitle", "Animal Not Found"),
146
+ children: Me.livestock ? /* @__PURE__ */ l(ae, {}) : je.livestock ? /* @__PURE__ */ l(ne, { onRetry: Ne }) : /* @__PURE__ */ l(te, {
147
+ title: y("healthybowl.livestock.animalDetails.notFound.title", "Animal not found"),
148
+ description: y("healthybowl.livestock.animalDetails.notFound.description", "The animal you are looking for does not exist."),
149
+ action: /* @__PURE__ */ l(d, {
150
+ onClick: () => b(x("livestock/animals")),
151
+ children: y("healthybowl.livestock.animalDetails.notFound.backToRegistry", "Back to Registry")
152
152
  })
153
153
  })
154
154
  });
155
- let We = [
155
+ let Xe = [
156
156
  {
157
157
  id: "overview",
158
- label: v("healthybowl.livestock.animalDetails.tabs.overview", "Overview")
158
+ label: y("healthybowl.livestock.animalDetails.tabs.overview", "Overview")
159
159
  },
160
160
  {
161
161
  id: "health",
162
- label: v("healthybowl.livestock.animalDetails.tabs.health", "Health")
162
+ label: y("healthybowl.livestock.animalDetails.tabs.health", "Health")
163
163
  },
164
164
  {
165
165
  id: "breeding",
166
- label: v("healthybowl.livestock.animalDetails.tabs.breeding", "Breeding")
166
+ label: y("healthybowl.livestock.animalDetails.tabs.breeding", "Breeding")
167
167
  },
168
168
  {
169
169
  id: "production",
170
- label: v("healthybowl.livestock.animalDetails.tabs.production", "Production")
170
+ label: y("healthybowl.livestock.animalDetails.tabs.production", "Production")
171
171
  },
172
172
  {
173
173
  id: "timeline",
174
- label: v("healthybowl.livestock.animalDetails.tabs.timeline", "Timeline")
174
+ label: y("healthybowl.livestock.animalDetails.tabs.timeline", "Timeline")
175
175
  }
176
176
  ];
177
- return /* @__PURE__ */ f(n, {
178
- title: `${E.name} (${E.tagNumber})`,
179
- description: `${E.breed} ${E.type}`,
180
- actions: /* @__PURE__ */ f("div", {
177
+ return /* @__PURE__ */ u(n, {
178
+ title: `${O.name} (${O.tagNumber})`,
179
+ description: `${O.breed} ${O.type}`,
180
+ actions: /* @__PURE__ */ u("div", {
181
181
  className: "flex items-center gap-2",
182
182
  children: [
183
- /* @__PURE__ */ f("button", {
184
- onClick: () => y(b("livestock/animals")),
185
- className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-3 py-2 text-sm text-text-primary hover:bg-bg-sunken/50",
183
+ /* @__PURE__ */ u(d, {
184
+ variant: "outline",
185
+ onClick: () => b(x("livestock/animals")),
186
186
  children: [
187
- /* @__PURE__ */ d(ue, { className: "h-4 w-4" }),
187
+ /* @__PURE__ */ l(de, { className: "h-4 w-4" }),
188
188
  " ",
189
- v("healthybowl.common.back", "Back")
189
+ y("healthybowl.common.back", "Back")
190
190
  ]
191
191
  }),
192
- /* @__PURE__ */ f("button", {
193
- onClick: Re,
194
- className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90",
192
+ /* @__PURE__ */ u(d, {
193
+ onClick: We,
195
194
  children: [
196
- /* @__PURE__ */ d(pe, { className: "h-4 w-4" }),
195
+ /* @__PURE__ */ l(me, { className: "h-4 w-4" }),
197
196
  " ",
198
- v("healthybowl.livestock.animalDetails.actions.editDetails", "Edit Details")
197
+ y("healthybowl.livestock.animalDetails.actions.editDetails", "Edit Details")
199
198
  ]
200
199
  }),
201
- /* @__PURE__ */ f("button", {
202
- onClick: Be,
203
- disabled: C,
204
- className: "inline-flex items-center gap-1.5 rounded-md border border-border-subtle px-3 py-2 text-sm text-status-error-text hover:bg-status-error-bg/10 disabled:opacity-60",
200
+ /* @__PURE__ */ u(d, {
201
+ variant: "destructive",
202
+ onClick: Ke,
203
+ disabled: T,
205
204
  children: [
206
- /* @__PURE__ */ d(ge, { className: "h-4 w-4" }),
205
+ /* @__PURE__ */ l(ve, { className: "h-4 w-4" }),
207
206
  " ",
208
- v("healthybowl.common.delete", "Delete")
207
+ y("healthybowl.common.delete", "Delete")
209
208
  ]
210
209
  })
211
210
  ]
212
211
  }),
213
212
  children: [
214
- /* @__PURE__ */ f("div", {
213
+ /* @__PURE__ */ u("div", {
215
214
  className: "flex flex-wrap items-center gap-3",
216
215
  children: [
217
- /* @__PURE__ */ d(i, {
218
- label: (E.healthStatus ?? "").replace("_", " "),
219
- variant: p(E.healthStatus),
216
+ /* @__PURE__ */ l(i, {
217
+ label: (O.healthStatus ?? "").replace("_", " "),
218
+ variant: _(O.healthStatus),
220
219
  dot: !0
221
220
  }),
222
- /* @__PURE__ */ d(i, {
223
- label: E.gender,
221
+ /* @__PURE__ */ l(i, {
222
+ label: O.gender,
224
223
  variant: "muted"
225
224
  }),
226
- E.productionType && /* @__PURE__ */ d(i, {
227
- label: E.productionType,
225
+ O.productionType && /* @__PURE__ */ l(i, {
226
+ label: O.productionType,
228
227
  variant: "info"
229
228
  })
230
229
  ]
231
230
  }),
232
- /* @__PURE__ */ d("div", {
231
+ /* @__PURE__ */ l("div", {
233
232
  className: "border-b border-border-subtle",
234
- children: /* @__PURE__ */ d("nav", {
233
+ children: /* @__PURE__ */ l("nav", {
235
234
  className: "-mb-px flex gap-6 overflow-x-auto",
236
- children: We.map((e) => /* @__PURE__ */ d("button", {
237
- onClick: () => je(e.id),
238
- className: `whitespace-nowrap border-b-2 py-2 px-1 text-sm font-medium ${x === e.id ? "border-primary text-primary" : "border-transparent text-text-secondary hover:text-text-primary hover:border-border-subtle"}`,
235
+ children: Xe.map((e) => /* @__PURE__ */ l("button", {
236
+ type: "button",
237
+ onClick: () => C(e.id),
238
+ className: `whitespace-nowrap border-b-2 py-2 px-1 text-sm font-medium ${S === e.id ? "border-primary text-primary" : "border-transparent text-text-secondary hover:text-text-primary hover:border-border-subtle"}`,
239
239
  children: e.label
240
240
  }, e.id))
241
241
  })
242
242
  }),
243
- x === "overview" && /* @__PURE__ */ f("div", {
243
+ S === "overview" && /* @__PURE__ */ u("div", {
244
244
  className: "grid grid-cols-1 gap-6 lg:grid-cols-3",
245
- children: [/* @__PURE__ */ f("div", {
245
+ children: [/* @__PURE__ */ u("div", {
246
246
  className: "lg:col-span-2 space-y-6",
247
- children: [/* @__PURE__ */ f("div", {
247
+ children: [/* @__PURE__ */ u("div", {
248
248
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
249
249
  children: [
250
- /* @__PURE__ */ d("h3", {
250
+ /* @__PURE__ */ l("h3", {
251
251
  className: "mb-4 text-sm font-medium text-text-primary",
252
- children: v("healthybowl.livestock.animalDetails.basicInfo.title", "Basic Information")
252
+ children: y("healthybowl.livestock.animalDetails.basicInfo.title", "Basic Information")
253
253
  }),
254
- /* @__PURE__ */ f("div", {
254
+ /* @__PURE__ */ u("div", {
255
255
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
256
256
  children: [
257
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
257
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
258
258
  className: "text-xs text-text-secondary",
259
- children: v("healthybowl.livestock.animalDetails.fields.type", "Type")
260
- }), /* @__PURE__ */ f("p", {
259
+ children: y("healthybowl.livestock.animalDetails.fields.type", "Type")
260
+ }), /* @__PURE__ */ u("p", {
261
261
  className: "mt-1 flex items-center gap-2 text-sm font-medium capitalize text-text-primary",
262
- children: [/* @__PURE__ */ d("span", {
262
+ children: [/* @__PURE__ */ l("span", {
263
263
  className: "text-xl",
264
- children: Se(E.type)
265
- }), E.type]
264
+ children: we(O.type)
265
+ }), O.type]
266
266
  })] }),
267
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
267
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
268
268
  className: "text-xs text-text-secondary",
269
- children: v("healthybowl.livestock.animalDetails.fields.breed", "Breed")
270
- }), /* @__PURE__ */ d("p", {
269
+ children: y("healthybowl.livestock.animalDetails.fields.breed", "Breed")
270
+ }), /* @__PURE__ */ l("p", {
271
271
  className: "mt-1 text-sm font-medium text-text-primary",
272
- children: E.breed
272
+ children: O.breed
273
273
  })] }),
274
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
274
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
275
275
  className: "text-xs text-text-secondary",
276
- children: v("healthybowl.livestock.animalDetails.fields.gender", "Gender")
277
- }), /* @__PURE__ */ d("p", {
276
+ children: y("healthybowl.livestock.animalDetails.fields.gender", "Gender")
277
+ }), /* @__PURE__ */ l("p", {
278
278
  className: "mt-1 text-sm font-medium capitalize text-text-primary",
279
- children: E.gender
279
+ children: O.gender
280
280
  })] }),
281
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
281
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
282
282
  className: "text-xs text-text-secondary",
283
- children: v("healthybowl.livestock.animalDetails.fields.dateOfBirth", "Date of Birth")
284
- }), /* @__PURE__ */ d("p", {
283
+ children: y("healthybowl.livestock.animalDetails.fields.dateOfBirth", "Date of Birth")
284
+ }), /* @__PURE__ */ l("p", {
285
285
  className: "mt-1 text-sm font-medium text-text-primary",
286
- children: e(E.dateOfBirth)
286
+ children: e(O.dateOfBirth)
287
287
  })] }),
288
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
288
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
289
289
  className: "text-xs text-text-secondary",
290
- children: v("healthybowl.livestock.animalDetails.fields.currentWeight", "Current Weight")
291
- }), /* @__PURE__ */ f("p", {
290
+ children: y("healthybowl.livestock.animalDetails.fields.currentWeight", "Current Weight")
291
+ }), /* @__PURE__ */ u("p", {
292
292
  className: "mt-1 text-sm font-medium text-text-primary",
293
- children: [t(E.weight ?? 0), " kg"]
293
+ children: [t(O.weight ?? 0), " kg"]
294
294
  })] }),
295
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
295
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
296
296
  className: "text-xs text-text-secondary",
297
- children: v("healthybowl.livestock.animalDetails.fields.lastCheckup", "Last Checkup")
298
- }), /* @__PURE__ */ d("p", {
297
+ children: y("healthybowl.livestock.animalDetails.fields.lastCheckup", "Last Checkup")
298
+ }), /* @__PURE__ */ l("p", {
299
299
  className: "mt-1 text-sm font-medium text-text-primary",
300
- children: e(E.lastCheckup)
300
+ children: e(O.lastCheckup)
301
301
  })] })
302
302
  ]
303
303
  }),
304
- (E.imageIds ?? []).length > 0 && /* @__PURE__ */ f("div", {
304
+ (O.imageIds ?? []).length > 0 && /* @__PURE__ */ u("div", {
305
305
  className: "mt-4",
306
- children: [/* @__PURE__ */ d("p", {
306
+ children: [/* @__PURE__ */ l("p", {
307
307
  className: "mb-2 text-xs text-text-secondary",
308
- children: v("healthybowl.livestock.animalDetails.fields.photos", "Photos")
309
- }), /* @__PURE__ */ d(a, {
308
+ children: y("healthybowl.livestock.animalDetails.fields.photos", "Photos")
309
+ }), /* @__PURE__ */ l(se, {
310
310
  entity: "Animal",
311
- imageIds: E.imageIds ?? [],
311
+ imageIds: O.imageIds ?? [],
312
312
  onChange: () => {},
313
313
  readOnly: !0
314
314
  })]
315
315
  })
316
316
  ]
317
- }), /* @__PURE__ */ f("div", {
317
+ }), /* @__PURE__ */ u("div", {
318
318
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
319
- children: [/* @__PURE__ */ f("div", {
319
+ children: [/* @__PURE__ */ u("div", {
320
320
  className: "mb-4 flex items-center justify-between",
321
- children: [/* @__PURE__ */ d("h3", {
321
+ children: [/* @__PURE__ */ l("h3", {
322
322
  className: "text-sm font-medium text-text-primary",
323
- children: v("healthybowl.livestock.animalDetails.recentActivity.title", "Recent Activity")
324
- }), /* @__PURE__ */ d("button", {
325
- onClick: () => je("health"),
326
- className: "text-xs text-primary hover:underline",
327
- children: v("healthybowl.livestock.animalDetails.recentActivity.viewAll", "View All")
323
+ children: y("healthybowl.livestock.animalDetails.recentActivity.title", "Recent Activity")
324
+ }), /* @__PURE__ */ l(d, {
325
+ variant: "link",
326
+ size: "sm",
327
+ onClick: () => C("health"),
328
+ className: "text-xs",
329
+ children: y("healthybowl.livestock.animalDetails.recentActivity.viewAll", "View All")
328
330
  })]
329
- }), J.length > 0 ? /* @__PURE__ */ d("div", {
331
+ }), J.length > 0 ? /* @__PURE__ */ l("div", {
330
332
  className: "flex flex-col gap-3",
331
- children: J.map((t) => /* @__PURE__ */ f("div", {
333
+ children: J.map((t) => /* @__PURE__ */ u("div", {
332
334
  className: "flex items-center justify-between rounded-md border border-border-subtle p-3",
333
- children: [/* @__PURE__ */ f("div", {
335
+ children: [/* @__PURE__ */ u("div", {
334
336
  className: "flex items-center gap-3",
335
- children: [/* @__PURE__ */ d("div", {
337
+ children: [/* @__PURE__ */ l("div", {
336
338
  className: "rounded-full bg-bg-sunken p-2",
337
- children: /* @__PURE__ */ d(c, { className: "h-4 w-4 text-text-secondary" })
338
- }), /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ f("p", {
339
+ children: /* @__PURE__ */ l(he, { className: "h-4 w-4 text-text-secondary" })
340
+ }), /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ u("p", {
339
341
  className: "text-sm font-medium text-text-primary",
340
342
  children: [
341
343
  t.type,
342
344
  " - ",
343
345
  t.diagnosis
344
346
  ]
345
- }), /* @__PURE__ */ f("p", {
347
+ }), /* @__PURE__ */ u("p", {
346
348
  className: "text-xs text-text-secondary",
347
349
  children: [
348
350
  e(t.date),
@@ -350,151 +352,153 @@ var p = (e) => {
350
352
  t.veterinarian
351
353
  ]
352
354
  })] })]
353
- }), /* @__PURE__ */ d(fe, { className: "h-4 w-4 text-text-secondary" })]
355
+ }), /* @__PURE__ */ l(pe, { className: "h-4 w-4 text-text-secondary" })]
354
356
  }, t.id))
355
- }) : /* @__PURE__ */ d("p", {
357
+ }) : /* @__PURE__ */ l("p", {
356
358
  className: "py-4 text-center text-sm text-text-secondary",
357
- children: v("healthybowl.livestock.animalDetails.recentActivity.empty", "No recent activity")
359
+ children: y("healthybowl.livestock.animalDetails.recentActivity.empty", "No recent activity")
358
360
  })]
359
361
  })]
360
- }), /* @__PURE__ */ f("div", {
362
+ }), /* @__PURE__ */ u("div", {
361
363
  className: "space-y-6",
362
- children: [/* @__PURE__ */ f("div", {
364
+ children: [/* @__PURE__ */ u("div", {
363
365
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
364
- children: [/* @__PURE__ */ d("h3", {
366
+ children: [/* @__PURE__ */ l("h3", {
365
367
  className: "mb-4 text-sm font-medium text-text-primary",
366
- children: v("healthybowl.livestock.animalDetails.quickStats.title", "Quick Stats")
367
- }), /* @__PURE__ */ f("div", {
368
+ children: y("healthybowl.livestock.animalDetails.quickStats.title", "Quick Stats")
369
+ }), /* @__PURE__ */ u("div", {
368
370
  className: "space-y-4",
369
371
  children: [
370
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
372
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
371
373
  className: "text-xs text-text-secondary",
372
- children: v("healthybowl.livestock.animalDetails.quickStats.avgDailyMilk", "Average Daily Milk")
373
- }), /* @__PURE__ */ f("p", {
374
+ children: y("healthybowl.livestock.animalDetails.quickStats.avgDailyMilk", "Average Daily Milk")
375
+ }), /* @__PURE__ */ u("p", {
374
376
  className: "text-xl font-bold text-text-primary",
375
- children: [Ve.toFixed(1), " L"]
377
+ children: [qe.toFixed(1), " L"]
376
378
  })] }),
377
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
379
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
378
380
  className: "text-xs text-text-secondary",
379
- children: v("healthybowl.livestock.animalDetails.quickStats.totalVaccinations", "Total Vaccinations")
380
- }), /* @__PURE__ */ d("p", {
381
+ children: y("healthybowl.livestock.animalDetails.quickStats.totalVaccinations", "Total Vaccinations")
382
+ }), /* @__PURE__ */ l("p", {
381
383
  className: "text-xl font-bold text-text-primary",
382
384
  children: Y.length
383
385
  })] }),
384
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
386
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
385
387
  className: "text-xs text-text-secondary",
386
- children: v("healthybowl.livestock.animalDetails.quickStats.breedingRecords", "Breeding Records")
387
- }), /* @__PURE__ */ d("p", {
388
+ children: y("healthybowl.livestock.animalDetails.quickStats.breedingRecords", "Breeding Records")
389
+ }), /* @__PURE__ */ l("p", {
388
390
  className: "text-xl font-bold text-text-primary",
389
391
  children: X.length
390
392
  })] }),
391
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
393
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
392
394
  className: "text-xs text-text-secondary",
393
- children: v("healthybowl.livestock.animalDetails.quickStats.healthScore", "Health Score")
394
- }), /* @__PURE__ */ f("div", {
395
+ children: y("healthybowl.livestock.animalDetails.quickStats.healthScore", "Health Score")
396
+ }), /* @__PURE__ */ u("div", {
395
397
  className: "mt-1",
396
- children: [/* @__PURE__ */ d("div", {
398
+ children: [/* @__PURE__ */ l("div", {
397
399
  className: "h-2 w-full rounded-full bg-bg-sunken",
398
- children: /* @__PURE__ */ d("div", {
400
+ children: /* @__PURE__ */ l("div", {
399
401
  className: "h-2 rounded-full bg-action-primary-bg",
400
- style: { width: `${He}%` }
402
+ style: { width: `${Je}%` }
401
403
  })
402
- }), /* @__PURE__ */ f("p", {
404
+ }), /* @__PURE__ */ u("p", {
403
405
  className: "mt-1 text-xs text-text-secondary",
404
- children: [He, "/100"]
406
+ children: [Je, "/100"]
405
407
  })]
406
408
  })] })
407
409
  ]
408
410
  })]
409
- }), /* @__PURE__ */ f("div", {
411
+ }), /* @__PURE__ */ u("div", {
410
412
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
411
- children: [/* @__PURE__ */ d("h3", {
413
+ children: [/* @__PURE__ */ l("h3", {
412
414
  className: "mb-4 text-sm font-medium text-text-primary",
413
- children: v("healthybowl.livestock.animalDetails.quickActions.title", "Quick Actions")
414
- }), /* @__PURE__ */ d("div", {
415
+ children: y("healthybowl.livestock.animalDetails.quickActions.title", "Quick Actions")
416
+ }), /* @__PURE__ */ l("div", {
415
417
  className: "flex flex-col gap-2",
416
418
  children: [
417
419
  {
418
420
  id: "recordHealthCheck",
419
- label: v("healthybowl.livestock.animalDetails.quickActions.recordHealthCheck", "Record Health Check"),
420
- icon: c,
421
+ label: y("healthybowl.livestock.animalDetails.quickActions.recordHealthCheck", "Record Health Check"),
422
+ icon: he,
421
423
  path: "livestock/health"
422
424
  },
423
425
  {
424
426
  id: "addVaccination",
425
- label: v("healthybowl.livestock.animalDetails.quickActions.addVaccination", "Add Vaccination"),
426
- icon: he,
427
+ label: y("healthybowl.livestock.animalDetails.quickActions.addVaccination", "Add Vaccination"),
428
+ icon: _e,
427
429
  path: "livestock/vaccinations"
428
430
  },
429
431
  {
430
432
  id: "updateWeight",
431
- label: v("healthybowl.livestock.animalDetails.quickActions.updateWeight", "Update Weight"),
432
- icon: ve,
433
- path: `livestock/animals/${E.id}`
433
+ label: y("healthybowl.livestock.animalDetails.quickActions.updateWeight", "Update Weight"),
434
+ icon: be,
435
+ path: `livestock/animals/${O.id}`
434
436
  },
435
437
  {
436
438
  id: "recordProduction",
437
- label: v("healthybowl.livestock.animalDetails.quickActions.recordProduction", "Record Production"),
438
- icon: l,
439
+ label: y("healthybowl.livestock.animalDetails.quickActions.recordProduction", "Record Production"),
440
+ icon: s,
439
441
  path: "livestock/production"
440
442
  }
441
- ].map((e) => /* @__PURE__ */ f("button", {
442
- onClick: () => y(b(e.path)),
443
- className: "flex items-center gap-2 rounded-md border border-border-subtle px-3 py-2 text-sm text-text-primary hover:bg-bg-sunken/50",
444
- children: [/* @__PURE__ */ d(e.icon, { className: "h-4 w-4 text-text-secondary" }), e.label]
443
+ ].map((e) => /* @__PURE__ */ u(d, {
444
+ variant: "outline",
445
+ onClick: () => b(x(e.path)),
446
+ className: "justify-start",
447
+ children: [/* @__PURE__ */ l(e.icon, { className: "h-4 w-4 text-text-secondary" }), e.label]
445
448
  }, e.id))
446
449
  })]
447
450
  })]
448
451
  })]
449
452
  }),
450
- x === "health" && /* @__PURE__ */ f("div", {
453
+ S === "health" && /* @__PURE__ */ u("div", {
451
454
  className: "grid grid-cols-1 gap-6 lg:grid-cols-3",
452
- children: [/* @__PURE__ */ f("div", {
455
+ children: [/* @__PURE__ */ u("div", {
453
456
  className: "lg:col-span-2 space-y-6",
454
- children: [/* @__PURE__ */ f("div", {
457
+ children: [/* @__PURE__ */ u("div", {
455
458
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
456
- children: [/* @__PURE__ */ f("div", {
459
+ children: [/* @__PURE__ */ u("div", {
457
460
  className: "mb-4 flex items-center justify-between",
458
- children: [/* @__PURE__ */ d("h3", {
461
+ children: [/* @__PURE__ */ l("h3", {
459
462
  className: "text-sm font-medium text-text-primary",
460
- children: v("healthybowl.livestock.animalDetails.healthRecords.title", "Health Records")
461
- }), /* @__PURE__ */ f("button", {
462
- onClick: () => y(b("livestock/health")),
463
- className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-3 py-1.5 text-xs font-medium text-action-primary-text hover:bg-action-primary-bg/90",
463
+ children: y("healthybowl.livestock.animalDetails.healthRecords.title", "Health Records")
464
+ }), /* @__PURE__ */ u(d, {
465
+ size: "sm",
466
+ onClick: () => b(x("livestock/health")),
467
+ className: "text-xs",
464
468
  children: [
465
- /* @__PURE__ */ d(u, { className: "h-3.5 w-3.5" }),
469
+ /* @__PURE__ */ l(c, { className: "h-3.5 w-3.5" }),
466
470
  " ",
467
- v("healthybowl.livestock.animalDetails.healthRecords.add", "Add Record")
471
+ y("healthybowl.livestock.animalDetails.healthRecords.add", "Add Record")
468
472
  ]
469
473
  })]
470
- }), J.length > 0 ? /* @__PURE__ */ d("div", {
474
+ }), J.length > 0 ? /* @__PURE__ */ l("div", {
471
475
  className: "flex flex-col gap-3",
472
- children: J.map((t) => /* @__PURE__ */ d("div", {
476
+ children: J.map((t) => /* @__PURE__ */ l("div", {
473
477
  className: "rounded-lg border border-border-subtle p-4",
474
- children: /* @__PURE__ */ d("div", {
478
+ children: /* @__PURE__ */ l("div", {
475
479
  className: "flex items-start justify-between",
476
- children: /* @__PURE__ */ f("div", {
480
+ children: /* @__PURE__ */ u("div", {
477
481
  className: "space-y-1.5",
478
482
  children: [
479
- /* @__PURE__ */ f("div", {
483
+ /* @__PURE__ */ u("div", {
480
484
  className: "flex items-center gap-2",
481
- children: [/* @__PURE__ */ d(i, {
485
+ children: [/* @__PURE__ */ l(i, {
482
486
  label: t.type,
483
487
  variant: "info"
484
- }), /* @__PURE__ */ d(i, {
488
+ }), /* @__PURE__ */ l(i, {
485
489
  label: t.status,
486
490
  variant: t.status === "resolved" ? "success" : t.status === "active" ? "warning" : "info"
487
491
  })]
488
492
  }),
489
- /* @__PURE__ */ d("p", {
493
+ /* @__PURE__ */ l("p", {
490
494
  className: "text-sm font-medium text-text-primary",
491
495
  children: t.diagnosis
492
496
  }),
493
- t.treatment && /* @__PURE__ */ d("p", {
497
+ t.treatment && /* @__PURE__ */ l("p", {
494
498
  className: "text-xs text-text-secondary",
495
- children: v("healthybowl.livestock.animalDetails.healthRecords.treatment", "Treatment: {{treatment}}", { treatment: t.treatment })
499
+ children: y("healthybowl.livestock.animalDetails.healthRecords.treatment", "Treatment: {{treatment}}", { treatment: t.treatment })
496
500
  }),
497
- /* @__PURE__ */ f("p", {
501
+ /* @__PURE__ */ u("p", {
498
502
  className: "text-xs text-text-secondary",
499
503
  children: [
500
504
  e(t.date),
@@ -506,250 +510,254 @@ var p = (e) => {
506
510
  })
507
511
  })
508
512
  }, t.id))
509
- }) : /* @__PURE__ */ d("p", {
513
+ }) : /* @__PURE__ */ l("p", {
510
514
  className: "py-4 text-center text-sm text-text-secondary",
511
- children: v("healthybowl.livestock.animalDetails.healthRecords.empty", "No health records")
515
+ children: y("healthybowl.livestock.animalDetails.healthRecords.empty", "No health records")
512
516
  })]
513
- }), /* @__PURE__ */ f("div", {
517
+ }), /* @__PURE__ */ u("div", {
514
518
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
515
- children: [/* @__PURE__ */ f("div", {
519
+ children: [/* @__PURE__ */ u("div", {
516
520
  className: "mb-4 flex items-center justify-between",
517
- children: [/* @__PURE__ */ d("h3", {
521
+ children: [/* @__PURE__ */ l("h3", {
518
522
  className: "text-sm font-medium text-text-primary",
519
- children: v("healthybowl.livestock.animalDetails.vaccinations.title", "Vaccination History")
520
- }), /* @__PURE__ */ f("button", {
521
- onClick: () => y(b("livestock/vaccinations")),
522
- className: "inline-flex items-center gap-2 rounded-md border border-border-subtle px-3 py-1.5 text-xs text-text-primary hover:bg-bg-sunken/50",
523
+ children: y("healthybowl.livestock.animalDetails.vaccinations.title", "Vaccination History")
524
+ }), /* @__PURE__ */ u(d, {
525
+ variant: "outline",
526
+ size: "sm",
527
+ onClick: () => b(x("livestock/vaccinations")),
528
+ className: "text-xs",
523
529
  children: [
524
- /* @__PURE__ */ d(de, { className: "h-3.5 w-3.5" }),
530
+ /* @__PURE__ */ l(fe, { className: "h-3.5 w-3.5" }),
525
531
  " ",
526
- v("healthybowl.livestock.animalDetails.vaccinations.schedule", "Schedule")
532
+ y("healthybowl.livestock.animalDetails.vaccinations.schedule", "Schedule")
527
533
  ]
528
534
  })]
529
- }), Y.length > 0 ? /* @__PURE__ */ d("div", {
535
+ }), Y.length > 0 ? /* @__PURE__ */ l("div", {
530
536
  className: "flex flex-col gap-3",
531
- children: Y.map((t) => /* @__PURE__ */ f("div", {
537
+ children: Y.map((t) => /* @__PURE__ */ u("div", {
532
538
  className: "flex items-center justify-between border-b border-border-subtle pb-3 last:border-0 last:pb-0",
533
- children: [/* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
539
+ children: [/* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
534
540
  className: "text-sm font-medium text-text-primary",
535
541
  children: t.vaccineName
536
- }), /* @__PURE__ */ d("p", {
542
+ }), /* @__PURE__ */ l("p", {
537
543
  className: "text-xs text-text-secondary",
538
- children: v("healthybowl.livestock.animalDetails.vaccinations.givenOn", "Given on {{date}}", { date: e(t.administrationDate) })
539
- })] }), /* @__PURE__ */ f("div", {
544
+ children: y("healthybowl.livestock.animalDetails.vaccinations.givenOn", "Given on {{date}}", { date: e(t.administrationDate) })
545
+ })] }), /* @__PURE__ */ u("div", {
540
546
  className: "text-right",
541
- children: [/* @__PURE__ */ d("p", {
547
+ children: [/* @__PURE__ */ l("p", {
542
548
  className: "text-xs text-text-secondary",
543
- children: v("healthybowl.livestock.animalDetails.vaccinations.nextDue", "Next due")
544
- }), /* @__PURE__ */ d("p", {
549
+ children: y("healthybowl.livestock.animalDetails.vaccinations.nextDue", "Next due")
550
+ }), /* @__PURE__ */ l("p", {
545
551
  className: "text-sm font-medium text-text-primary",
546
552
  children: e(t.nextDueDate)
547
553
  })]
548
554
  })]
549
555
  }, t.id))
550
- }) : /* @__PURE__ */ d("p", {
556
+ }) : /* @__PURE__ */ l("p", {
551
557
  className: "py-4 text-center text-sm text-text-secondary",
552
- children: v("healthybowl.livestock.animalDetails.vaccinations.empty", "No vaccination records")
558
+ children: y("healthybowl.livestock.animalDetails.vaccinations.empty", "No vaccination records")
553
559
  })]
554
560
  })]
555
- }), /* @__PURE__ */ d("div", {
561
+ }), /* @__PURE__ */ l("div", {
556
562
  className: "space-y-6",
557
- children: /* @__PURE__ */ f("div", {
563
+ children: /* @__PURE__ */ u("div", {
558
564
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
559
- children: [/* @__PURE__ */ d("h3", {
565
+ children: [/* @__PURE__ */ l("h3", {
560
566
  className: "mb-4 text-sm font-medium text-text-primary",
561
- children: v("healthybowl.livestock.animalDetails.healthSummary.title", "Health Summary")
562
- }), /* @__PURE__ */ f("div", {
567
+ children: y("healthybowl.livestock.animalDetails.healthSummary.title", "Health Summary")
568
+ }), /* @__PURE__ */ u("div", {
563
569
  className: "space-y-4",
564
570
  children: [
565
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
571
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
566
572
  className: "text-xs text-text-secondary",
567
- children: v("healthybowl.livestock.animalDetails.healthSummary.currentStatus", "Current Status")
568
- }), /* @__PURE__ */ d("div", {
573
+ children: y("healthybowl.livestock.animalDetails.healthSummary.currentStatus", "Current Status")
574
+ }), /* @__PURE__ */ l("div", {
569
575
  className: "mt-1",
570
- children: /* @__PURE__ */ d(i, {
571
- label: (E.healthStatus ?? "").replace("_", " "),
572
- variant: p(E.healthStatus),
576
+ children: /* @__PURE__ */ l(i, {
577
+ label: (O.healthStatus ?? "").replace("_", " "),
578
+ variant: _(O.healthStatus),
573
579
  dot: !0
574
580
  })
575
581
  })] }),
576
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
582
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
577
583
  className: "text-xs text-text-secondary",
578
- children: v("healthybowl.livestock.animalDetails.fields.lastCheckup", "Last Checkup")
579
- }), /* @__PURE__ */ d("p", {
584
+ children: y("healthybowl.livestock.animalDetails.fields.lastCheckup", "Last Checkup")
585
+ }), /* @__PURE__ */ l("p", {
580
586
  className: "text-sm font-medium text-text-primary",
581
- children: e(E.lastCheckup)
587
+ children: e(O.lastCheckup)
582
588
  })] }),
583
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
589
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
584
590
  className: "text-xs text-text-secondary",
585
- children: v("healthybowl.livestock.animalDetails.healthSummary.nextVaccination", "Next Vaccination")
586
- }), /* @__PURE__ */ d("p", {
591
+ children: y("healthybowl.livestock.animalDetails.healthSummary.nextVaccination", "Next Vaccination")
592
+ }), /* @__PURE__ */ l("p", {
587
593
  className: "text-sm font-medium text-text-primary",
588
- children: Y.find((e) => e.status === "scheduled") ? `${Y.find((e) => e.status === "scheduled").vaccineName} - ${e(Y.find((e) => e.status === "scheduled").nextDueDate)}` : v("healthybowl.livestock.animalDetails.healthSummary.noneScheduled", "None scheduled")
594
+ children: Y.find((e) => e.status === "scheduled") ? `${Y.find((e) => e.status === "scheduled").vaccineName} - ${e(Y.find((e) => e.status === "scheduled").nextDueDate)}` : y("healthybowl.livestock.animalDetails.healthSummary.noneScheduled", "None scheduled")
589
595
  })] }),
590
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
596
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
591
597
  className: "text-xs text-text-secondary",
592
- children: v("healthybowl.livestock.animalDetails.quickStats.totalVaccinations", "Total Vaccinations")
593
- }), /* @__PURE__ */ d("p", {
598
+ children: y("healthybowl.livestock.animalDetails.quickStats.totalVaccinations", "Total Vaccinations")
599
+ }), /* @__PURE__ */ l("p", {
594
600
  className: "text-xl font-bold text-text-primary",
595
- children: E.vaccinations ?? 0
601
+ children: O.vaccinations ?? 0
596
602
  })] })
597
603
  ]
598
604
  })]
599
605
  })
600
606
  })]
601
607
  }),
602
- x === "breeding" && /* @__PURE__ */ d("div", {
608
+ S === "breeding" && /* @__PURE__ */ l("div", {
603
609
  className: "space-y-6",
604
- children: /* @__PURE__ */ f("div", {
610
+ children: /* @__PURE__ */ u("div", {
605
611
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
606
- children: [/* @__PURE__ */ f("div", {
612
+ children: [/* @__PURE__ */ u("div", {
607
613
  className: "mb-4 flex items-center justify-between",
608
- children: [/* @__PURE__ */ d("h3", {
614
+ children: [/* @__PURE__ */ l("h3", {
609
615
  className: "text-sm font-medium text-text-primary",
610
- children: v("healthybowl.livestock.animalDetails.breeding.title", "Breeding History")
611
- }), /* @__PURE__ */ f("button", {
612
- onClick: () => y(b("livestock/breeding")),
613
- className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-3 py-1.5 text-xs font-medium text-action-primary-text hover:bg-action-primary-bg/90",
616
+ children: y("healthybowl.livestock.animalDetails.breeding.title", "Breeding History")
617
+ }), /* @__PURE__ */ u(d, {
618
+ size: "sm",
619
+ onClick: () => b(x("livestock/breeding")),
620
+ className: "text-xs",
614
621
  children: [
615
- /* @__PURE__ */ d(u, { className: "h-3.5 w-3.5" }),
622
+ /* @__PURE__ */ l(c, { className: "h-3.5 w-3.5" }),
616
623
  " ",
617
- v("healthybowl.livestock.animalDetails.healthRecords.add", "Add Record")
624
+ y("healthybowl.livestock.animalDetails.healthRecords.add", "Add Record")
618
625
  ]
619
626
  })]
620
- }), X.length > 0 ? /* @__PURE__ */ d("div", {
627
+ }), X.length > 0 ? /* @__PURE__ */ l("div", {
621
628
  className: "flex flex-col gap-3",
622
- children: X.map((t) => /* @__PURE__ */ d("div", {
629
+ children: X.map((t) => /* @__PURE__ */ l("div", {
623
630
  className: "rounded-lg border border-border-subtle p-4",
624
- children: /* @__PURE__ */ f("div", {
631
+ children: /* @__PURE__ */ u("div", {
625
632
  className: "grid grid-cols-1 gap-4 md:grid-cols-4",
626
633
  children: [
627
- /* @__PURE__ */ f("div", { children: [
628
- /* @__PURE__ */ d("p", {
634
+ /* @__PURE__ */ u("div", { children: [
635
+ /* @__PURE__ */ l("p", {
629
636
  className: "text-xs text-text-secondary",
630
- children: v("healthybowl.livestock.animalDetails.breeding.matingDate", "Mating Date")
637
+ children: y("healthybowl.livestock.animalDetails.breeding.matingDate", "Mating Date")
631
638
  }),
632
- /* @__PURE__ */ d("p", {
639
+ /* @__PURE__ */ l("p", {
633
640
  className: "text-sm font-medium text-text-primary",
634
641
  children: e(t.matingDate)
635
642
  }),
636
- /* @__PURE__ */ d("p", {
643
+ /* @__PURE__ */ l("p", {
637
644
  className: "text-xs capitalize text-text-secondary",
638
645
  children: t.matingType
639
646
  })
640
647
  ] }),
641
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
648
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
642
649
  className: "text-xs text-text-secondary",
643
- children: v("healthybowl.livestock.animalDetails.breeding.female", "Female")
644
- }), /* @__PURE__ */ d("p", {
650
+ children: y("healthybowl.livestock.animalDetails.breeding.female", "Female")
651
+ }), /* @__PURE__ */ l("p", {
645
652
  className: "text-sm font-medium text-text-primary",
646
653
  children: t.femaleName
647
654
  })] }),
648
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("p", {
655
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("p", {
649
656
  className: "text-xs text-text-secondary",
650
- children: v("healthybowl.livestock.animalDetails.breeding.male", "Male")
651
- }), /* @__PURE__ */ d("p", {
657
+ children: y("healthybowl.livestock.animalDetails.breeding.male", "Male")
658
+ }), /* @__PURE__ */ l("p", {
652
659
  className: "text-sm font-medium text-text-primary",
653
660
  children: t.maleName
654
661
  })] }),
655
- /* @__PURE__ */ f("div", { children: [
656
- /* @__PURE__ */ d("p", {
662
+ /* @__PURE__ */ u("div", { children: [
663
+ /* @__PURE__ */ l("p", {
657
664
  className: "text-xs text-text-secondary",
658
- children: v("healthybowl.livestock.animalDetails.breeding.status", "Status")
665
+ children: y("healthybowl.livestock.animalDetails.breeding.status", "Status")
659
666
  }),
660
- /* @__PURE__ */ d(i, {
667
+ /* @__PURE__ */ l(i, {
661
668
  label: t.status,
662
669
  variant: t.status === "confirmed" || t.status === "delivered" ? "success" : t.status === "failed" ? "error" : "info"
663
670
  }),
664
- t.expectedDeliveryDate && /* @__PURE__ */ d("p", {
671
+ t.expectedDeliveryDate && /* @__PURE__ */ l("p", {
665
672
  className: "mt-1 text-xs text-text-secondary",
666
- children: v("healthybowl.livestock.animalDetails.breeding.expected", "Expected: {{date}}", { date: e(t.expectedDeliveryDate) })
673
+ children: y("healthybowl.livestock.animalDetails.breeding.expected", "Expected: {{date}}", { date: e(t.expectedDeliveryDate) })
667
674
  })
668
675
  ] })
669
676
  ]
670
677
  })
671
678
  }, t.id))
672
- }) : /* @__PURE__ */ d("p", {
679
+ }) : /* @__PURE__ */ l("p", {
673
680
  className: "py-8 text-center text-sm text-text-secondary",
674
- children: v("healthybowl.livestock.animalDetails.breeding.empty", "No breeding records for this animal")
681
+ children: y("healthybowl.livestock.animalDetails.breeding.empty", "No breeding records for this animal")
675
682
  })]
676
683
  })
677
684
  }),
678
- x === "production" && /* @__PURE__ */ f("div", {
685
+ S === "production" && /* @__PURE__ */ u("div", {
679
686
  className: "space-y-6",
680
- children: [/* @__PURE__ */ f("div", {
687
+ children: [/* @__PURE__ */ u("div", {
681
688
  className: "grid grid-cols-1 gap-4 sm:grid-cols-3",
682
689
  children: [
683
- /* @__PURE__ */ d(r, {
684
- label: v("healthybowl.livestock.animalDetails.production.stats.latest", "Latest Production"),
690
+ /* @__PURE__ */ l(r, {
691
+ label: y("healthybowl.livestock.animalDetails.production.stats.latest", "Latest Production"),
685
692
  value: $ ? $.quantity : 0,
686
693
  unit: $ ? $.unit : "",
687
- icon: /* @__PURE__ */ d(l, { className: "h-4 w-4" })
694
+ icon: /* @__PURE__ */ l(s, { className: "h-4 w-4" })
688
695
  }),
689
- /* @__PURE__ */ d(r, {
690
- label: v("healthybowl.livestock.animalDetails.production.stats.avg", "Avg Production"),
696
+ /* @__PURE__ */ l(r, {
697
+ label: y("healthybowl.livestock.animalDetails.production.stats.avg", "Avg Production"),
691
698
  value: Z.length > 0 ? parseFloat((Z.reduce((e, t) => e + t.quantity, 0) / Z.length).toFixed(1)) : 0,
692
699
  unit: Z.length > 0 ? Z[0].unit : "",
693
- icon: /* @__PURE__ */ d(_e, { className: "h-4 w-4" })
700
+ icon: /* @__PURE__ */ l(ye, { className: "h-4 w-4" })
694
701
  }),
695
- /* @__PURE__ */ d(r, {
696
- label: v("healthybowl.livestock.animalDetails.production.stats.totalRecords", "Total Records"),
702
+ /* @__PURE__ */ l(r, {
703
+ label: y("healthybowl.livestock.animalDetails.production.stats.totalRecords", "Total Records"),
697
704
  value: Z.length,
698
- icon: /* @__PURE__ */ d(me, { className: "h-4 w-4" })
705
+ icon: /* @__PURE__ */ l(ge, { className: "h-4 w-4" })
699
706
  })
700
707
  ]
701
- }), /* @__PURE__ */ f("div", {
708
+ }), /* @__PURE__ */ u("div", {
702
709
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
703
- children: [/* @__PURE__ */ f("div", {
710
+ children: [/* @__PURE__ */ u("div", {
704
711
  className: "mb-4 flex items-center justify-between",
705
- children: [/* @__PURE__ */ d("h3", {
712
+ children: [/* @__PURE__ */ l("h3", {
706
713
  className: "text-sm font-medium text-text-primary",
707
- children: v("healthybowl.livestock.animalDetails.production.recent.title", "Recent Production")
708
- }), /* @__PURE__ */ f("button", {
709
- onClick: () => y(b("livestock/production")),
710
- className: "inline-flex items-center gap-2 rounded-md bg-action-primary-bg px-3 py-1.5 text-xs font-medium text-action-primary-text hover:bg-action-primary-bg/90",
714
+ children: y("healthybowl.livestock.animalDetails.production.recent.title", "Recent Production")
715
+ }), /* @__PURE__ */ u(d, {
716
+ size: "sm",
717
+ onClick: () => b(x("livestock/production")),
718
+ className: "text-xs",
711
719
  children: [
712
- /* @__PURE__ */ d(u, { className: "h-3.5 w-3.5" }),
720
+ /* @__PURE__ */ l(c, { className: "h-3.5 w-3.5" }),
713
721
  " ",
714
- v("healthybowl.livestock.animalDetails.production.recordProduction", "Record Production")
722
+ y("healthybowl.livestock.animalDetails.production.recordProduction", "Record Production")
715
723
  ]
716
724
  })]
717
- }), Z.length > 0 ? /* @__PURE__ */ d("div", {
725
+ }), Z.length > 0 ? /* @__PURE__ */ l("div", {
718
726
  className: "overflow-x-auto",
719
- children: /* @__PURE__ */ f("table", {
727
+ children: /* @__PURE__ */ u("table", {
720
728
  className: "w-full",
721
- children: [/* @__PURE__ */ d("thead", { children: /* @__PURE__ */ f("tr", {
729
+ children: [/* @__PURE__ */ l("thead", { children: /* @__PURE__ */ u("tr", {
722
730
  className: "border-b border-border-subtle",
723
731
  children: [
724
- /* @__PURE__ */ d("th", {
732
+ /* @__PURE__ */ l("th", {
725
733
  className: "py-2 px-3 text-left text-xs font-medium text-text-secondary",
726
- children: v("healthybowl.livestock.animalDetails.production.table.date", "Date")
734
+ children: y("healthybowl.livestock.animalDetails.production.table.date", "Date")
727
735
  }),
728
- /* @__PURE__ */ d("th", {
736
+ /* @__PURE__ */ l("th", {
729
737
  className: "py-2 px-3 text-left text-xs font-medium text-text-secondary",
730
- children: v("healthybowl.livestock.animalDetails.production.table.type", "Type")
738
+ children: y("healthybowl.livestock.animalDetails.production.table.type", "Type")
731
739
  }),
732
- /* @__PURE__ */ d("th", {
740
+ /* @__PURE__ */ l("th", {
733
741
  className: "py-2 px-3 text-left text-xs font-medium text-text-secondary",
734
- children: v("healthybowl.livestock.animalDetails.production.table.quantity", "Quantity")
742
+ children: y("healthybowl.livestock.animalDetails.production.table.quantity", "Quantity")
735
743
  }),
736
- /* @__PURE__ */ d("th", {
744
+ /* @__PURE__ */ l("th", {
737
745
  className: "py-2 px-3 text-left text-xs font-medium text-text-secondary",
738
- children: v("healthybowl.livestock.animalDetails.production.table.quality", "Quality")
746
+ children: y("healthybowl.livestock.animalDetails.production.table.quality", "Quality")
739
747
  })
740
748
  ]
741
- }) }), /* @__PURE__ */ d("tbody", { children: Z.map((t) => /* @__PURE__ */ f("tr", {
749
+ }) }), /* @__PURE__ */ l("tbody", { children: Z.map((t) => /* @__PURE__ */ u("tr", {
742
750
  className: "border-b border-border-subtle last:border-0",
743
751
  children: [
744
- /* @__PURE__ */ d("td", {
752
+ /* @__PURE__ */ l("td", {
745
753
  className: "py-3 px-3 text-sm text-text-primary",
746
754
  children: e(t.date)
747
755
  }),
748
- /* @__PURE__ */ d("td", {
756
+ /* @__PURE__ */ l("td", {
749
757
  className: "py-3 px-3 text-sm capitalize text-text-primary",
750
758
  children: t.type
751
759
  }),
752
- /* @__PURE__ */ f("td", {
760
+ /* @__PURE__ */ u("td", {
753
761
  className: "py-3 px-3 text-sm text-text-primary",
754
762
  children: [
755
763
  t.quantity,
@@ -757,9 +765,9 @@ var p = (e) => {
757
765
  t.unit
758
766
  ]
759
767
  }),
760
- /* @__PURE__ */ d("td", {
768
+ /* @__PURE__ */ l("td", {
761
769
  className: "py-3 px-3",
762
- children: /* @__PURE__ */ d(i, {
770
+ children: /* @__PURE__ */ l(i, {
763
771
  label: (t.quality ?? "").replace("_", " "),
764
772
  variant: t.quality === "premium" ? "success" : t.quality === "standard" ? "info" : "warning"
765
773
  })
@@ -767,38 +775,38 @@ var p = (e) => {
767
775
  ]
768
776
  }, t.id)) })]
769
777
  })
770
- }) : /* @__PURE__ */ d("p", {
778
+ }) : /* @__PURE__ */ l("p", {
771
779
  className: "py-8 text-center text-sm text-text-secondary",
772
- children: v("healthybowl.livestock.animalDetails.production.empty", "No production records for this animal")
780
+ children: y("healthybowl.livestock.animalDetails.production.empty", "No production records for this animal")
773
781
  })]
774
782
  })]
775
783
  }),
776
- x === "timeline" && /* @__PURE__ */ d("div", {
784
+ S === "timeline" && /* @__PURE__ */ l("div", {
777
785
  className: "rounded-lg border border-border-subtle bg-bg-surface p-4 shadow-sm",
778
- children: Ue.length > 0 ? /* @__PURE__ */ f("div", {
786
+ children: Ye.length > 0 ? /* @__PURE__ */ u("div", {
779
787
  className: "relative",
780
- children: [/* @__PURE__ */ d("div", { className: "absolute left-4 top-0 bottom-0 w-px bg-border" }), /* @__PURE__ */ d("div", {
788
+ children: [/* @__PURE__ */ l("div", { className: "absolute left-4 top-0 bottom-0 w-px bg-border" }), /* @__PURE__ */ l("div", {
781
789
  className: "flex flex-col gap-4",
782
- children: Ue.map((t) => /* @__PURE__ */ f("div", {
790
+ children: Ye.map((t) => /* @__PURE__ */ u("div", {
783
791
  className: "relative flex items-start gap-4 pl-10",
784
- children: [/* @__PURE__ */ d("div", { className: `absolute left-2.5 top-1.5 h-3 w-3 rounded-full border-2 border-background ${t.category === "Health" ? "bg-status-error-bg" : t.category === "Vaccination" ? "bg-info" : "bg-success"}` }), /* @__PURE__ */ f("div", {
792
+ children: [/* @__PURE__ */ l("div", { className: `absolute left-2.5 top-1.5 h-3 w-3 rounded-full border-2 border-background ${t.category === "Health" ? "bg-status-error-bg" : t.category === "Vaccination" ? "bg-info" : "bg-success"}` }), /* @__PURE__ */ u("div", {
785
793
  className: "flex-1 rounded-md border border-border-subtle p-3",
786
794
  children: [
787
- /* @__PURE__ */ f("div", {
795
+ /* @__PURE__ */ u("div", {
788
796
  className: "flex items-center gap-2",
789
- children: [/* @__PURE__ */ d(i, {
797
+ children: [/* @__PURE__ */ l(i, {
790
798
  label: t.categoryLabel,
791
799
  variant: t.category === "Health" ? "warning" : t.category === "Vaccination" ? "info" : "success"
792
- }), /* @__PURE__ */ d("span", {
800
+ }), /* @__PURE__ */ l("span", {
793
801
  className: "text-xs text-text-secondary",
794
802
  children: e(t.date)
795
803
  })]
796
804
  }),
797
- /* @__PURE__ */ d("p", {
805
+ /* @__PURE__ */ l("p", {
798
806
  className: "mt-1 text-sm font-medium text-text-primary",
799
807
  children: t.title
800
808
  }),
801
- /* @__PURE__ */ d("p", {
809
+ /* @__PURE__ */ l("p", {
802
810
  className: "text-xs text-text-secondary",
803
811
  children: t.detail
804
812
  })
@@ -806,212 +814,217 @@ var p = (e) => {
806
814
  })]
807
815
  }, t.id))
808
816
  })]
809
- }) : /* @__PURE__ */ d("p", {
817
+ }) : /* @__PURE__ */ l("p", {
810
818
  className: "py-8 text-center text-sm text-text-secondary",
811
- children: v("healthybowl.livestock.animalDetails.timeline.empty", "No timeline records for this animal")
819
+ children: y("healthybowl.livestock.animalDetails.timeline.empty", "No timeline records for this animal")
812
820
  })
813
821
  }),
814
- /* @__PURE__ */ d(oe, {
815
- open: Me,
816
- onClose: () => S(!1),
817
- title: v("healthybowl.livestock.animalDetails.editModal.title", "Edit Animal Details"),
818
- description: v("healthybowl.livestock.animalDetails.editModal.description", "Update details for {{name}}", { name: E.name }),
822
+ /* @__PURE__ */ l(oe, {
823
+ open: Ie,
824
+ onClose: () => w(!1),
825
+ title: y("healthybowl.livestock.animalDetails.editModal.title", "Edit Animal Details"),
826
+ description: y("healthybowl.livestock.animalDetails.editModal.description", "Update details for {{name}}", { name: O.name }),
819
827
  size: "lg",
820
- footer: /* @__PURE__ */ f(xe, { children: [/* @__PURE__ */ d("button", {
821
- onClick: () => S(!1),
822
- className: "rounded-md border border-border-subtle px-4 py-2 text-sm text-text-secondary hover:text-text-primary",
823
- children: v("healthybowl.common.cancel", "Cancel")
824
- }), /* @__PURE__ */ d("button", {
825
- onClick: ze,
826
- disabled: C,
827
- className: "rounded-md bg-action-primary-bg px-4 py-2 text-sm font-medium text-action-primary-text hover:bg-action-primary-bg/90 disabled:opacity-60",
828
- children: C ? v("healthybowl.common.saving", "Saving...") : v("healthybowl.livestock.animalDetails.editModal.save", "Save Changes")
828
+ footer: /* @__PURE__ */ u(Ce, { children: [/* @__PURE__ */ l(d, {
829
+ variant: "outline",
830
+ onClick: () => w(!1),
831
+ children: y("healthybowl.common.cancel", "Cancel")
832
+ }), /* @__PURE__ */ l(d, {
833
+ onClick: Ge,
834
+ disabled: T,
835
+ children: T ? y("healthybowl.common.saving", "Saving...") : y("healthybowl.livestock.animalDetails.editModal.save", "Save Changes")
829
836
  })] }),
830
- children: /* @__PURE__ */ f("div", {
837
+ children: /* @__PURE__ */ u("div", {
831
838
  className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
832
839
  children: [
833
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ f("label", {
840
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ u("label", {
834
841
  className: "text-sm font-medium text-text-primary",
835
- children: [v("healthybowl.livestock.animalDetails.form.name", "Name"), " *"]
836
- }), /* @__PURE__ */ d("input", {
842
+ children: [y("healthybowl.livestock.animalDetails.form.name", "Name"), " *"]
843
+ }), /* @__PURE__ */ l("input", {
837
844
  type: "text",
838
- value: D,
839
- onChange: (e) => O(e.target.value),
845
+ value: k,
846
+ onChange: (e) => A(e.target.value),
840
847
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
841
848
  })] }),
842
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ f("label", {
849
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ u("label", {
843
850
  className: "text-sm font-medium text-text-primary",
844
- children: [v("healthybowl.livestock.animalDetails.form.tagNumber", "Tag Number"), " *"]
845
- }), /* @__PURE__ */ d("input", {
851
+ children: [y("healthybowl.livestock.animalDetails.form.tagNumber", "Tag Number"), " *"]
852
+ }), /* @__PURE__ */ l("input", {
846
853
  type: "text",
847
- value: L,
848
- onChange: (e) => R(e.target.value),
854
+ value: z,
855
+ onChange: (e) => B(e.target.value),
849
856
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
850
857
  })] }),
851
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
858
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
852
859
  className: "text-sm font-medium text-text-primary",
853
- children: v("healthybowl.livestock.animalDetails.fields.type", "Type")
854
- }), /* @__PURE__ */ f("select", {
855
- value: k,
856
- onChange: (e) => A(e.target.value),
857
- className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
858
- children: [
859
- /* @__PURE__ */ d("option", {
860
+ children: y("healthybowl.livestock.animalDetails.fields.type", "Type")
861
+ }), /* @__PURE__ */ u(f, {
862
+ value: j,
863
+ onValueChange: M,
864
+ children: [/* @__PURE__ */ l(h, {
865
+ className: "mt-1 w-full",
866
+ children: /* @__PURE__ */ l(g, { placeholder: y("healthybowl.livestock.animalDetails.fields.type", "Type") })
867
+ }), /* @__PURE__ */ u(p, { children: [
868
+ /* @__PURE__ */ l(m, {
860
869
  value: "cattle",
861
- children: v("healthybowl.livestock.animalDetails.types.cattle", "Cattle")
870
+ children: y("healthybowl.livestock.animalDetails.types.cattle", "Cattle")
862
871
  }),
863
- /* @__PURE__ */ d("option", {
872
+ /* @__PURE__ */ l(m, {
864
873
  value: "buffalo",
865
- children: v("healthybowl.livestock.animalDetails.types.buffalo", "Buffalo")
874
+ children: y("healthybowl.livestock.animalDetails.types.buffalo", "Buffalo")
866
875
  }),
867
- /* @__PURE__ */ d("option", {
876
+ /* @__PURE__ */ l(m, {
868
877
  value: "goat",
869
- children: v("healthybowl.livestock.animalDetails.types.goat", "Goat")
878
+ children: y("healthybowl.livestock.animalDetails.types.goat", "Goat")
870
879
  }),
871
- /* @__PURE__ */ d("option", {
880
+ /* @__PURE__ */ l(m, {
872
881
  value: "sheep",
873
- children: v("healthybowl.livestock.animalDetails.types.sheep", "Sheep")
882
+ children: y("healthybowl.livestock.animalDetails.types.sheep", "Sheep")
874
883
  }),
875
- /* @__PURE__ */ d("option", {
884
+ /* @__PURE__ */ l(m, {
876
885
  value: "pig",
877
- children: v("healthybowl.livestock.animalDetails.types.pig", "Pig")
886
+ children: y("healthybowl.livestock.animalDetails.types.pig", "Pig")
878
887
  }),
879
- /* @__PURE__ */ d("option", {
888
+ /* @__PURE__ */ l(m, {
880
889
  value: "poultry",
881
- children: v("healthybowl.livestock.animalDetails.types.poultry", "Poultry")
890
+ children: y("healthybowl.livestock.animalDetails.types.poultry", "Poultry")
882
891
  })
883
- ]
892
+ ] })]
884
893
  })] }),
885
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
894
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
886
895
  className: "text-sm font-medium text-text-primary",
887
- children: v("healthybowl.livestock.animalDetails.fields.breed", "Breed")
888
- }), /* @__PURE__ */ d("input", {
896
+ children: y("healthybowl.livestock.animalDetails.fields.breed", "Breed")
897
+ }), /* @__PURE__ */ l("input", {
889
898
  type: "text",
890
- value: j,
891
- onChange: (e) => M(e.target.value),
899
+ value: N,
900
+ onChange: (e) => P(e.target.value),
892
901
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
893
902
  })] }),
894
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
903
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
895
904
  className: "text-sm font-medium text-text-primary",
896
- children: v("healthybowl.livestock.animalDetails.fields.gender", "Gender")
897
- }), /* @__PURE__ */ f("select", {
898
- value: N,
899
- onChange: (e) => P(e.target.value),
900
- className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
901
- children: [/* @__PURE__ */ d("option", {
905
+ children: y("healthybowl.livestock.animalDetails.fields.gender", "Gender")
906
+ }), /* @__PURE__ */ u(f, {
907
+ value: F,
908
+ onValueChange: I,
909
+ children: [/* @__PURE__ */ l(h, {
910
+ className: "mt-1 w-full",
911
+ children: /* @__PURE__ */ l(g, { placeholder: y("healthybowl.livestock.animalDetails.fields.gender", "Gender") })
912
+ }), /* @__PURE__ */ u(p, { children: [/* @__PURE__ */ l(m, {
902
913
  value: "male",
903
- children: v("healthybowl.livestock.animalDetails.genders.male", "Male")
904
- }), /* @__PURE__ */ d("option", {
914
+ children: y("healthybowl.livestock.animalDetails.genders.male", "Male")
915
+ }), /* @__PURE__ */ l(m, {
905
916
  value: "female",
906
- children: v("healthybowl.livestock.animalDetails.genders.female", "Female")
907
- })]
917
+ children: y("healthybowl.livestock.animalDetails.genders.female", "Female")
918
+ })] })]
908
919
  })] }),
909
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
920
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
910
921
  className: "text-sm font-medium text-text-primary",
911
- children: v("healthybowl.livestock.animalDetails.form.healthStatus", "Health Status")
912
- }), /* @__PURE__ */ f("select", {
913
- value: F,
914
- onChange: (e) => I(e.target.value),
915
- className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary",
916
- children: [
917
- /* @__PURE__ */ d("option", {
922
+ children: y("healthybowl.livestock.animalDetails.form.healthStatus", "Health Status")
923
+ }), /* @__PURE__ */ u(f, {
924
+ value: L,
925
+ onValueChange: R,
926
+ children: [/* @__PURE__ */ l(h, {
927
+ className: "mt-1 w-full",
928
+ children: /* @__PURE__ */ l(g, { placeholder: y("healthybowl.livestock.animalDetails.form.healthStatus", "Health Status") })
929
+ }), /* @__PURE__ */ u(p, { children: [
930
+ /* @__PURE__ */ l(m, {
918
931
  value: "healthy",
919
- children: v("healthybowl.livestock.animalDetails.healthStatuses.healthy", "Healthy")
932
+ children: y("healthybowl.livestock.animalDetails.healthStatuses.healthy", "Healthy")
920
933
  }),
921
- /* @__PURE__ */ d("option", {
934
+ /* @__PURE__ */ l(m, {
922
935
  value: "pregnant",
923
- children: v("healthybowl.livestock.animalDetails.healthStatuses.pregnant", "Pregnant")
936
+ children: y("healthybowl.livestock.animalDetails.healthStatuses.pregnant", "Pregnant")
924
937
  }),
925
- /* @__PURE__ */ d("option", {
938
+ /* @__PURE__ */ l(m, {
926
939
  value: "under_treatment",
927
- children: v("healthybowl.livestock.animalDetails.healthStatuses.underTreatment", "Under Treatment")
940
+ children: y("healthybowl.livestock.animalDetails.healthStatuses.underTreatment", "Under Treatment")
928
941
  }),
929
- /* @__PURE__ */ d("option", {
942
+ /* @__PURE__ */ l(m, {
930
943
  value: "sick",
931
- children: v("healthybowl.livestock.animalDetails.healthStatuses.sick", "Sick")
944
+ children: y("healthybowl.livestock.animalDetails.healthStatuses.sick", "Sick")
932
945
  }),
933
- /* @__PURE__ */ d("option", {
946
+ /* @__PURE__ */ l(m, {
934
947
  value: "quarantine",
935
- children: v("healthybowl.livestock.animalDetails.healthStatuses.quarantine", "Quarantine")
948
+ children: y("healthybowl.livestock.animalDetails.healthStatuses.quarantine", "Quarantine")
936
949
  })
937
- ]
950
+ ] })]
938
951
  })] }),
939
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
952
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
940
953
  className: "text-sm font-medium text-text-primary",
941
- children: v("healthybowl.livestock.animalDetails.form.weight", "Weight (kg)")
942
- }), /* @__PURE__ */ d("input", {
954
+ children: y("healthybowl.livestock.animalDetails.form.weight", "Weight (kg)")
955
+ }), /* @__PURE__ */ l("input", {
943
956
  type: "number",
944
957
  min: 0,
945
- value: V,
946
- onChange: (e) => H(e.target.value),
958
+ value: U,
959
+ onChange: (e) => W(e.target.value),
947
960
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
948
961
  })] }),
949
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
962
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
950
963
  className: "text-sm font-medium text-text-primary",
951
- children: v("healthybowl.livestock.animalDetails.form.vaccinations", "Vaccinations")
952
- }), /* @__PURE__ */ d("input", {
964
+ children: y("healthybowl.livestock.animalDetails.form.vaccinations", "Vaccinations")
965
+ }), /* @__PURE__ */ l("input", {
953
966
  type: "number",
954
967
  min: 0,
955
- value: z,
956
- onChange: (e) => B(e.target.value),
968
+ value: V,
969
+ onChange: (e) => H(e.target.value),
957
970
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
958
971
  })] }),
959
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
972
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
960
973
  className: "text-sm font-medium text-text-primary",
961
- children: v("healthybowl.livestock.animalDetails.fields.dateOfBirth", "Date of Birth")
962
- }), /* @__PURE__ */ d("input", {
974
+ children: y("healthybowl.livestock.animalDetails.fields.dateOfBirth", "Date of Birth")
975
+ }), /* @__PURE__ */ l("input", {
963
976
  type: "date",
964
- value: U,
965
- onChange: (e) => W(e.target.value),
977
+ value: G,
978
+ onChange: (e) => ze(e.target.value),
966
979
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
967
980
  })] }),
968
- /* @__PURE__ */ f("div", { children: [/* @__PURE__ */ d("label", {
981
+ /* @__PURE__ */ u("div", { children: [/* @__PURE__ */ l("label", {
969
982
  className: "text-sm font-medium text-text-primary",
970
- children: v("healthybowl.livestock.animalDetails.fields.lastCheckup", "Last Checkup")
971
- }), /* @__PURE__ */ d("input", {
983
+ children: y("healthybowl.livestock.animalDetails.fields.lastCheckup", "Last Checkup")
984
+ }), /* @__PURE__ */ l("input", {
972
985
  type: "date",
973
- value: G,
974
- onChange: (e) => K(e.target.value),
986
+ value: K,
987
+ onChange: (e) => Be(e.target.value),
975
988
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
976
989
  })] }),
977
- /* @__PURE__ */ f("div", {
990
+ /* @__PURE__ */ u("div", {
978
991
  className: "sm:col-span-2",
979
- children: [/* @__PURE__ */ d("label", {
992
+ children: [/* @__PURE__ */ l("label", {
980
993
  className: "text-sm font-medium text-text-primary",
981
- children: v("healthybowl.livestock.animalDetails.form.productionType", "Production Type")
982
- }), /* @__PURE__ */ d("input", {
994
+ children: y("healthybowl.livestock.animalDetails.form.productionType", "Production Type")
995
+ }), /* @__PURE__ */ l("input", {
983
996
  type: "text",
984
997
  value: q,
985
- onChange: (e) => Fe(e.target.value),
986
- placeholder: v("healthybowl.livestock.animalDetails.form.productionTypePlaceholder", "e.g. dairy, meat, eggs"),
998
+ onChange: (e) => Ve(e.target.value),
999
+ placeholder: y("healthybowl.livestock.animalDetails.form.productionTypePlaceholder", "e.g. dairy, meat, eggs"),
987
1000
  className: "mt-1 w-full rounded-md border border-border-subtle bg-bg-surface px-3 py-2 text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-[var(--color-focus-ring)]"
988
1001
  })]
989
1002
  }),
990
- /* @__PURE__ */ f("div", {
1003
+ /* @__PURE__ */ u("div", {
991
1004
  className: "sm:col-span-2",
992
- children: [/* @__PURE__ */ d("label", {
1005
+ children: [/* @__PURE__ */ l("label", {
993
1006
  className: "text-sm font-medium text-text-primary",
994
- children: v("healthybowl.livestock.animalDetails.form.photos", "Photos")
995
- }), /* @__PURE__ */ d("div", {
1007
+ children: y("healthybowl.livestock.animalDetails.form.photos", "Photos")
1008
+ }), /* @__PURE__ */ l("div", {
996
1009
  className: "mt-1",
997
- children: /* @__PURE__ */ d(a, {
1010
+ children: /* @__PURE__ */ l(se, {
998
1011
  entity: "Animal",
999
- imageIds: Ie,
1000
- onChange: Le
1012
+ imageIds: He,
1013
+ onChange: Ue
1001
1014
  })
1002
1015
  })]
1003
1016
  })
1004
1017
  ]
1005
1018
  })
1006
1019
  }),
1007
- /* @__PURE__ */ d(re, {
1008
- toasts: Ne,
1009
- onDismiss: Pe
1020
+ /* @__PURE__ */ l(re, {
1021
+ toasts: Le,
1022
+ onDismiss: Re
1010
1023
  })
1011
1024
  ]
1012
1025
  });
1013
1026
  };
1014
1027
  //#endregion
1015
- export { m as AnimalDetailsPage };
1028
+ export { v as AnimalDetailsPage };
1016
1029
 
1017
1030
  //# sourceMappingURL=AnimalDetailsPage.js.map