@burdenoff/microfe-proserviceworld 2026.1026.2 → 2026.1031.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (105) hide show
  1. package/dist/proserviceworld/components/CredentialDirectory.js +44 -43
  2. package/dist/proserviceworld/components/CredentialDirectory.js.map +1 -1
  3. package/dist/proserviceworld/components/CredentialReminderPanel.js +5 -4
  4. package/dist/proserviceworld/components/CredentialReminderPanel.js.map +1 -1
  5. package/dist/proserviceworld/components/ui.d.ts +7 -3
  6. package/dist/proserviceworld/components/ui.d.ts.map +1 -1
  7. package/dist/proserviceworld/components/ui.js +135 -121
  8. package/dist/proserviceworld/components/ui.js.map +1 -1
  9. package/dist/proserviceworld/hooks/useProServiceWorldApi.d.ts +28 -0
  10. package/dist/proserviceworld/hooks/useProServiceWorldApi.d.ts.map +1 -1
  11. package/dist/proserviceworld/hooks/useProServiceWorldApi.js +95 -73
  12. package/dist/proserviceworld/hooks/useProServiceWorldApi.js.map +1 -1
  13. package/dist/proserviceworld/hooks/useTr.d.ts +49 -8
  14. package/dist/proserviceworld/hooks/useTr.d.ts.map +1 -1
  15. package/dist/proserviceworld/hooks/useTr.js +45 -21
  16. package/dist/proserviceworld/hooks/useTr.js.map +1 -1
  17. package/dist/proserviceworld/i18n/catalog/analytics.d.ts +5 -0
  18. package/dist/proserviceworld/i18n/catalog/analytics.d.ts.map +1 -0
  19. package/dist/proserviceworld/i18n/catalog/analytics.js +271 -0
  20. package/dist/proserviceworld/i18n/catalog/analytics.js.map +1 -0
  21. package/dist/proserviceworld/i18n/catalog/common.d.ts +9 -0
  22. package/dist/proserviceworld/i18n/catalog/common.d.ts.map +1 -0
  23. package/dist/proserviceworld/i18n/catalog/common.js +163 -0
  24. package/dist/proserviceworld/i18n/catalog/common.js.map +1 -0
  25. package/dist/proserviceworld/i18n/catalog/compliance.d.ts +5 -0
  26. package/dist/proserviceworld/i18n/catalog/compliance.d.ts.map +1 -0
  27. package/dist/proserviceworld/i18n/catalog/compliance.js +157 -0
  28. package/dist/proserviceworld/i18n/catalog/compliance.js.map +1 -0
  29. package/dist/proserviceworld/i18n/catalog/conflicts.d.ts +5 -0
  30. package/dist/proserviceworld/i18n/catalog/conflicts.d.ts.map +1 -0
  31. package/dist/proserviceworld/i18n/catalog/conflicts.js +145 -0
  32. package/dist/proserviceworld/i18n/catalog/conflicts.js.map +1 -0
  33. package/dist/proserviceworld/i18n/catalog/documents.d.ts +5 -0
  34. package/dist/proserviceworld/i18n/catalog/documents.d.ts.map +1 -0
  35. package/dist/proserviceworld/i18n/catalog/documents.js +157 -0
  36. package/dist/proserviceworld/i18n/catalog/documents.js.map +1 -0
  37. package/dist/proserviceworld/i18n/catalog/enums.d.ts +10 -0
  38. package/dist/proserviceworld/i18n/catalog/enums.d.ts.map +1 -0
  39. package/dist/proserviceworld/i18n/catalog/enums.js +481 -0
  40. package/dist/proserviceworld/i18n/catalog/enums.js.map +1 -0
  41. package/dist/proserviceworld/i18n/catalog/index.d.ts +9 -0
  42. package/dist/proserviceworld/i18n/catalog/index.d.ts.map +1 -0
  43. package/dist/proserviceworld/i18n/catalog/index.js +25 -0
  44. package/dist/proserviceworld/i18n/catalog/index.js.map +1 -0
  45. package/dist/proserviceworld/i18n/catalog/invoices.d.ts +5 -0
  46. package/dist/proserviceworld/i18n/catalog/invoices.d.ts.map +1 -0
  47. package/dist/proserviceworld/i18n/catalog/invoices.js +247 -0
  48. package/dist/proserviceworld/i18n/catalog/invoices.js.map +1 -0
  49. package/dist/proserviceworld/i18n/catalog/practiceAreas.d.ts +5 -0
  50. package/dist/proserviceworld/i18n/catalog/practiceAreas.d.ts.map +1 -0
  51. package/dist/proserviceworld/i18n/catalog/practiceAreas.js +97 -0
  52. package/dist/proserviceworld/i18n/catalog/practiceAreas.js.map +1 -0
  53. package/dist/proserviceworld/i18n/catalog/time.d.ts +5 -0
  54. package/dist/proserviceworld/i18n/catalog/time.d.ts.map +1 -0
  55. package/dist/proserviceworld/i18n/catalog/time.js +301 -0
  56. package/dist/proserviceworld/i18n/catalog/time.js.map +1 -0
  57. package/dist/proserviceworld/i18n/index.d.ts +10 -9
  58. package/dist/proserviceworld/i18n/index.d.ts.map +1 -1
  59. package/dist/proserviceworld/i18n/index.js +16 -12
  60. package/dist/proserviceworld/i18n/index.js.map +1 -1
  61. package/dist/proserviceworld/i18n/types.d.ts +13 -0
  62. package/dist/proserviceworld/i18n/types.d.ts.map +1 -0
  63. package/dist/proserviceworld/i18n/types.js +18 -0
  64. package/dist/proserviceworld/i18n/types.js.map +1 -0
  65. package/dist/proserviceworld/pages/AnalyticsPage.d.ts.map +1 -1
  66. package/dist/proserviceworld/pages/AnalyticsPage.js +236 -152
  67. package/dist/proserviceworld/pages/AnalyticsPage.js.map +1 -1
  68. package/dist/proserviceworld/pages/ClientDetailPage.js +99 -98
  69. package/dist/proserviceworld/pages/ClientDetailPage.js.map +1 -1
  70. package/dist/proserviceworld/pages/ClientsPage.d.ts.map +1 -1
  71. package/dist/proserviceworld/pages/ClientsPage.js +181 -181
  72. package/dist/proserviceworld/pages/ClientsPage.js.map +1 -1
  73. package/dist/proserviceworld/pages/CompliancePage.d.ts.map +1 -1
  74. package/dist/proserviceworld/pages/CompliancePage.js +210 -209
  75. package/dist/proserviceworld/pages/CompliancePage.js.map +1 -1
  76. package/dist/proserviceworld/pages/ConflictsPage.d.ts.map +1 -1
  77. package/dist/proserviceworld/pages/ConflictsPage.js +139 -138
  78. package/dist/proserviceworld/pages/ConflictsPage.js.map +1 -1
  79. package/dist/proserviceworld/pages/DocumentsPage.d.ts.map +1 -1
  80. package/dist/proserviceworld/pages/DocumentsPage.js +150 -149
  81. package/dist/proserviceworld/pages/DocumentsPage.js.map +1 -1
  82. package/dist/proserviceworld/pages/EngagementDetailPage.js +105 -104
  83. package/dist/proserviceworld/pages/EngagementDetailPage.js.map +1 -1
  84. package/dist/proserviceworld/pages/EngagementsPage.d.ts.map +1 -1
  85. package/dist/proserviceworld/pages/EngagementsPage.js +137 -137
  86. package/dist/proserviceworld/pages/EngagementsPage.js.map +1 -1
  87. package/dist/proserviceworld/pages/InvoicesPage.d.ts.map +1 -1
  88. package/dist/proserviceworld/pages/InvoicesPage.js +275 -258
  89. package/dist/proserviceworld/pages/InvoicesPage.js.map +1 -1
  90. package/dist/proserviceworld/pages/MattersPage.d.ts.map +1 -1
  91. package/dist/proserviceworld/pages/MattersPage.js +166 -166
  92. package/dist/proserviceworld/pages/MattersPage.js.map +1 -1
  93. package/dist/proserviceworld/pages/PracticeAreasPage.d.ts.map +1 -1
  94. package/dist/proserviceworld/pages/PracticeAreasPage.js +100 -99
  95. package/dist/proserviceworld/pages/PracticeAreasPage.js.map +1 -1
  96. package/dist/proserviceworld/pages/PractitionerCredentialsPage.js +30 -29
  97. package/dist/proserviceworld/pages/PractitionerCredentialsPage.js.map +1 -1
  98. package/dist/proserviceworld/pages/TimePage.d.ts.map +1 -1
  99. package/dist/proserviceworld/pages/TimePage.js +343 -350
  100. package/dist/proserviceworld/pages/TimePage.js.map +1 -1
  101. package/dist/proserviceworld/utils/humanize.d.ts +3 -0
  102. package/dist/proserviceworld/utils/humanize.d.ts.map +1 -0
  103. package/dist/proserviceworld/utils/humanize.js +6 -0
  104. package/dist/proserviceworld/utils/humanize.js.map +1 -0
  105. package/package.json +1 -1
@@ -1,7 +1,8 @@
1
1
  import { useProServiceWorld as e } from "../providers/ProServiceWorldProvider.js";
2
2
  import { useAddTeamAssignment as t, useCompleteMilestone as n, useCreateDeliverable as r, useCreateMilestone as i, useEngagement as a, usePracticeAreas as o, useRemoveTeamAssignment as s, useTeamAssignments as c, useTimeEntries as l, useTransitionDeliverable as u, useTransitionEngagement as d } from "../hooks/useProServiceWorldApi.js";
3
3
  import { useNav as f } from "../utils/nav.js";
4
- import { Banner as p, Empty as m, ErrorState as h, Field as g, LoadingBlock as _, MetricCard as v, Modal as y, NativeSelect as b, PageHeader as x, SectionCard as S, StatusPill as C, TableWrap as w, Td as T, TextArea as E, TextInput as D, Th as O, enumOptions as k, fmtDate as A, fmtMinutesAsHours as j, fmtMoney as M, humanize as N } from "../components/ui.js";
4
+ import { humanize as p } from "../utils/humanize.js";
5
+ import { Banner as m, Empty as h, ErrorState as g, Field as _, LoadingBlock as v, MetricCard as y, Modal as b, NativeSelect as x, PageHeader as S, SectionCard as C, StatusPill as w, TableWrap as T, Td as E, TextArea as D, TextInput as O, Th as k, enumOptions as A, fmtDate as j, fmtMinutesAsHours as M, fmtMoney as N } from "../components/ui.js";
5
6
  import { useActorNames as ee } from "../hooks/useActorNames.js";
6
7
  import { DiscussionThread as te } from "../components/DiscussionThread.js";
7
8
  import { useAnalytics as ne } from "../hooks/useAnalytics.js";
@@ -38,17 +39,17 @@ var ce = {
38
39
  "SPECIALIST",
39
40
  "SUPPORT"
40
41
  ], J = () => {
41
- let { id: e = "" } = se(), t = f(), { emitFact: n } = ne(), { data: r, isLoading: i, error: s, refetch: u } = a(e), g = l({ engagementId: e }), y = o(), b = c({ engagementId: e }), T = d(), [E, D] = P(!1), [k, F] = P(!1), [B, V] = P(!1), [G, K] = P(null), q = ee([r?.responsiblePartnerId, ...(b.data?.items ?? []).map((e) => e.practitionerId)]);
42
- if (i) return /* @__PURE__ */ H(_, {});
43
- if (s) return /* @__PURE__ */ H(h, {
42
+ let { id: e = "" } = se(), t = f(), { emitFact: n } = ne(), { data: r, isLoading: i, error: s, refetch: u } = a(e), _ = l({ engagementId: e }), b = o(), x = c({ engagementId: e }), E = d(), [D, O] = P(!1), [A, F] = P(!1), [B, V] = P(!1), [G, K] = P(null), q = ee([r?.responsiblePartnerId, ...(x.data?.items ?? []).map((e) => e.practitionerId)]);
43
+ if (i) return /* @__PURE__ */ H(v, {});
44
+ if (s) return /* @__PURE__ */ H(g, {
44
45
  error: s,
45
46
  onRetry: () => void u()
46
47
  });
47
- if (!r) return /* @__PURE__ */ H(m, { title: "Engagement not found" });
48
- let J = ce[r.status] ?? [], Y = g.data?.items ?? [], X = Y.length, Z = g.data?.totalCount ?? X, Q = X < Z ? ` · first ${X} of ${Z} entries` : "", $ = Y.reduce((e, t) => e + t.minutes, 0), he = Y.filter((e) => e.billable && e.status !== "BILLED").reduce((e, t) => e + t.minutes, 0), ge = Y.filter((e) => e.status === "BILLED").reduce((e, t) => e + t.minutes, 0), _e = r.milestones.filter((e) => e.status === "COMPLETED").length, ve = r.deliverables.filter((e) => e.status === "CLIENT_REVIEW").length, ye = y.data?.items.find((e) => e.id === r.practiceAreaId)?.name ?? null, be = [
48
+ if (!r) return /* @__PURE__ */ H(h, { title: "Engagement not found" });
49
+ let J = ce[r.status] ?? [], Y = _.data?.items ?? [], X = Y.length, Z = _.data?.totalCount ?? X, Q = X < Z ? ` · first ${X} of ${Z} entries` : "", $ = Y.reduce((e, t) => e + t.minutes, 0), he = Y.filter((e) => e.billable && e.status !== "BILLED").reduce((e, t) => e + t.minutes, 0), ge = Y.filter((e) => e.status === "BILLED").reduce((e, t) => e + t.minutes, 0), _e = r.milestones.filter((e) => e.status === "COMPLETED").length, ve = r.deliverables.filter((e) => e.status === "CLIENT_REVIEW").length, ye = b.data?.items.find((e) => e.id === r.practiceAreaId)?.name ?? null, be = [
49
50
  r.client?.name,
50
51
  ye,
51
- N(r.feeArrangement),
52
+ p(r.feeArrangement),
52
53
  r.responsiblePartnerId ? `Partner: ${q.nameOf(r.responsiblePartnerId)}` : null
53
54
  ].filter(Boolean).join(" · ");
54
55
  return /* @__PURE__ */ U("div", {
@@ -60,12 +61,12 @@ var ce = {
60
61
  className: "flex items-center gap-1.5 text-sm text-text-secondary transition-colors hover:text-accent",
61
62
  children: [/* @__PURE__ */ H(re, { className: "h-4 w-4" }), " Back to engagements"]
62
63
  }),
63
- /* @__PURE__ */ H(x, {
64
+ /* @__PURE__ */ H(S, {
64
65
  title: r.name,
65
66
  subtitle: be,
66
- actions: /* @__PURE__ */ H(C, { status: r.status })
67
+ actions: /* @__PURE__ */ H(w, { status: r.status })
67
68
  }),
68
- G && /* @__PURE__ */ H(p, {
69
+ G && /* @__PURE__ */ H(m, {
69
70
  tone: G.tone,
70
71
  onClose: () => K(null),
71
72
  children: G.text
@@ -73,43 +74,43 @@ var ce = {
73
74
  /* @__PURE__ */ U("div", {
74
75
  className: "grid grid-cols-2 gap-3 lg:grid-cols-4",
75
76
  children: [
76
- /* @__PURE__ */ H(v, {
77
+ /* @__PURE__ */ H(y, {
77
78
  label: "Fee",
78
- value: M(r.feeAmount, r.currency),
79
- hint: N(r.feeArrangement),
79
+ value: N(r.feeAmount, r.currency),
80
+ hint: p(r.feeArrangement),
80
81
  icon: /* @__PURE__ */ H(ae, { className: "h-4 w-4" }),
81
82
  tone: "success"
82
83
  }),
83
- /* @__PURE__ */ H(v, {
84
+ /* @__PURE__ */ H(y, {
84
85
  label: "Deliverables",
85
86
  value: r.deliverables.length,
86
87
  hint: `${ve} in client review`,
87
88
  icon: /* @__PURE__ */ H(L, { className: "h-4 w-4" }),
88
89
  tone: "info"
89
90
  }),
90
- /* @__PURE__ */ H(v, {
91
+ /* @__PURE__ */ H(y, {
91
92
  label: "Milestones",
92
93
  value: `${_e} of ${r.milestones.length}`,
93
94
  hint: "Completed",
94
95
  icon: /* @__PURE__ */ H(R, { className: "h-4 w-4" }),
95
96
  tone: "accent"
96
97
  }),
97
- /* @__PURE__ */ H(v, {
98
+ /* @__PURE__ */ H(y, {
98
99
  label: "Unbilled hours",
99
- value: j(he),
100
- hint: `${j(ge)} billed · ${j($)} logged${Q}`,
100
+ value: M(he),
101
+ hint: `${M(ge)} billed · ${M($)} logged${Q}`,
101
102
  icon: /* @__PURE__ */ H(I, { className: "h-4 w-4" }),
102
103
  tone: "warning"
103
104
  })
104
105
  ]
105
106
  }),
106
- J.length > 0 && /* @__PURE__ */ H(S, {
107
+ J.length > 0 && /* @__PURE__ */ H(C, {
107
108
  title: "Advance lifecycle",
108
109
  children: /* @__PURE__ */ U("div", {
109
110
  className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between",
110
111
  children: [/* @__PURE__ */ U("div", {
111
112
  className: "flex items-center gap-2 text-sm text-text-secondary",
112
- children: [/* @__PURE__ */ H("span", { children: "Currently" }), /* @__PURE__ */ H(C, { status: r.status })]
113
+ children: [/* @__PURE__ */ H("span", { children: "Currently" }), /* @__PURE__ */ H(w, { status: r.status })]
113
114
  }), /* @__PURE__ */ H("div", {
114
115
  className: "flex flex-wrap gap-2",
115
116
  children: J.map((e) => {
@@ -117,8 +118,8 @@ var ce = {
117
118
  return /* @__PURE__ */ U(W, {
118
119
  size: "sm",
119
120
  variant: t ? "outline" : "default",
120
- disabled: T.isPending,
121
- onClick: () => T.mutate({
121
+ disabled: E.isPending,
122
+ onClick: () => E.mutate({
122
123
  id: r.id,
123
124
  status: e
124
125
  }, {
@@ -128,7 +129,7 @@ var ce = {
128
129
  status: e
129
130
  }), K({
130
131
  tone: "success",
131
- text: `Moved to ${N(e)}.`
132
+ text: `Moved to ${p(e)}.`
132
133
  });
133
134
  },
134
135
  onError: (e) => K({
@@ -136,7 +137,7 @@ var ce = {
136
137
  text: e instanceof Error ? e.message : "Transition failed."
137
138
  })
138
139
  }),
139
- children: [N(e), !t && /* @__PURE__ */ H(ie, { className: "ml-1.5 h-4 w-4" })]
140
+ children: [p(e), !t && /* @__PURE__ */ H(ie, { className: "ml-1.5 h-4 w-4" })]
140
141
  }, e);
141
142
  })
142
143
  })]
@@ -144,15 +145,15 @@ var ce = {
144
145
  }),
145
146
  /* @__PURE__ */ U("div", {
146
147
  className: "grid grid-cols-1 gap-4 lg:grid-cols-2",
147
- children: [/* @__PURE__ */ H(S, {
148
+ children: [/* @__PURE__ */ H(C, {
148
149
  title: "Deliverables",
149
150
  action: /* @__PURE__ */ U(W, {
150
151
  size: "sm",
151
152
  variant: "outline",
152
- onClick: () => D(!0),
153
+ onClick: () => O(!0),
153
154
  children: [/* @__PURE__ */ H(z, { className: "mr-1.5 h-4 w-4" }), "Add"]
154
155
  }),
155
- children: r.deliverables.length === 0 ? /* @__PURE__ */ H(m, {
156
+ children: r.deliverables.length === 0 ? /* @__PURE__ */ H(h, {
156
157
  title: "No deliverables",
157
158
  description: "Track the tangible outputs of this engagement.",
158
159
  icon: /* @__PURE__ */ H(L, { className: "h-7 w-7" })
@@ -175,7 +176,7 @@ var ce = {
175
176
  })]
176
177
  }), e.dueDate && /* @__PURE__ */ U("div", {
177
178
  className: "mt-0.5 text-xs text-text-tertiary",
178
- children: ["Due ", A(e.dueDate)]
179
+ children: ["Due ", j(e.dueDate)]
179
180
  })]
180
181
  }), /* @__PURE__ */ H(de, {
181
182
  id: e.id,
@@ -186,7 +187,7 @@ var ce = {
186
187
  })
187
188
  }, e.id))
188
189
  })
189
- }), /* @__PURE__ */ H(S, {
190
+ }), /* @__PURE__ */ H(C, {
190
191
  title: "Milestones",
191
192
  action: /* @__PURE__ */ U(W, {
192
193
  size: "sm",
@@ -194,7 +195,7 @@ var ce = {
194
195
  onClick: () => F(!0),
195
196
  children: [/* @__PURE__ */ H(z, { className: "mr-1.5 h-4 w-4" }), "Add"]
196
197
  }),
197
- children: r.milestones.length === 0 ? /* @__PURE__ */ H(m, {
198
+ children: r.milestones.length === 0 ? /* @__PURE__ */ H(h, {
198
199
  title: "No milestones",
199
200
  description: "Add checkpoints — some can trigger billing.",
200
201
  icon: /* @__PURE__ */ H(R, { className: "h-7 w-7" })
@@ -210,14 +211,14 @@ var ce = {
210
211
  }), /* @__PURE__ */ U("div", {
211
212
  className: "mt-0.5 text-xs text-text-tertiary",
212
213
  children: [
213
- e.triggersInvoice ? `Bills ${M(e.triggerAmount, r.currency)} · ` : "",
214
+ e.triggersInvoice ? `Bills ${N(e.triggerAmount, r.currency)} · ` : "",
214
215
  "Due ",
215
- A(e.dueDate)
216
+ j(e.dueDate)
216
217
  ]
217
218
  })]
218
219
  }), /* @__PURE__ */ U("div", {
219
220
  className: "flex shrink-0 items-center gap-2",
220
- children: [/* @__PURE__ */ H(C, { status: e.status }), e.status !== "COMPLETED" && e.status !== "CANCELLED" && /* @__PURE__ */ H(fe, {
221
+ children: [/* @__PURE__ */ H(w, { status: e.status }), e.status !== "COMPLETED" && e.status !== "CANCELLED" && /* @__PURE__ */ H(fe, {
221
222
  id: e.id,
222
223
  engagementId: r.id,
223
224
  onDone: () => void u()
@@ -227,37 +228,37 @@ var ce = {
227
228
  })
228
229
  })]
229
230
  }),
230
- /* @__PURE__ */ H(S, {
231
+ /* @__PURE__ */ H(C, {
231
232
  title: "Team",
232
- description: `${b.data?.totalCount ?? 0} staffed on this engagement`,
233
+ description: `${x.data?.totalCount ?? 0} staffed on this engagement`,
233
234
  action: /* @__PURE__ */ U(W, {
234
235
  size: "sm",
235
236
  variant: "outline",
236
237
  onClick: () => V(!0),
237
238
  children: [/* @__PURE__ */ H(z, { className: "mr-1.5 h-4 w-4" }), "Assign"]
238
239
  }),
239
- children: b.isLoading ? /* @__PURE__ */ H(_, { label: "Loading…" }) : b.error ? /* @__PURE__ */ H(h, {
240
- error: b.error,
241
- onRetry: () => void b.refetch()
242
- }) : !b.data || b.data.items.length === 0 ? /* @__PURE__ */ H(m, {
240
+ children: x.isLoading ? /* @__PURE__ */ H(v, { label: "Loading…" }) : x.error ? /* @__PURE__ */ H(g, {
241
+ error: x.error,
242
+ onRetry: () => void x.refetch()
243
+ }) : !x.data || x.data.items.length === 0 ? /* @__PURE__ */ H(h, {
243
244
  title: "No one assigned",
244
245
  description: "Staff the practitioners delivering this engagement, with their role and billing rate.",
245
246
  icon: /* @__PURE__ */ H(oe, { className: "h-7 w-7" })
246
- }) : /* @__PURE__ */ U(w, { children: [/* @__PURE__ */ H("thead", { children: /* @__PURE__ */ U("tr", { children: [
247
- /* @__PURE__ */ H(O, { children: "Practitioner" }),
248
- /* @__PURE__ */ H(O, { children: "Role" }),
249
- /* @__PURE__ */ H(O, { children: "Allocation" }),
250
- /* @__PURE__ */ H(O, { children: "Billing rate" }),
251
- /* @__PURE__ */ H(O, {
247
+ }) : /* @__PURE__ */ U(T, { children: [/* @__PURE__ */ H("thead", { children: /* @__PURE__ */ U("tr", { children: [
248
+ /* @__PURE__ */ H(k, { children: "Practitioner" }),
249
+ /* @__PURE__ */ H(k, { children: "Role" }),
250
+ /* @__PURE__ */ H(k, { children: "Allocation" }),
251
+ /* @__PURE__ */ H(k, { children: "Billing rate" }),
252
+ /* @__PURE__ */ H(k, {
252
253
  className: "text-right",
253
254
  children: "Actions"
254
255
  })
255
- ] }) }), /* @__PURE__ */ H("tbody", { children: b.data.items.map((e) => /* @__PURE__ */ H(le, {
256
+ ] }) }), /* @__PURE__ */ H("tbody", { children: x.data.items.map((e) => /* @__PURE__ */ H(le, {
256
257
  assignment: e,
257
258
  currency: r.currency,
258
259
  actors: q,
259
260
  onRemoved: (e) => {
260
- b.refetch(), K(e ? {
261
+ x.refetch(), K(e ? {
261
262
  tone: "success",
262
263
  text: "Team assignment removed."
263
264
  } : {
@@ -275,34 +276,34 @@ var ce = {
275
276
  entityType: "proserviceworld-engagement",
276
277
  entityId: r.id
277
278
  })
278
- }), /* @__PURE__ */ H(S, {
279
+ }), /* @__PURE__ */ H(C, {
279
280
  title: "Time logged",
280
- description: `${j($)}${Q}`,
281
+ description: `${M($)}${Q}`,
281
282
  action: /* @__PURE__ */ U(W, {
282
283
  size: "sm",
283
284
  variant: "outline",
284
285
  onClick: () => t("time"),
285
286
  children: [/* @__PURE__ */ H(I, { className: "mr-1.5 h-4 w-4" }), "Log time"]
286
287
  }),
287
- children: g.isLoading ? /* @__PURE__ */ H(_, { label: "Loading…" }) : !g.data || g.data.items.length === 0 ? /* @__PURE__ */ H(m, {
288
+ children: _.isLoading ? /* @__PURE__ */ H(v, { label: "Loading…" }) : !_.data || _.data.items.length === 0 ? /* @__PURE__ */ H(h, {
288
289
  title: "No time logged",
289
290
  description: "Time logged against this engagement will appear here.",
290
291
  icon: /* @__PURE__ */ H(I, { className: "h-7 w-7" })
291
292
  }) : /* @__PURE__ */ H("ul", {
292
293
  className: "space-y-2",
293
- children: g.data.items.slice(0, 8).map((e) => /* @__PURE__ */ U("li", {
294
+ children: _.data.items.slice(0, 8).map((e) => /* @__PURE__ */ U("li", {
294
295
  className: "rounded-lg border border-border-seam bg-bg-canvas p-3 text-sm",
295
296
  children: [/* @__PURE__ */ U("div", {
296
297
  className: "flex items-center justify-between gap-2",
297
298
  children: [/* @__PURE__ */ H("span", {
298
299
  className: "whitespace-nowrap text-xs text-text-tertiary",
299
- children: A(e.date)
300
+ children: j(e.date)
300
301
  }), /* @__PURE__ */ U("span", {
301
302
  className: "flex items-center gap-2",
302
303
  children: [/* @__PURE__ */ H("span", {
303
304
  className: "font-medium text-text-primary",
304
- children: j(e.minutes)
305
- }), /* @__PURE__ */ H(C, { status: e.status })]
305
+ children: M(e.minutes)
306
+ }), /* @__PURE__ */ H(w, { status: e.status })]
306
307
  })]
307
308
  }), /* @__PURE__ */ H("div", {
308
309
  className: "mt-1 truncate text-text-secondary",
@@ -317,15 +318,15 @@ var ce = {
317
318
  currency: r.currency,
318
319
  onClose: () => V(!1),
319
320
  onDone: () => {
320
- b.refetch(), K({
321
+ x.refetch(), K({
321
322
  tone: "success",
322
323
  text: "Practitioner assigned."
323
324
  });
324
325
  }
325
326
  }),
326
- E && /* @__PURE__ */ H(pe, {
327
+ D && /* @__PURE__ */ H(pe, {
327
328
  engagementId: r.id,
328
- onClose: () => D(!1),
329
+ onClose: () => O(!1),
329
330
  onDone: () => {
330
331
  u(), K({
331
332
  tone: "success",
@@ -333,7 +334,7 @@ var ce = {
333
334
  });
334
335
  }
335
336
  }),
336
- k && /* @__PURE__ */ H(me, {
337
+ A && /* @__PURE__ */ H(me, {
337
338
  engagementId: r.id,
338
339
  onClose: () => F(!1),
339
340
  onDone: () => {
@@ -350,7 +351,7 @@ var ce = {
350
351
  return /* @__PURE__ */ U("tr", {
351
352
  className: "transition-colors hover:bg-bg-sunken/60",
352
353
  children: [
353
- /* @__PURE__ */ U(T, { children: [/* @__PURE__ */ U("div", {
354
+ /* @__PURE__ */ U(E, { children: [/* @__PURE__ */ U("div", {
354
355
  className: "flex items-center gap-2",
355
356
  children: [/* @__PURE__ */ H("span", {
356
357
  className: "font-medium text-text-primary",
@@ -363,17 +364,17 @@ var ce = {
363
364
  className: "text-xs text-text-tertiary",
364
365
  children: o
365
366
  }) : null] }),
366
- /* @__PURE__ */ H(T, {
367
+ /* @__PURE__ */ H(E, {
367
368
  className: "whitespace-nowrap",
368
- children: N(e.role)
369
+ children: p(e.role)
369
370
  }),
370
- /* @__PURE__ */ U(T, {
371
+ /* @__PURE__ */ U(E, {
371
372
  className: "whitespace-nowrap",
372
373
  children: [e.allocationPct, "%"]
373
374
  }),
374
- /* @__PURE__ */ H(T, {
375
+ /* @__PURE__ */ H(E, {
375
376
  className: "whitespace-nowrap",
376
- children: e.billingRate > 0 ? /* @__PURE__ */ U(V, { children: [M(e.billingRate, t), /* @__PURE__ */ H("span", {
377
+ children: e.billingRate > 0 ? /* @__PURE__ */ U(V, { children: [N(e.billingRate, t), /* @__PURE__ */ H("span", {
377
378
  className: "text-xs text-text-tertiary",
378
379
  children: " / hr"
379
380
  })] }) : /* @__PURE__ */ H("span", {
@@ -381,7 +382,7 @@ var ce = {
381
382
  children: "—"
382
383
  })
383
384
  }),
384
- /* @__PURE__ */ H(T, {
385
+ /* @__PURE__ */ H(E, {
385
386
  className: "text-right",
386
387
  children: /* @__PURE__ */ H(W, {
387
388
  variant: "ghost",
@@ -400,17 +401,17 @@ var ce = {
400
401
  ]
401
402
  });
402
403
  }, ue = ({ engagementId: n, currency: r, onClose: i, onDone: a }) => {
403
- let { workspaceId: o } = e(), s = G({ workspaceId: o ?? "" }), c = t(), [l, u] = P(""), [d, f] = P("ASSOCIATE"), [m, h] = P(!1), [_, v] = P("100"), [x, S] = P(""), [C, w] = P(null), T = () => {
404
+ let { workspaceId: o } = e(), s = G({ workspaceId: o ?? "" }), c = t(), [l, u] = P(""), [d, f] = P("ASSOCIATE"), [p, h] = P(!1), [g, v] = P("100"), [y, S] = P(""), [C, w] = P(null), T = () => {
404
405
  if (w(null), !l) return w("Choose a practitioner to assign.");
405
- let e = Number(_);
406
+ let e = Number(g);
406
407
  if (!Number.isFinite(e) || e < 1 || e > 100) return w("Allocation must be between 1 and 100.");
407
- let t = x.trim() ? Number(x) : 0;
408
+ let t = y.trim() ? Number(y) : 0;
408
409
  if (!Number.isFinite(t) || t < 0) return w("Billing rate must be a positive number.");
409
410
  c.mutate({
410
411
  engagementId: n,
411
412
  practitionerId: l,
412
413
  role: d,
413
- isLead: m,
414
+ isLead: p,
414
415
  allocationPct: Math.round(e),
415
416
  billingRate: t
416
417
  }, {
@@ -420,7 +421,7 @@ var ce = {
420
421
  onError: (e) => w(e instanceof Error ? e.message : "Could not assign.")
421
422
  });
422
423
  }, E = !s.loading && s.members.length === 0;
423
- return /* @__PURE__ */ H(y, {
424
+ return /* @__PURE__ */ H(b, {
424
425
  open: !0,
425
426
  onClose: i,
426
427
  title: "Assign practitioner",
@@ -437,18 +438,18 @@ var ce = {
437
438
  children: /* @__PURE__ */ U("div", {
438
439
  className: "space-y-3",
439
440
  children: [
440
- C && /* @__PURE__ */ H(p, {
441
+ C && /* @__PURE__ */ H(m, {
441
442
  tone: "danger",
442
443
  children: C
443
444
  }),
444
- E && /* @__PURE__ */ H(p, {
445
+ E && /* @__PURE__ */ H(m, {
445
446
  tone: "danger",
446
447
  children: "The workspace member directory could not be read, so there is nobody to assign here."
447
448
  }),
448
- /* @__PURE__ */ H(g, {
449
+ /* @__PURE__ */ H(_, {
449
450
  label: "Practitioner",
450
451
  required: !0,
451
- children: /* @__PURE__ */ U(b, {
452
+ children: /* @__PURE__ */ U(x, {
452
453
  value: l,
453
454
  onChange: (e) => u(e.target.value),
454
455
  disabled: s.loading || E,
@@ -470,32 +471,32 @@ var ce = {
470
471
  }),
471
472
  /* @__PURE__ */ U("div", {
472
473
  className: "grid grid-cols-1 gap-3 sm:grid-cols-2",
473
- children: [/* @__PURE__ */ H(g, {
474
+ children: [/* @__PURE__ */ H(_, {
474
475
  label: "Role",
475
- children: /* @__PURE__ */ H(b, {
476
+ children: /* @__PURE__ */ H(x, {
476
477
  value: d,
477
478
  onChange: (e) => f(e.target.value),
478
- children: k(q)
479
+ children: A(q)
479
480
  })
480
- }), /* @__PURE__ */ H(g, {
481
+ }), /* @__PURE__ */ H(_, {
481
482
  label: "Allocation %",
482
483
  hint: "Share of this person's time on the engagement.",
483
- children: /* @__PURE__ */ H(D, {
484
+ children: /* @__PURE__ */ H(O, {
484
485
  type: "number",
485
486
  min: 1,
486
487
  max: 100,
487
- value: _,
488
+ value: g,
488
489
  onChange: (e) => v(e.target.value)
489
490
  })
490
491
  })]
491
492
  }),
492
- /* @__PURE__ */ H(g, {
493
+ /* @__PURE__ */ H(_, {
493
494
  label: `Billing rate (${r} / hr)`,
494
495
  hint: "Leave blank for a non-billed seat.",
495
- children: /* @__PURE__ */ H(D, {
496
+ children: /* @__PURE__ */ H(O, {
496
497
  type: "number",
497
498
  min: 0,
498
- value: x,
499
+ value: y,
499
500
  onChange: (e) => S(e.target.value),
500
501
  placeholder: "0"
501
502
  })
@@ -504,7 +505,7 @@ var ce = {
504
505
  className: "flex items-center gap-2 text-sm text-text-secondary",
505
506
  children: [/* @__PURE__ */ H("input", {
506
507
  type: "checkbox",
507
- checked: m,
508
+ checked: p,
508
509
  onChange: (e) => h(e.target.checked),
509
510
  className: "h-4 w-4 rounded border-border-seam accent-accent"
510
511
  }), "Engagement lead"]
@@ -514,7 +515,7 @@ var ce = {
514
515
  });
515
516
  }, de = ({ id: e, engagementId: t, status: n, onDone: r }) => {
516
517
  let i = u();
517
- return /* @__PURE__ */ H(b, {
518
+ return /* @__PURE__ */ H(x, {
518
519
  value: n,
519
520
  disabled: i.isPending,
520
521
  onChange: (n) => i.mutate({
@@ -525,7 +526,7 @@ var ce = {
525
526
  className: "w-40 shrink-0",
526
527
  children: K.map((e) => /* @__PURE__ */ H("option", {
527
528
  value: e,
528
- children: N(e)
529
+ children: p(e)
529
530
  }, e))
530
531
  });
531
532
  }, fe = ({ id: e, engagementId: t, onDone: r }) => {
@@ -551,7 +552,7 @@ var ce = {
551
552
  ...n,
552
553
  [e]: t.target.value
553
554
  }));
554
- return /* @__PURE__ */ H(y, {
555
+ return /* @__PURE__ */ H(b, {
555
556
  open: !0,
556
557
  onClose: t,
557
558
  title: "Add deliverable",
@@ -582,37 +583,37 @@ var ce = {
582
583
  children: /* @__PURE__ */ U("div", {
583
584
  className: "space-y-3",
584
585
  children: [
585
- s && /* @__PURE__ */ H(p, {
586
+ s && /* @__PURE__ */ H(m, {
586
587
  tone: "danger",
587
588
  children: s
588
589
  }),
589
- /* @__PURE__ */ H(g, {
590
+ /* @__PURE__ */ H(_, {
590
591
  label: "Name",
591
592
  required: !0,
592
- children: /* @__PURE__ */ H(D, {
593
+ children: /* @__PURE__ */ H(O, {
593
594
  value: a.name,
594
595
  onChange: l("name"),
595
596
  placeholder: "Draft audit report"
596
597
  })
597
598
  }),
598
- /* @__PURE__ */ H(g, {
599
+ /* @__PURE__ */ H(_, {
599
600
  label: "Due date",
600
- children: /* @__PURE__ */ H(D, {
601
+ children: /* @__PURE__ */ H(O, {
601
602
  type: "date",
602
603
  value: a.dueDate,
603
604
  onChange: l("dueDate")
604
605
  })
605
606
  }),
606
- /* @__PURE__ */ H(g, {
607
+ /* @__PURE__ */ H(_, {
607
608
  label: "Acceptance criteria",
608
- children: /* @__PURE__ */ H(E, {
609
+ children: /* @__PURE__ */ H(D, {
609
610
  value: a.acceptanceCriteria,
610
611
  onChange: l("acceptanceCriteria")
611
612
  })
612
613
  }),
613
- /* @__PURE__ */ H(g, {
614
+ /* @__PURE__ */ H(_, {
614
615
  label: "Description",
615
- children: /* @__PURE__ */ H(E, {
616
+ children: /* @__PURE__ */ H(D, {
616
617
  value: a.description,
617
618
  onChange: l("description")
618
619
  })
@@ -627,7 +628,7 @@ var ce = {
627
628
  triggerAmount: "",
628
629
  triggersInvoice: !1
629
630
  }), [s, c] = P(null);
630
- return /* @__PURE__ */ H(y, {
631
+ return /* @__PURE__ */ H(b, {
631
632
  open: !0,
632
633
  onClose: t,
633
634
  title: "Add milestone",
@@ -658,14 +659,14 @@ var ce = {
658
659
  children: /* @__PURE__ */ U("div", {
659
660
  className: "space-y-3",
660
661
  children: [
661
- s && /* @__PURE__ */ H(p, {
662
+ s && /* @__PURE__ */ H(m, {
662
663
  tone: "danger",
663
664
  children: s
664
665
  }),
665
- /* @__PURE__ */ H(g, {
666
+ /* @__PURE__ */ H(_, {
666
667
  label: "Name",
667
668
  required: !0,
668
- children: /* @__PURE__ */ H(D, {
669
+ children: /* @__PURE__ */ H(O, {
669
670
  value: a.name,
670
671
  onChange: (e) => o((t) => ({
671
672
  ...t,
@@ -674,9 +675,9 @@ var ce = {
674
675
  placeholder: "Phase 1 sign-off"
675
676
  })
676
677
  }),
677
- /* @__PURE__ */ H(g, {
678
+ /* @__PURE__ */ H(_, {
678
679
  label: "Due date",
679
- children: /* @__PURE__ */ H(D, {
680
+ children: /* @__PURE__ */ H(O, {
680
681
  type: "date",
681
682
  value: a.dueDate,
682
683
  onChange: (e) => o((t) => ({
@@ -685,10 +686,10 @@ var ce = {
685
686
  }))
686
687
  })
687
688
  }),
688
- /* @__PURE__ */ H(g, {
689
+ /* @__PURE__ */ H(_, {
689
690
  label: "Trigger amount",
690
691
  hint: "Amount billed when this milestone completes (if it triggers an invoice).",
691
- children: /* @__PURE__ */ H(D, {
692
+ children: /* @__PURE__ */ H(O, {
692
693
  type: "number",
693
694
  min: "0",
694
695
  value: a.triggerAmount,