@burdenoff/microfe-proserviceworld 2026.706.2 → 2026.706.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.
Files changed (26) hide show
  1. package/dist/proserviceworld/components/DiscussionThread.js +1 -1
  2. package/dist/proserviceworld/components/DiscussionThread.js.map +1 -1
  3. package/dist/proserviceworld/components/ui.js +18 -18
  4. package/dist/proserviceworld/components/ui.js.map +1 -1
  5. package/dist/proserviceworld/hooks/useEntityComments.js.map +1 -1
  6. package/dist/proserviceworld/pages/AnalyticsPage.js +277 -111
  7. package/dist/proserviceworld/pages/AnalyticsPage.js.map +1 -1
  8. package/dist/proserviceworld/pages/ClientDetailPage.js +219 -151
  9. package/dist/proserviceworld/pages/ClientDetailPage.js.map +1 -1
  10. package/dist/proserviceworld/pages/ClientsPage.js +148 -127
  11. package/dist/proserviceworld/pages/ClientsPage.js.map +1 -1
  12. package/dist/proserviceworld/pages/CompliancePage.js +140 -96
  13. package/dist/proserviceworld/pages/CompliancePage.js.map +1 -1
  14. package/dist/proserviceworld/pages/DashboardPage.js +221 -104
  15. package/dist/proserviceworld/pages/DashboardPage.js.map +1 -1
  16. package/dist/proserviceworld/pages/EngagementDetailPage.js +211 -181
  17. package/dist/proserviceworld/pages/EngagementDetailPage.js.map +1 -1
  18. package/dist/proserviceworld/pages/EngagementsPage.js +144 -106
  19. package/dist/proserviceworld/pages/EngagementsPage.js.map +1 -1
  20. package/dist/proserviceworld/pages/InvoicesPage.js +144 -129
  21. package/dist/proserviceworld/pages/InvoicesPage.js.map +1 -1
  22. package/dist/proserviceworld/pages/MattersPage.js +163 -122
  23. package/dist/proserviceworld/pages/MattersPage.js.map +1 -1
  24. package/dist/proserviceworld/pages/TimePage.js +112 -92
  25. package/dist/proserviceworld/pages/TimePage.js.map +1 -1
  26. package/package.json +1 -1
@@ -3,12 +3,12 @@ import { useNav as s } from "../utils/nav.js";
3
3
  import { Banner as c, Empty as l, ErrorState as u, Field as d, LoadingBlock as f, MetricCard as p, Modal as m, NativeSelect as h, PageHeader as g, SectionCard as _, StatusPill as v, TextArea as y, TextInput as b, fmtDate as x, fmtMinutesAsHours as S, fmtMoney as C, humanize as w } from "../components/ui.js";
4
4
  import { DiscussionThread as T } from "../components/DiscussionThread.js";
5
5
  import { useState as E } from "react";
6
- import { ArrowLeft as D, CheckCircle2 as O, Clock as k, FileText as A, Flag as j, Plus as M } from "lucide-react";
7
- import { useParams as N } from "react-router-dom";
8
- import { Fragment as P, jsx as F, jsxs as I } from "react/jsx-runtime";
9
- import { Button as L } from "@burdenoff/fe-libs/ui";
6
+ import { ArrowLeft as D, ArrowRight as O, CheckCircle2 as k, Clock as A, DollarSign as j, FileText as M, Flag as N, Plus as P } from "lucide-react";
7
+ import { useParams as F } from "react-router-dom";
8
+ import { Fragment as I, jsx as L, jsxs as R } from "react/jsx-runtime";
9
+ import { Button as z } from "@burdenoff/fe-libs/ui";
10
10
  //#region src/proserviceworld/pages/EngagementDetailPage.tsx
11
- var R = {
11
+ var B = {
12
12
  PROPOSAL: ["ACCEPTED", "CANCELLED"],
13
13
  ACCEPTED: ["IN_PROGRESS", "CANCELLED"],
14
14
  IN_PROGRESS: ["REVIEW", "CANCELLED"],
@@ -21,123 +21,141 @@ var R = {
21
21
  INVOICED: ["CLOSED"],
22
22
  CLOSED: [],
23
23
  CANCELLED: []
24
- }, z = [
24
+ }, V = [
25
25
  "DRAFT",
26
26
  "INTERNAL_REVIEW",
27
27
  "CLIENT_REVIEW",
28
28
  "ACCEPTED",
29
29
  "REJECTED"
30
- ], B = () => {
31
- let { id: e = "" } = N(), t = s(), { data: n, isLoading: a, error: d, refetch: m } = r(e), h = i({ engagementId: e }), y = o(), [b, O] = E(!1), [P, z] = E(!1), [B, G] = E(null);
32
- if (a) return /* @__PURE__ */ F(f, {});
33
- if (d) return /* @__PURE__ */ F(u, {
30
+ ], H = () => {
31
+ let { id: e = "" } = F(), t = s(), { data: n, isLoading: a, error: d, refetch: m } = r(e), h = i({ engagementId: e }), y = o(), [b, k] = E(!1), [I, V] = E(!1), [H, q] = E(null);
32
+ if (a) return /* @__PURE__ */ L(f, {});
33
+ if (d) return /* @__PURE__ */ L(u, {
34
34
  error: d,
35
35
  onRetry: () => void m()
36
36
  });
37
- if (!n) return /* @__PURE__ */ F(l, { title: "Engagement not found" });
38
- let K = R[n.status] ?? [], q = (h.data?.items ?? []).reduce((e, t) => e + t.minutes, 0);
39
- return /* @__PURE__ */ I("div", {
37
+ if (!n) return /* @__PURE__ */ L(l, { title: "Engagement not found" });
38
+ let J = B[n.status] ?? [], Y = (h.data?.items ?? []).reduce((e, t) => e + t.minutes, 0);
39
+ return /* @__PURE__ */ R("div", {
40
40
  className: "space-y-6",
41
41
  children: [
42
- /* @__PURE__ */ I("button", {
42
+ /* @__PURE__ */ R("button", {
43
43
  type: "button",
44
44
  onClick: () => t("engagements"),
45
- className: "flex items-center gap-1.5 text-sm text-text-secondary hover:text-accent",
46
- children: [/* @__PURE__ */ F(D, { className: "h-4 w-4" }), " Back to engagements"]
45
+ className: "flex items-center gap-1.5 text-sm text-text-secondary transition-colors hover:text-accent",
46
+ children: [/* @__PURE__ */ L(D, { className: "h-4 w-4" }), " Back to engagements"]
47
47
  }),
48
- /* @__PURE__ */ F(g, {
48
+ /* @__PURE__ */ L(g, {
49
49
  title: n.name,
50
50
  subtitle: n.client ? `${n.client.name} · ${w(n.feeArrangement)}` : w(n.feeArrangement),
51
- actions: /* @__PURE__ */ F(v, { status: n.status })
51
+ actions: /* @__PURE__ */ L(v, { status: n.status })
52
52
  }),
53
- B && /* @__PURE__ */ F(c, {
54
- tone: B.tone,
55
- onClose: () => G(null),
56
- children: B.text
53
+ H && /* @__PURE__ */ L(c, {
54
+ tone: H.tone,
55
+ onClose: () => q(null),
56
+ children: H.text
57
57
  }),
58
- /* @__PURE__ */ I("div", {
58
+ /* @__PURE__ */ R("div", {
59
59
  className: "grid grid-cols-2 gap-3 lg:grid-cols-4",
60
60
  children: [
61
- /* @__PURE__ */ F(p, {
61
+ /* @__PURE__ */ L(p, {
62
62
  label: "Fee",
63
63
  value: C(n.feeAmount, n.currency),
64
- hint: w(n.feeArrangement)
64
+ hint: w(n.feeArrangement),
65
+ icon: /* @__PURE__ */ L(j, { className: "h-4 w-4" }),
66
+ tone: "success"
65
67
  }),
66
- /* @__PURE__ */ F(p, {
68
+ /* @__PURE__ */ L(p, {
67
69
  label: "Deliverables",
68
- value: n.deliverables.length
70
+ value: n.deliverables.length,
71
+ icon: /* @__PURE__ */ L(M, { className: "h-4 w-4" }),
72
+ tone: "info"
69
73
  }),
70
- /* @__PURE__ */ F(p, {
74
+ /* @__PURE__ */ L(p, {
71
75
  label: "Milestones",
72
- value: n.milestones.length
76
+ value: n.milestones.length,
77
+ icon: /* @__PURE__ */ L(N, { className: "h-4 w-4" }),
78
+ tone: "accent"
73
79
  }),
74
- /* @__PURE__ */ F(p, {
80
+ /* @__PURE__ */ L(p, {
75
81
  label: "Time logged",
76
- value: S(q),
77
- hint: `${h.data?.totalCount ?? 0} entries`
82
+ value: S(Y),
83
+ hint: `${h.data?.totalCount ?? 0} entries`,
84
+ icon: /* @__PURE__ */ L(A, { className: "h-4 w-4" }),
85
+ tone: "warning"
78
86
  })
79
87
  ]
80
88
  }),
81
- K.length > 0 && /* @__PURE__ */ F(_, {
89
+ J.length > 0 && /* @__PURE__ */ L(_, {
82
90
  title: "Advance lifecycle",
83
- description: `Current status: ${w(n.status)}`,
84
- children: /* @__PURE__ */ F("div", {
85
- className: "flex flex-wrap gap-2",
86
- children: K.map((e) => /* @__PURE__ */ F(L, {
87
- size: "sm",
88
- variant: e === "CANCELLED" ? "outline" : "default",
89
- disabled: y.isPending,
90
- onClick: () => y.mutate({
91
- id: n.id,
92
- status: e
93
- }, {
94
- onSuccess: () => G({
95
- tone: "success",
96
- text: `Moved to ${w(e)}.`
97
- }),
98
- onError: (e) => G({
99
- tone: "danger",
100
- text: e instanceof Error ? e.message : "Transition failed."
101
- })
102
- }),
103
- children: w(e)
104
- }, e))
91
+ children: /* @__PURE__ */ R("div", {
92
+ className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between",
93
+ children: [/* @__PURE__ */ R("div", {
94
+ className: "flex items-center gap-2 text-sm text-text-secondary",
95
+ children: [/* @__PURE__ */ L("span", { children: "Currently" }), /* @__PURE__ */ L(v, { status: n.status })]
96
+ }), /* @__PURE__ */ L("div", {
97
+ className: "flex flex-wrap gap-2",
98
+ children: J.map((e) => {
99
+ let t = e === "CANCELLED";
100
+ return /* @__PURE__ */ R(z, {
101
+ size: "sm",
102
+ variant: t ? "outline" : "default",
103
+ disabled: y.isPending,
104
+ onClick: () => y.mutate({
105
+ id: n.id,
106
+ status: e
107
+ }, {
108
+ onSuccess: () => q({
109
+ tone: "success",
110
+ text: `Moved to ${w(e)}.`
111
+ }),
112
+ onError: (e) => q({
113
+ tone: "danger",
114
+ text: e instanceof Error ? e.message : "Transition failed."
115
+ })
116
+ }),
117
+ children: [w(e), !t && /* @__PURE__ */ L(O, { className: "ml-1.5 h-4 w-4" })]
118
+ }, e);
119
+ })
120
+ })]
105
121
  })
106
122
  }),
107
- /* @__PURE__ */ I("div", {
123
+ /* @__PURE__ */ R("div", {
108
124
  className: "grid grid-cols-1 gap-4 lg:grid-cols-2",
109
- children: [/* @__PURE__ */ F(_, {
125
+ children: [/* @__PURE__ */ L(_, {
110
126
  title: "Deliverables",
111
- action: /* @__PURE__ */ I(L, {
127
+ action: /* @__PURE__ */ R(z, {
112
128
  size: "sm",
113
129
  variant: "outline",
114
- onClick: () => O(!0),
115
- children: [/* @__PURE__ */ F(M, { className: "mr-1.5 h-4 w-4" }), "Add"]
130
+ onClick: () => k(!0),
131
+ children: [/* @__PURE__ */ L(P, { className: "mr-1.5 h-4 w-4" }), "Add"]
116
132
  }),
117
- children: n.deliverables.length === 0 ? /* @__PURE__ */ F(l, {
133
+ children: n.deliverables.length === 0 ? /* @__PURE__ */ L(l, {
118
134
  title: "No deliverables",
119
135
  description: "Track the tangible outputs of this engagement.",
120
- icon: /* @__PURE__ */ F(A, { className: "h-7 w-7" })
121
- }) : /* @__PURE__ */ F("ul", {
122
- className: "space-y-2",
123
- children: n.deliverables.map((e) => /* @__PURE__ */ F("li", {
124
- className: "rounded-lg border border-border-seam p-3",
125
- children: /* @__PURE__ */ I("div", {
126
- className: "flex items-start justify-between gap-2",
127
- children: [/* @__PURE__ */ I("div", { children: [/* @__PURE__ */ I("div", {
128
- className: "text-sm font-medium text-text-primary",
129
- children: [
130
- e.name,
131
- " ",
132
- /* @__PURE__ */ I("span", {
133
- className: "text-xs text-text-tertiary",
136
+ icon: /* @__PURE__ */ L(M, { className: "h-7 w-7" })
137
+ }) : /* @__PURE__ */ L("ul", {
138
+ className: "space-y-2.5",
139
+ children: n.deliverables.map((e) => /* @__PURE__ */ L("li", {
140
+ className: "rounded-xl border border-border-seam bg-bg-canvas p-3.5 transition-colors hover:border-accent/40",
141
+ children: /* @__PURE__ */ R("div", {
142
+ className: "flex items-start justify-between gap-3",
143
+ children: [/* @__PURE__ */ R("div", {
144
+ className: "min-w-0",
145
+ children: [/* @__PURE__ */ R("div", {
146
+ className: "flex items-center gap-2 text-sm font-medium text-text-primary",
147
+ children: [/* @__PURE__ */ L("span", {
148
+ className: "truncate",
149
+ children: e.name
150
+ }), /* @__PURE__ */ R("span", {
151
+ className: "shrink-0 rounded-md bg-bg-sunken px-1.5 py-0.5 text-[10px] font-semibold text-text-tertiary",
134
152
  children: ["v", e.version]
135
- })
136
- ]
137
- }), e.dueDate && /* @__PURE__ */ I("div", {
138
- className: "text-xs text-text-tertiary",
139
- children: ["Due ", x(e.dueDate)]
140
- })] }), /* @__PURE__ */ F(V, {
153
+ })]
154
+ }), e.dueDate && /* @__PURE__ */ R("div", {
155
+ className: "mt-0.5 text-xs text-text-tertiary",
156
+ children: ["Due ", x(e.dueDate)]
157
+ })]
158
+ }), /* @__PURE__ */ L(U, {
141
159
  id: e.id,
142
160
  engagementId: n.id,
143
161
  status: e.status,
@@ -146,35 +164,38 @@ var R = {
146
164
  })
147
165
  }, e.id))
148
166
  })
149
- }), /* @__PURE__ */ F(_, {
167
+ }), /* @__PURE__ */ L(_, {
150
168
  title: "Milestones",
151
- action: /* @__PURE__ */ I(L, {
169
+ action: /* @__PURE__ */ R(z, {
152
170
  size: "sm",
153
171
  variant: "outline",
154
- onClick: () => z(!0),
155
- children: [/* @__PURE__ */ F(M, { className: "mr-1.5 h-4 w-4" }), "Add"]
172
+ onClick: () => V(!0),
173
+ children: [/* @__PURE__ */ L(P, { className: "mr-1.5 h-4 w-4" }), "Add"]
156
174
  }),
157
- children: n.milestones.length === 0 ? /* @__PURE__ */ F(l, {
175
+ children: n.milestones.length === 0 ? /* @__PURE__ */ L(l, {
158
176
  title: "No milestones",
159
177
  description: "Add checkpoints — some can trigger billing.",
160
- icon: /* @__PURE__ */ F(j, { className: "h-7 w-7" })
161
- }) : /* @__PURE__ */ F("ul", {
162
- className: "space-y-2",
163
- children: n.milestones.map((e) => /* @__PURE__ */ I("li", {
164
- className: "flex items-center justify-between rounded-lg border border-border-seam p-3",
165
- children: [/* @__PURE__ */ I("div", { children: [/* @__PURE__ */ F("div", {
166
- className: "text-sm font-medium text-text-primary",
167
- children: e.name
168
- }), /* @__PURE__ */ I("div", {
169
- className: "text-xs text-text-tertiary",
170
- children: [
171
- e.triggersInvoice ? `Bills ${C(e.triggerAmount, n.currency)} · ` : "",
172
- "Due ",
173
- x(e.dueDate)
174
- ]
175
- })] }), /* @__PURE__ */ I("div", {
176
- className: "flex items-center gap-2",
177
- children: [/* @__PURE__ */ F(v, { status: e.status }), e.status !== "COMPLETED" && e.status !== "CANCELLED" && /* @__PURE__ */ F(H, {
178
+ icon: /* @__PURE__ */ L(N, { className: "h-7 w-7" })
179
+ }) : /* @__PURE__ */ L("ul", {
180
+ className: "space-y-2.5",
181
+ children: n.milestones.map((e) => /* @__PURE__ */ R("li", {
182
+ className: "flex items-center justify-between gap-3 rounded-xl border border-border-seam bg-bg-canvas p-3.5 transition-colors hover:border-accent/40",
183
+ children: [/* @__PURE__ */ R("div", {
184
+ className: "min-w-0",
185
+ children: [/* @__PURE__ */ L("div", {
186
+ className: "truncate text-sm font-medium text-text-primary",
187
+ children: e.name
188
+ }), /* @__PURE__ */ R("div", {
189
+ className: "mt-0.5 text-xs text-text-tertiary",
190
+ children: [
191
+ e.triggersInvoice ? `Bills ${C(e.triggerAmount, n.currency)} · ` : "",
192
+ "Due ",
193
+ x(e.dueDate)
194
+ ]
195
+ })]
196
+ }), /* @__PURE__ */ R("div", {
197
+ className: "flex shrink-0 items-center gap-2",
198
+ children: [/* @__PURE__ */ L(v, { status: e.status }), e.status !== "COMPLETED" && e.status !== "CANCELLED" && /* @__PURE__ */ L(W, {
178
199
  id: e.id,
179
200
  engagementId: n.id,
180
201
  onDone: () => void m()
@@ -184,57 +205,66 @@ var R = {
184
205
  })
185
206
  })]
186
207
  }),
187
- /* @__PURE__ */ F(_, {
188
- title: "Time logged",
189
- action: /* @__PURE__ */ I(L, {
190
- size: "sm",
191
- variant: "outline",
192
- onClick: () => t("time"),
193
- children: [/* @__PURE__ */ F(k, { className: "mr-1.5 h-4 w-4" }), "Log time"]
194
- }),
195
- children: h.isLoading ? /* @__PURE__ */ F(f, { label: "Loading…" }) : !h.data || h.data.items.length === 0 ? /* @__PURE__ */ F(l, {
196
- title: "No time logged",
197
- description: "Time logged against this engagement will appear here."
198
- }) : /* @__PURE__ */ F("ul", {
199
- className: "divide-y divide-border-seam",
200
- children: h.data.items.slice(0, 8).map((e) => /* @__PURE__ */ I("li", {
201
- className: "flex items-center justify-between py-2 text-sm",
202
- children: [/* @__PURE__ */ I("span", {
203
- className: "text-text-secondary",
204
- children: [
205
- x(e.date),
206
- " · ",
207
- e.narrative || "Time entry"
208
- ]
209
- }), /* @__PURE__ */ I("span", {
210
- className: "flex items-center gap-2",
211
- children: [/* @__PURE__ */ F("span", {
212
- className: "text-text-primary",
213
- children: S(e.minutes)
214
- }), /* @__PURE__ */ F(v, { status: e.status })]
215
- })]
216
- }, e.id))
217
- })
218
- }),
219
- /* @__PURE__ */ F(T, {
220
- entityType: "proserviceworld-engagement",
221
- entityId: n.id
208
+ /* @__PURE__ */ R("div", {
209
+ className: "grid grid-cols-1 gap-4 lg:grid-cols-3",
210
+ children: [/* @__PURE__ */ L("div", {
211
+ className: "lg:col-span-2",
212
+ children: /* @__PURE__ */ L(T, {
213
+ entityType: "proserviceworld-engagement",
214
+ entityId: n.id
215
+ })
216
+ }), /* @__PURE__ */ L(_, {
217
+ title: "Time logged",
218
+ description: S(Y),
219
+ action: /* @__PURE__ */ R(z, {
220
+ size: "sm",
221
+ variant: "outline",
222
+ onClick: () => t("time"),
223
+ children: [/* @__PURE__ */ L(A, { className: "mr-1.5 h-4 w-4" }), "Log time"]
224
+ }),
225
+ children: h.isLoading ? /* @__PURE__ */ L(f, { label: "Loading…" }) : !h.data || h.data.items.length === 0 ? /* @__PURE__ */ L(l, {
226
+ title: "No time logged",
227
+ description: "Time logged against this engagement will appear here.",
228
+ icon: /* @__PURE__ */ L(A, { className: "h-7 w-7" })
229
+ }) : /* @__PURE__ */ L("ul", {
230
+ className: "space-y-2",
231
+ children: h.data.items.slice(0, 8).map((e) => /* @__PURE__ */ R("li", {
232
+ className: "rounded-lg border border-border-seam bg-bg-canvas p-3 text-sm",
233
+ children: [/* @__PURE__ */ R("div", {
234
+ className: "flex items-center justify-between gap-2",
235
+ children: [/* @__PURE__ */ L("span", {
236
+ className: "whitespace-nowrap text-xs text-text-tertiary",
237
+ children: x(e.date)
238
+ }), /* @__PURE__ */ R("span", {
239
+ className: "flex items-center gap-2",
240
+ children: [/* @__PURE__ */ L("span", {
241
+ className: "font-medium text-text-primary",
242
+ children: S(e.minutes)
243
+ }), /* @__PURE__ */ L(v, { status: e.status })]
244
+ })]
245
+ }), /* @__PURE__ */ L("div", {
246
+ className: "mt-1 truncate text-text-secondary",
247
+ children: e.narrative || "Time entry"
248
+ })]
249
+ }, e.id))
250
+ })
251
+ })]
222
252
  }),
223
- b && /* @__PURE__ */ F(U, {
253
+ b && /* @__PURE__ */ L(G, {
224
254
  engagementId: n.id,
225
- onClose: () => O(!1),
255
+ onClose: () => k(!1),
226
256
  onDone: () => {
227
- m(), G({
257
+ m(), q({
228
258
  tone: "success",
229
259
  text: "Deliverable added."
230
260
  });
231
261
  }
232
262
  }),
233
- P && /* @__PURE__ */ F(W, {
263
+ I && /* @__PURE__ */ L(K, {
234
264
  engagementId: n.id,
235
- onClose: () => z(!1),
265
+ onClose: () => V(!1),
236
266
  onDone: () => {
237
- m(), G({
267
+ m(), q({
238
268
  tone: "success",
239
269
  text: "Milestone added."
240
270
  });
@@ -242,9 +272,9 @@ var R = {
242
272
  })
243
273
  ]
244
274
  });
245
- }, V = ({ id: e, engagementId: t, status: n, onDone: r }) => {
275
+ }, U = ({ id: e, engagementId: t, status: n, onDone: r }) => {
246
276
  let i = a();
247
- return /* @__PURE__ */ F(h, {
277
+ return /* @__PURE__ */ L(h, {
248
278
  value: n,
249
279
  disabled: i.isPending,
250
280
  onChange: (n) => i.mutate({
@@ -252,15 +282,15 @@ var R = {
252
282
  status: n.target.value,
253
283
  engagementId: t
254
284
  }, { onSuccess: r }),
255
- className: "w-40",
256
- children: z.map((e) => /* @__PURE__ */ F("option", {
285
+ className: "w-40 shrink-0",
286
+ children: V.map((e) => /* @__PURE__ */ L("option", {
257
287
  value: e,
258
288
  children: w(e)
259
289
  }, e))
260
290
  });
261
- }, H = ({ id: t, engagementId: n, onDone: r }) => {
291
+ }, W = ({ id: t, engagementId: n, onDone: r }) => {
262
292
  let i = e();
263
- return /* @__PURE__ */ F(L, {
293
+ return /* @__PURE__ */ L(z, {
264
294
  variant: "ghost",
265
295
  size: "sm",
266
296
  "aria-label": "Complete milestone",
@@ -269,9 +299,9 @@ var R = {
269
299
  id: t,
270
300
  engagementId: n
271
301
  }, { onSuccess: r }),
272
- children: /* @__PURE__ */ F(O, { className: "h-4 w-4" })
302
+ children: /* @__PURE__ */ L(k, { className: "h-4 w-4" })
273
303
  });
274
- }, U = ({ engagementId: e, onClose: n, onDone: r }) => {
304
+ }, G = ({ engagementId: e, onClose: n, onDone: r }) => {
275
305
  let i = t(), [a, o] = E({
276
306
  name: "",
277
307
  description: "",
@@ -281,16 +311,16 @@ var R = {
281
311
  ...n,
282
312
  [e]: t.target.value
283
313
  }));
284
- return /* @__PURE__ */ F(m, {
314
+ return /* @__PURE__ */ L(m, {
285
315
  open: !0,
286
316
  onClose: n,
287
317
  title: "Add deliverable",
288
- footer: /* @__PURE__ */ I(P, { children: [/* @__PURE__ */ F(L, {
318
+ footer: /* @__PURE__ */ R(I, { children: [/* @__PURE__ */ L(z, {
289
319
  variant: "outline",
290
320
  onClick: n,
291
321
  disabled: i.isPending,
292
322
  children: "Cancel"
293
- }), /* @__PURE__ */ F(L, {
323
+ }), /* @__PURE__ */ L(z, {
294
324
  onClick: () => {
295
325
  if (l(null), !a.name.trim()) return l("Name is required.");
296
326
  i.mutate({
@@ -309,40 +339,40 @@ var R = {
309
339
  disabled: i.isPending,
310
340
  children: i.isPending ? "Adding…" : "Add"
311
341
  })] }),
312
- children: /* @__PURE__ */ I("div", {
342
+ children: /* @__PURE__ */ R("div", {
313
343
  className: "space-y-3",
314
344
  children: [
315
- s && /* @__PURE__ */ F(c, {
345
+ s && /* @__PURE__ */ L(c, {
316
346
  tone: "danger",
317
347
  children: s
318
348
  }),
319
- /* @__PURE__ */ F(d, {
349
+ /* @__PURE__ */ L(d, {
320
350
  label: "Name",
321
351
  required: !0,
322
- children: /* @__PURE__ */ F(b, {
352
+ children: /* @__PURE__ */ L(b, {
323
353
  value: a.name,
324
354
  onChange: u("name"),
325
355
  placeholder: "Draft audit report"
326
356
  })
327
357
  }),
328
- /* @__PURE__ */ F(d, {
358
+ /* @__PURE__ */ L(d, {
329
359
  label: "Due date",
330
- children: /* @__PURE__ */ F(b, {
360
+ children: /* @__PURE__ */ L(b, {
331
361
  type: "date",
332
362
  value: a.dueDate,
333
363
  onChange: u("dueDate")
334
364
  })
335
365
  }),
336
- /* @__PURE__ */ F(d, {
366
+ /* @__PURE__ */ L(d, {
337
367
  label: "Acceptance criteria",
338
- children: /* @__PURE__ */ F(y, {
368
+ children: /* @__PURE__ */ L(y, {
339
369
  value: a.acceptanceCriteria,
340
370
  onChange: u("acceptanceCriteria")
341
371
  })
342
372
  }),
343
- /* @__PURE__ */ F(d, {
373
+ /* @__PURE__ */ L(d, {
344
374
  label: "Description",
345
- children: /* @__PURE__ */ F(y, {
375
+ children: /* @__PURE__ */ L(y, {
346
376
  value: a.description,
347
377
  onChange: u("description")
348
378
  })
@@ -350,23 +380,23 @@ var R = {
350
380
  ]
351
381
  })
352
382
  });
353
- }, W = ({ engagementId: e, onClose: t, onDone: r }) => {
383
+ }, K = ({ engagementId: e, onClose: t, onDone: r }) => {
354
384
  let i = n(), [a, o] = E({
355
385
  name: "",
356
386
  dueDate: "",
357
387
  triggerAmount: "",
358
388
  triggersInvoice: !1
359
389
  }), [s, l] = E(null);
360
- return /* @__PURE__ */ F(m, {
390
+ return /* @__PURE__ */ L(m, {
361
391
  open: !0,
362
392
  onClose: t,
363
393
  title: "Add milestone",
364
- footer: /* @__PURE__ */ I(P, { children: [/* @__PURE__ */ F(L, {
394
+ footer: /* @__PURE__ */ R(I, { children: [/* @__PURE__ */ L(z, {
365
395
  variant: "outline",
366
396
  onClick: t,
367
397
  disabled: i.isPending,
368
398
  children: "Cancel"
369
- }), /* @__PURE__ */ F(L, {
399
+ }), /* @__PURE__ */ L(z, {
370
400
  onClick: () => {
371
401
  if (l(null), !a.name.trim()) return l("Name is required.");
372
402
  i.mutate({
@@ -385,17 +415,17 @@ var R = {
385
415
  disabled: i.isPending,
386
416
  children: i.isPending ? "Adding…" : "Add"
387
417
  })] }),
388
- children: /* @__PURE__ */ I("div", {
418
+ children: /* @__PURE__ */ R("div", {
389
419
  className: "space-y-3",
390
420
  children: [
391
- s && /* @__PURE__ */ F(c, {
421
+ s && /* @__PURE__ */ L(c, {
392
422
  tone: "danger",
393
423
  children: s
394
424
  }),
395
- /* @__PURE__ */ F(d, {
425
+ /* @__PURE__ */ L(d, {
396
426
  label: "Name",
397
427
  required: !0,
398
- children: /* @__PURE__ */ F(b, {
428
+ children: /* @__PURE__ */ L(b, {
399
429
  value: a.name,
400
430
  onChange: (e) => o((t) => ({
401
431
  ...t,
@@ -404,9 +434,9 @@ var R = {
404
434
  placeholder: "Phase 1 sign-off"
405
435
  })
406
436
  }),
407
- /* @__PURE__ */ F(d, {
437
+ /* @__PURE__ */ L(d, {
408
438
  label: "Due date",
409
- children: /* @__PURE__ */ F(b, {
439
+ children: /* @__PURE__ */ L(b, {
410
440
  type: "date",
411
441
  value: a.dueDate,
412
442
  onChange: (e) => o((t) => ({
@@ -415,10 +445,10 @@ var R = {
415
445
  }))
416
446
  })
417
447
  }),
418
- /* @__PURE__ */ F(d, {
448
+ /* @__PURE__ */ L(d, {
419
449
  label: "Trigger amount",
420
450
  hint: "Amount billed when this milestone completes (if it triggers an invoice).",
421
- children: /* @__PURE__ */ F(b, {
451
+ children: /* @__PURE__ */ L(b, {
422
452
  type: "number",
423
453
  min: "0",
424
454
  value: a.triggerAmount,
@@ -428,9 +458,9 @@ var R = {
428
458
  }))
429
459
  })
430
460
  }),
431
- /* @__PURE__ */ I("label", {
461
+ /* @__PURE__ */ R("label", {
432
462
  className: "flex items-center gap-2 text-sm text-text-secondary",
433
- children: [/* @__PURE__ */ F("input", {
463
+ children: [/* @__PURE__ */ L("input", {
434
464
  type: "checkbox",
435
465
  checked: a.triggersInvoice,
436
466
  onChange: (e) => o((t) => ({
@@ -444,6 +474,6 @@ var R = {
444
474
  });
445
475
  };
446
476
  //#endregion
447
- export { B as EngagementDetailPage };
477
+ export { H as EngagementDetailPage };
448
478
 
449
479
  //# sourceMappingURL=EngagementDetailPage.js.map