@elevasis/ui 2.30.0 → 2.31.0

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 (109) hide show
  1. package/dist/{CoreAuthKitInner-QC62UHTZ.js → CoreAuthKitInner-KSEGSB67.js} +1 -1
  2. package/dist/api/index.js +3 -3
  3. package/dist/app/index.d.ts +122 -1
  4. package/dist/app/index.js +7 -7
  5. package/dist/auth/context.js +1 -1
  6. package/dist/auth/index.js +1 -1
  7. package/dist/charts/index.js +4 -4
  8. package/dist/{chunk-T5Z7G2J2.js → chunk-3BAPR3KA.js} +1 -1
  9. package/dist/{chunk-4VQ2PXMI.js → chunk-3FV6HBXS.js} +4 -4
  10. package/dist/{chunk-2DIYILF7.js → chunk-542WPQU2.js} +2 -2
  11. package/dist/{chunk-SBCIB5TZ.js → chunk-5LJAEZMA.js} +5 -5
  12. package/dist/{chunk-T2PAD63Y.js → chunk-7HMCB26R.js} +1 -1
  13. package/dist/chunk-7KC4P3AU.js +357 -0
  14. package/dist/{chunk-AKOD52HS.js → chunk-CQZ3DNQY.js} +4 -3
  15. package/dist/{chunk-I2KLQ2HA.js → chunk-DZTG5IAC.js} +7 -1
  16. package/dist/{chunk-JCGD4GM6.js → chunk-GRDLB6LM.js} +1 -0
  17. package/dist/{chunk-JKTPRYGV.js → chunk-HQGF4ATG.js} +9 -55
  18. package/dist/{chunk-SKXXT3E2.js → chunk-HYNYEBHM.js} +4 -4
  19. package/dist/{chunk-6EFVZV6X.js → chunk-JKSUN5GN.js} +718 -64
  20. package/dist/{chunk-LRZFLK2F.js → chunk-L2NVFLXU.js} +3 -3
  21. package/dist/{chunk-6WXDE5LZ.js → chunk-L3BVJWML.js} +1 -1
  22. package/dist/{chunk-3MDNBHVB.js → chunk-MVFCLZSK.js} +690 -221
  23. package/dist/{chunk-HYLERWRO.js → chunk-ND42LPY4.js} +6 -6
  24. package/dist/{chunk-CLUP5H3C.js → chunk-O2QOPJI5.js} +360 -126
  25. package/dist/{chunk-X2SUMO3P.js → chunk-P55BJZZW.js} +2 -1
  26. package/dist/{chunk-4FZYEEPK.js → chunk-Q6OYNEGR.js} +5 -5
  27. package/dist/{chunk-4SY6BTVZ.js → chunk-QDEETKYT.js} +4 -1
  28. package/dist/{chunk-IKQ42WHU.js → chunk-QHEWXU7I.js} +1 -1
  29. package/dist/chunk-R2XR4FCV.js +48 -0
  30. package/dist/chunk-R66W5UDG.js +26 -0
  31. package/dist/{chunk-3GV5NHSS.js → chunk-SHQXMW4F.js} +39 -211
  32. package/dist/{chunk-A7B7HLDF.js → chunk-T3IPHEYJ.js} +1889 -301
  33. package/dist/{chunk-7E3FUTND.js → chunk-TOIXUWR6.js} +1 -1
  34. package/dist/{chunk-NITGGYH2.js → chunk-TVRQ6AQI.js} +1 -1
  35. package/dist/{chunk-CN2HC4D4.js → chunk-UFTM5SZZ.js} +2 -2
  36. package/dist/{chunk-KVJ3LFH2.js → chunk-VNFR57DF.js} +4 -24
  37. package/dist/{chunk-P5WYW2GI.js → chunk-Y4FWCG7Y.js} +150 -305
  38. package/dist/components/chat/index.js +1 -1
  39. package/dist/components/index.d.ts +205 -11
  40. package/dist/components/index.js +38 -35
  41. package/dist/components/navigation/index.js +1 -1
  42. package/dist/execution/index.d.ts +2 -1
  43. package/dist/execution/index.js +1 -1
  44. package/dist/features/auth/index.d.ts +121 -0
  45. package/dist/features/auth/index.js +1 -1
  46. package/dist/features/clients/index.css +611 -0
  47. package/dist/features/clients/index.d.ts +86 -0
  48. package/dist/features/clients/index.js +719 -0
  49. package/dist/features/crm/index.d.ts +148 -2
  50. package/dist/features/crm/index.js +18 -16
  51. package/dist/features/dashboard/index.d.ts +36 -1
  52. package/dist/features/dashboard/index.js +14 -14
  53. package/dist/features/delivery/index.d.ts +121 -0
  54. package/dist/features/delivery/index.js +18 -16
  55. package/dist/features/knowledge/index.js +43 -20
  56. package/dist/features/lead-gen/index.d.ts +17 -11
  57. package/dist/features/lead-gen/index.js +19 -17
  58. package/dist/features/monitoring/index.js +17 -16
  59. package/dist/features/monitoring/requests/index.js +14 -13
  60. package/dist/features/operations/index.d.ts +38 -2
  61. package/dist/features/operations/index.js +22 -21
  62. package/dist/features/seo/index.js +1 -1
  63. package/dist/features/settings/index.d.ts +121 -0
  64. package/dist/features/settings/index.js +16 -15
  65. package/dist/graph/index.js +1 -1
  66. package/dist/hooks/delivery/index.d.ts +140 -0
  67. package/dist/hooks/delivery/index.js +3 -3
  68. package/dist/hooks/index.d.ts +583 -19
  69. package/dist/hooks/index.js +12 -12
  70. package/dist/hooks/operations/command-view/utils/transformCommandViewData.d.ts +82 -1
  71. package/dist/hooks/operations/command-view/utils/transformCommandViewData.js +1 -1
  72. package/dist/hooks/published.d.ts +583 -19
  73. package/dist/hooks/published.js +12 -12
  74. package/dist/index.d.ts +680 -21
  75. package/dist/index.js +13 -13
  76. package/dist/initialization/index.d.ts +121 -0
  77. package/dist/initialization/index.js +1 -1
  78. package/dist/knowledge/index.d.ts +97 -1
  79. package/dist/knowledge/index.js +1692 -1039
  80. package/dist/layout/index.d.ts +6 -0
  81. package/dist/layout/index.js +4 -4
  82. package/dist/organization/index.js +1 -1
  83. package/dist/profile/index.d.ts +121 -0
  84. package/dist/profile/index.js +1 -1
  85. package/dist/provider/ElevasisServiceContext.js +1 -1
  86. package/dist/provider/index.d.ts +218 -2
  87. package/dist/provider/index.js +10 -10
  88. package/dist/provider/published.d.ts +218 -2
  89. package/dist/provider/published.js +7 -7
  90. package/dist/router/context.js +1 -1
  91. package/dist/router/index.js +1 -1
  92. package/dist/sse/index.js +1 -1
  93. package/dist/supabase/index.d.ts +232 -0
  94. package/dist/supabase/index.js +1 -1
  95. package/dist/test-utils/index.js +3 -3
  96. package/dist/test-utils/setup-integration.js +1 -1
  97. package/dist/test-utils/setup.js +2 -2
  98. package/dist/theme/index.js +4 -4
  99. package/dist/theme/presets/index.js +2 -2
  100. package/dist/typeform/index.js +1 -1
  101. package/dist/typeform/schemas.js +1 -1
  102. package/dist/types/index.d.ts +204 -1
  103. package/dist/utils/index.d.ts +36 -1
  104. package/dist/utils/index.js +2 -2
  105. package/dist/vite/index.js +3 -3
  106. package/dist/vite-plugin-knowledge/index.js +2 -2
  107. package/dist/zustand/index.js +1 -1
  108. package/package.json +13 -4
  109. /package/dist/{chunk-HXZQWMKE.js → chunk-XQHZBA65.js} +0 -0
@@ -0,0 +1,357 @@
1
+ import { SubshellNavItem } from './chunk-X4WBGKJQ.js';
2
+ import { SubshellSidebarSection } from './chunk-IIMU5YAJ.js';
3
+ import { useDealsLookup, useCreateDealTask, useDealTasksDue } from './chunk-JKSUN5GN.js';
4
+ import { useRouterContext } from './chunk-Q7DJKLEN.js';
5
+ import { Box, Stack, Text, UnstyledButton, Group, Button, Modal, Title, Select, TextInput, Textarea, Badge, Center, Loader } from '@mantine/core';
6
+ import { IconLayoutGrid, IconColumns, IconFileInvoice, IconList, IconBuilding, IconAddressBook, IconTrophy, IconClockExclamation, IconUser, IconPlus, IconChecklist, IconTarget, IconCheckbox, IconCalendar, IconMail, IconPhone } from '@tabler/icons-react';
7
+ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
8
+ import { useState } from 'react';
9
+
10
+ // src/features/crm/workbench/constants.ts
11
+ var SAVED_VIEW_PRESETS = [
12
+ {
13
+ id: "my-deals",
14
+ label: "My Deals",
15
+ iconName: "IconUser",
16
+ target: "/crm/deals"
17
+ },
18
+ {
19
+ id: "overdue",
20
+ label: "Overdue",
21
+ iconName: "IconClockExclamation",
22
+ target: "/crm/deals"
23
+ },
24
+ {
25
+ id: "won-this-month",
26
+ label: "Won this month",
27
+ iconName: "IconTrophy",
28
+ target: "/crm/deals",
29
+ urlFilters: { stage: "closed_won" }
30
+ }
31
+ ];
32
+ var ICON_MAP = {
33
+ IconUser,
34
+ IconClockExclamation,
35
+ IconTrophy
36
+ };
37
+ function SavedViewsPanel({ onViewClick, showSectionLabel = true }) {
38
+ return /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Stack, { gap: 4, children: [
39
+ showSectionLabel && /* @__PURE__ */ jsx(Text, { fz: "xs", tt: "uppercase", c: "dimmed", fw: 600, mb: 4, children: "Saved Views" }),
40
+ SAVED_VIEW_PRESETS.map((preset) => {
41
+ const Icon = ICON_MAP[preset.iconName];
42
+ return /* @__PURE__ */ jsx(
43
+ UnstyledButton,
44
+ {
45
+ onClick: () => onViewClick(preset),
46
+ style: {
47
+ display: "block",
48
+ width: "100%",
49
+ padding: "4px 6px",
50
+ borderRadius: "var(--mantine-radius-sm)",
51
+ transition: `background-color var(--duration-fast) var(--easing)`
52
+ },
53
+ onMouseEnter: (e) => {
54
+ e.currentTarget.style.backgroundColor = "var(--color-surface-hover)";
55
+ },
56
+ onMouseLeave: (e) => {
57
+ e.currentTarget.style.backgroundColor = "transparent";
58
+ },
59
+ children: /* @__PURE__ */ jsxs(Group, { gap: "xs", wrap: "nowrap", children: [
60
+ /* @__PURE__ */ jsx(Icon, { size: 14, style: { color: "var(--color-text-dimmed)", flexShrink: 0 } }),
61
+ /* @__PURE__ */ jsx(Text, { size: "xs", children: preset.label })
62
+ ] })
63
+ },
64
+ preset.id
65
+ );
66
+ })
67
+ ] }) });
68
+ }
69
+ var KIND_OPTIONS = [
70
+ { value: "call", label: "Call" },
71
+ { value: "email", label: "Email" },
72
+ { value: "meeting", label: "Meeting" },
73
+ { value: "other", label: "Other" }
74
+ ];
75
+ function QuickCreateActions({ showSectionLabel = true }) {
76
+ const [open, setOpen] = useState(false);
77
+ const [dealId, setDealId] = useState(null);
78
+ const [dealSearch, setDealSearch] = useState("");
79
+ const [title, setTitle] = useState("");
80
+ const [description, setDescription] = useState("");
81
+ const [kind, setKind] = useState("other");
82
+ const [dueAt, setDueAt] = useState("");
83
+ const { data: deals, isLoading: isLoadingDeals } = useDealsLookup(
84
+ {
85
+ search: dealSearch || void 0,
86
+ limit: 25
87
+ },
88
+ { enabled: open }
89
+ );
90
+ const createTask = useCreateDealTask();
91
+ const dealOptions = (deals ?? []).map((deal) => ({
92
+ value: deal.id,
93
+ label: deal.displayLabel
94
+ }));
95
+ function resetForm() {
96
+ setDealId(null);
97
+ setDealSearch("");
98
+ setTitle("");
99
+ setDescription("");
100
+ setKind("other");
101
+ setDueAt("");
102
+ }
103
+ function handleClose() {
104
+ setOpen(false);
105
+ resetForm();
106
+ }
107
+ async function handleSubmit() {
108
+ if (!dealId || !title) return;
109
+ await createTask.mutateAsync({
110
+ dealId,
111
+ title,
112
+ description: description || null,
113
+ kind,
114
+ dueAt: dueAt ? new Date(dueAt).toISOString() : null
115
+ });
116
+ handleClose();
117
+ }
118
+ const isSubmitDisabled = !dealId || !title || createTask.isPending;
119
+ return /* @__PURE__ */ jsxs(Fragment, { children: [
120
+ /* @__PURE__ */ jsxs(Stack, { gap: 4, children: [
121
+ showSectionLabel && /* @__PURE__ */ jsx(Text, { fz: "xs", tt: "uppercase", c: "dimmed", fw: 600, children: "TASKS" }),
122
+ /* @__PURE__ */ jsx(Button, { variant: "light", size: "xs", leftSection: /* @__PURE__ */ jsx(IconPlus, { size: 14 }), fullWidth: true, onClick: () => setOpen(true), children: "New Task" })
123
+ ] }),
124
+ /* @__PURE__ */ jsxs(Modal, { opened: open, onClose: handleClose, size: "md", children: [
125
+ /* @__PURE__ */ jsxs(Stack, { gap: "sm", children: [
126
+ /* @__PURE__ */ jsx(Title, { order: 3, children: "New Task" }),
127
+ /* @__PURE__ */ jsx(
128
+ Select,
129
+ {
130
+ label: "Deal",
131
+ placeholder: "Search deals",
132
+ data: dealOptions,
133
+ value: dealId,
134
+ onChange: setDealId,
135
+ searchValue: dealSearch,
136
+ onSearchChange: setDealSearch,
137
+ searchable: true,
138
+ nothingFoundMessage: dealSearch ? "No matching deals" : "No deals available",
139
+ disabled: isLoadingDeals,
140
+ required: true
141
+ }
142
+ ),
143
+ /* @__PURE__ */ jsx(
144
+ TextInput,
145
+ {
146
+ label: "Title",
147
+ placeholder: "Task title",
148
+ value: title,
149
+ onChange: (e) => setTitle(e.currentTarget.value),
150
+ required: true
151
+ }
152
+ ),
153
+ /* @__PURE__ */ jsx(
154
+ Textarea,
155
+ {
156
+ label: "Description",
157
+ placeholder: "Optional description",
158
+ value: description,
159
+ onChange: (e) => setDescription(e.currentTarget.value),
160
+ autosize: true,
161
+ minRows: 2,
162
+ maxRows: 5
163
+ }
164
+ ),
165
+ /* @__PURE__ */ jsx(
166
+ Select,
167
+ {
168
+ label: "Kind",
169
+ data: KIND_OPTIONS,
170
+ value: kind,
171
+ onChange: (v) => setKind(v ?? "other")
172
+ }
173
+ ),
174
+ /* @__PURE__ */ jsx(
175
+ TextInput,
176
+ {
177
+ type: "datetime-local",
178
+ label: "Due At",
179
+ value: dueAt,
180
+ onChange: (e) => setDueAt(e.currentTarget.value)
181
+ }
182
+ )
183
+ ] }),
184
+ /* @__PURE__ */ jsxs(Group, { justify: "flex-end", mt: "md", children: [
185
+ /* @__PURE__ */ jsx(Button, { variant: "default", onClick: handleClose, children: "Cancel" }),
186
+ /* @__PURE__ */ jsx(Button, { onClick: handleSubmit, loading: createTask.isPending, disabled: isSubmitDisabled, children: "Create" })
187
+ ] })
188
+ ] })
189
+ ] });
190
+ }
191
+ var CRM_ITEMS = [
192
+ { label: "Overview", to: "/crm", icon: IconLayoutGrid, exact: true },
193
+ { label: "Pipeline", to: "/crm/pipeline", icon: IconColumns, exact: false },
194
+ { label: "Deals", to: "/crm/deals", icon: IconFileInvoice, exact: false }
195
+ ];
196
+ var CrmSidebarMiddle = ({ items = CRM_ITEMS } = {}) => {
197
+ const { currentPath, navigate } = useRouterContext();
198
+ return /* @__PURE__ */ jsxs(Stack, { gap: 0, style: { flex: 1, overflowY: "auto" }, children: [
199
+ /* @__PURE__ */ jsx(Stack, { gap: 0, p: "sm", children: items.map((item) => {
200
+ const isActive = item.exact ? currentPath === item.to || currentPath === `${item.to}/` : currentPath.startsWith(item.to);
201
+ return /* @__PURE__ */ jsx(
202
+ SubshellNavItem,
203
+ {
204
+ icon: item.icon,
205
+ label: item.label,
206
+ isActive,
207
+ href: item.to,
208
+ onClick: () => navigate(item.to)
209
+ },
210
+ item.to
211
+ );
212
+ }) }),
213
+ /* @__PURE__ */ jsx(SubshellSidebarSection, { icon: IconChecklist, label: "My Tasks", withTopBorder: true }),
214
+ /* @__PURE__ */ jsx(Stack, { gap: 0, p: "sm", children: /* @__PURE__ */ jsx(
215
+ MyTasksPanel,
216
+ {
217
+ onTaskClick: (dealId) => navigate(`/crm/deals/${dealId}`),
218
+ onSeeAll: () => navigate("/crm/deals"),
219
+ showSectionLabel: false,
220
+ footer: /* @__PURE__ */ jsx(QuickCreateActions, { showSectionLabel: false })
221
+ }
222
+ ) })
223
+ ] });
224
+ };
225
+ var LEAD_GEN_ITEMS = [
226
+ { label: "Overview", to: "/lead-gen", icon: IconLayoutGrid, exact: true },
227
+ { label: "Lists", to: "/lead-gen/lists", icon: IconList, exact: false },
228
+ { label: "Companies", to: "/lead-gen/companies", icon: IconBuilding, exact: false },
229
+ { label: "Contacts", to: "/lead-gen/contacts", icon: IconAddressBook, exact: false }
230
+ ];
231
+ var LeadGenSidebarMiddle = ({ items = LEAD_GEN_ITEMS } = {}) => {
232
+ const { currentPath, navigate } = useRouterContext();
233
+ return /* @__PURE__ */ jsx(Stack, { gap: 0, style: { flex: 1, overflowY: "auto" }, children: /* @__PURE__ */ jsx(Stack, { gap: 0, p: "sm", children: items.map((item) => {
234
+ const isActive = item.exact ? currentPath === item.to || currentPath === `${item.to}/` : currentPath.startsWith(item.to);
235
+ return /* @__PURE__ */ jsx(
236
+ SubshellNavItem,
237
+ {
238
+ icon: item.icon,
239
+ label: item.label,
240
+ isActive,
241
+ href: item.to,
242
+ onClick: () => navigate(item.to)
243
+ },
244
+ item.to
245
+ );
246
+ }) }) });
247
+ };
248
+ var renderItems = (items, currentPath, navigate) => items.map((item) => {
249
+ const isActive = item.exact ? currentPath === item.to || currentPath === `${item.to}/` : currentPath.startsWith(item.to);
250
+ return /* @__PURE__ */ jsx(
251
+ SubshellNavItem,
252
+ {
253
+ icon: item.icon,
254
+ label: item.label,
255
+ isActive,
256
+ href: item.to,
257
+ onClick: () => navigate(item.to)
258
+ },
259
+ item.to
260
+ );
261
+ });
262
+ var SalesSidebar = () => {
263
+ const { currentPath, navigate } = useRouterContext();
264
+ return /* @__PURE__ */ jsx(Stack, { gap: 0, style: { height: "100%", display: "flex", flexDirection: "column" }, children: /* @__PURE__ */ jsxs(Stack, { gap: 0, style: { flex: 1, overflowY: "auto" }, children: [
265
+ /* @__PURE__ */ jsx(SubshellSidebarSection, { icon: IconTarget, label: "Lead Gen" }),
266
+ /* @__PURE__ */ jsx(Stack, { gap: 0, p: "sm", children: renderItems(LEAD_GEN_ITEMS, currentPath, navigate) }),
267
+ /* @__PURE__ */ jsx(SubshellSidebarSection, { icon: IconAddressBook, label: "CRM", withTopBorder: true }),
268
+ /* @__PURE__ */ jsx(Stack, { gap: 0, p: "sm", children: renderItems(CRM_ITEMS, currentPath, navigate) }),
269
+ /* @__PURE__ */ jsx(SubshellSidebarSection, { icon: IconChecklist, label: "My Tasks", withTopBorder: true }),
270
+ /* @__PURE__ */ jsx(Stack, { gap: 0, p: "sm", children: /* @__PURE__ */ jsx(
271
+ MyTasksPanel,
272
+ {
273
+ onTaskClick: (dealId) => navigate(`/crm/deals/${dealId}`),
274
+ onSeeAll: () => navigate("/crm/deals"),
275
+ showSectionLabel: false,
276
+ footer: /* @__PURE__ */ jsx(QuickCreateActions, { showSectionLabel: false })
277
+ }
278
+ ) })
279
+ ] }) });
280
+ };
281
+ var KIND_ICONS = {
282
+ call: IconPhone,
283
+ email: IconMail,
284
+ meeting: IconCalendar,
285
+ other: IconCheckbox
286
+ };
287
+ function formatDueLabel(dueAt) {
288
+ if (!dueAt) return "";
289
+ const date = new Date(dueAt);
290
+ const now = /* @__PURE__ */ new Date();
291
+ const today = new Date(now.getFullYear(), now.getMonth(), now.getDate());
292
+ const dueDay = new Date(date.getFullYear(), date.getMonth(), date.getDate());
293
+ const diffDays = Math.round((dueDay.getTime() - today.getTime()) / 864e5);
294
+ if (diffDays < 0) return `${Math.abs(diffDays)}d overdue`;
295
+ if (diffDays === 0) {
296
+ return date.toLocaleTimeString([], { hour: "2-digit", minute: "2-digit" });
297
+ }
298
+ return `in ${diffDays}d`;
299
+ }
300
+ function TaskRow({ task, onClick }) {
301
+ const KindIcon = KIND_ICONS[task.kind];
302
+ const dueLabel = formatDueLabel(task.dueAt);
303
+ const isOverdue = task.dueAt !== null && new Date(task.dueAt) < /* @__PURE__ */ new Date();
304
+ return /* @__PURE__ */ jsx(
305
+ UnstyledButton,
306
+ {
307
+ onClick,
308
+ style: {
309
+ display: "block",
310
+ width: "100%",
311
+ padding: "4px 6px",
312
+ borderRadius: "var(--mantine-radius-sm)",
313
+ transition: `background-color var(--duration-fast) var(--easing)`
314
+ },
315
+ onMouseEnter: (e) => {
316
+ e.currentTarget.style.backgroundColor = "var(--color-surface-hover)";
317
+ },
318
+ onMouseLeave: (e) => {
319
+ e.currentTarget.style.backgroundColor = "transparent";
320
+ },
321
+ children: /* @__PURE__ */ jsxs(Group, { gap: "xs", wrap: "nowrap", children: [
322
+ /* @__PURE__ */ jsx(KindIcon, { size: 14, style: { color: "var(--color-text-dimmed)", flexShrink: 0 } }),
323
+ /* @__PURE__ */ jsx(Text, { size: "xs", truncate: true, style: { flex: 1, minWidth: 0 }, children: task.title }),
324
+ dueLabel && /* @__PURE__ */ jsx(Badge, { size: "xs", variant: "light", color: isOverdue ? "red" : "gray", style: { flexShrink: 0 }, children: dueLabel })
325
+ ] })
326
+ }
327
+ );
328
+ }
329
+ function MyTasksPanel({
330
+ onTaskClick,
331
+ onSeeAll,
332
+ footer,
333
+ showSectionLabel = true
334
+ }) {
335
+ const { data, isLoading, isError } = useDealTasksDue({ window: "today_and_overdue" });
336
+ const tasks = data ?? [];
337
+ const total = tasks.length;
338
+ const visible = tasks.slice(0, 5);
339
+ return /* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsxs(Stack, { gap: 4, children: [
340
+ showSectionLabel && /* @__PURE__ */ jsxs(Group, { justify: "space-between", mb: 4, children: [
341
+ /* @__PURE__ */ jsx(Text, { fz: "xs", tt: "uppercase", c: "dimmed", fw: 600, children: "My Tasks" }),
342
+ total > 0 && /* @__PURE__ */ jsx(Badge, { size: "xs", variant: "light", children: total })
343
+ ] }),
344
+ isLoading && /* @__PURE__ */ jsx(Center, { py: 4, children: /* @__PURE__ */ jsx(Loader, { size: "xs" }) }),
345
+ isError && /* @__PURE__ */ jsx(Text, { size: "xs", c: "red", children: "Failed to load tasks" }),
346
+ !isLoading && !isError && visible.length === 0 && /* @__PURE__ */ jsx(Text, { size: "xs", c: "dimmed", children: "No tasks due - you're caught up." }),
347
+ !isLoading && !isError && visible.map((task) => /* @__PURE__ */ jsx(TaskRow, { task, onClick: () => onTaskClick(task.dealId) }, task.id)),
348
+ onSeeAll && total > 5 && /* @__PURE__ */ jsx(UnstyledButton, { onClick: onSeeAll, mt: 2, style: { display: "inline-block" }, children: /* @__PURE__ */ jsxs(Text, { size: "xs", c: "dimmed", style: { textDecoration: "underline" }, children: [
349
+ "See all (",
350
+ total,
351
+ ")"
352
+ ] }) }),
353
+ footer
354
+ ] }) });
355
+ }
356
+
357
+ export { CRM_ITEMS, CrmSidebarMiddle, LEAD_GEN_ITEMS, LeadGenSidebarMiddle, MyTasksPanel, QuickCreateActions, SAVED_VIEW_PRESETS, SalesSidebar, SavedViewsPanel };
@@ -1,6 +1,6 @@
1
- import { ApiClientProvider, useApiClient } from './chunk-7E3FUTND.js';
1
+ import { ApiClientProvider, useApiClient } from './chunk-TOIXUWR6.js';
2
2
  import { OrganizationProvider } from './chunk-HUJCU55S.js';
3
- import { getErrorInfo, getErrorTitle, formatErrorMessage } from './chunk-HXZQWMKE.js';
3
+ import { getErrorInfo, getErrorTitle, formatErrorMessage } from './chunk-XQHZBA65.js';
4
4
  import { InitializationProvider } from './chunk-533DUEQY.js';
5
5
  import { useOrganization } from './chunk-DD3CCMCZ.js';
6
6
  import { ProfileProvider } from './chunk-2Q2JQSQO.js';
@@ -56,6 +56,7 @@ var ORGANIZATION_MODEL_ICON_TOKENS = [
56
56
  "knowledge.reference",
57
57
  "feature.dashboard",
58
58
  "feature.calendar",
59
+ "feature.business",
59
60
  "feature.sales",
60
61
  "feature.crm",
61
62
  "feature.finance",
@@ -637,7 +638,7 @@ function findListActionByCapability(registry, capabilityKey) {
637
638
  function getListActionWorkflowId(action) {
638
639
  return action.workflowId ?? action.resourceId;
639
640
  }
640
- var LazyCoreAuthKitInner = lazy(() => import('./CoreAuthKitInner-QC62UHTZ.js').then((m) => ({ default: m.CoreAuthKitInner })));
641
+ var LazyCoreAuthKitInner = lazy(() => import('./CoreAuthKitInner-KSEGSB67.js').then((m) => ({ default: m.CoreAuthKitInner })));
641
642
  var defaultQueryClient = null;
642
643
  function getDefaultQueryClient() {
643
644
  if (!defaultQueryClient) {
@@ -2,6 +2,12 @@ var __defProp = Object.defineProperty;
2
2
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
3
  var __getOwnPropNames = Object.getOwnPropertyNames;
4
4
  var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
6
+ get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
7
+ }) : x)(function(x) {
8
+ if (typeof require !== "undefined") return require.apply(this, arguments);
9
+ throw Error('Dynamic require of "' + x + '" is not supported');
10
+ });
5
11
  var __export = (target, all) => {
6
12
  for (var name in all)
7
13
  __defProp(target, name, { get: all[name], enumerable: true });
@@ -16,4 +22,4 @@ var __copyProps = (to, from, except, desc) => {
16
22
  };
17
23
  var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
18
24
 
19
- export { __export, __reExport };
25
+ export { __export, __reExport, __require };
@@ -17,6 +17,7 @@ var DEFAULT_SEMANTIC_ICON_REGISTRY = {
17
17
  "nav.archive": IconArchive,
18
18
  "feature.dashboard": IconDashboard,
19
19
  "feature.calendar": IconCalendar,
20
+ "feature.business": IconBuildingStore,
20
21
  "feature.sales": IconChartBar,
21
22
  "feature.crm": IconBuildingStore,
22
23
  "feature.finance": IconChartBar,
@@ -1,16 +1,17 @@
1
1
  import { PROJECTS_VIEW_CAPABILITY_ID, PROJECTS_FEATURE_ID } from './chunk-ECNNI3NT.js';
2
- import { PageContainer } from './chunk-BZZCNLT6.js';
3
- import { TableSelectionToolbar, SortableHeader } from './chunk-TUMSNGTX.js';
4
2
  import { SubshellNavItem } from './chunk-X4WBGKJQ.js';
5
3
  import { SubshellSidebarSection } from './chunk-IIMU5YAJ.js';
4
+ import { milestoneStatusColors, formatStatusLabel, taskTypeColors, taskStatusColors, projectStatusColors, calculateProgress, noteTypeColors } from './chunk-R2XR4FCV.js';
5
+ import { PageContainer } from './chunk-BZZCNLT6.js';
6
+ import { TableSelectionToolbar, SortableHeader } from './chunk-TUMSNGTX.js';
6
7
  import { FilterBar } from './chunk-PDHTXPSF.js';
7
- import { CustomModal } from './chunk-KVJ3LFH2.js';
8
- import { useProjectRealtime, useTableSort, sortData, usePaginationState, useTableSelection, useProjectActivities } from './chunk-6EFVZV6X.js';
9
- import { useCreateTask, useCreateMilestone, useProjectMilestones, useUpdateTask, useProjects, useDeleteProject, useProject, useProjectNotes, useUpdateMilestone, useCreateNote, showApiErrorNotification, projectKeys } from './chunk-T2PAD63Y.js';
10
- import { StatusBadge, EmptyState, PageTitleCaption, CenteredErrorState, StatCard, CardHeader } from './chunk-6WXDE5LZ.js';
8
+ import { CustomModal } from './chunk-R66W5UDG.js';
9
+ import { useProjectRealtime, useTableSort, sortData, usePaginationState, useTableSelection, useProjectActivities } from './chunk-JKSUN5GN.js';
10
+ import { useCreateTask, useCreateMilestone, useProjectMilestones, useUpdateTask, useProjects, useDeleteProject, useProject, useProjectNotes, useUpdateMilestone, useCreateNote, showApiErrorNotification, projectKeys } from './chunk-7HMCB26R.js';
11
+ import { StatusBadge, EmptyState, PageTitleCaption, CenteredErrorState, StatCard, CardHeader } from './chunk-L3BVJWML.js';
11
12
  import { SubshellContentContainer } from './chunk-TKAYX2SP.js';
12
13
  import { useRouterContext } from './chunk-Q7DJKLEN.js';
13
- import { PAGE_SIZE_DEFAULT, formatTimeAgo, formatDate, formatRelativeTime } from './chunk-HXZQWMKE.js';
14
+ import { PAGE_SIZE_DEFAULT, formatTimeAgo, formatDate, formatRelativeTime } from './chunk-XQHZBA65.js';
14
15
  import { useElevasisServices } from './chunk-KJ3QUBNU.js';
15
16
  import { useState, useMemo, useCallback } from 'react';
16
17
  import { Stack, Text, Group, Checkbox, ActionIcon, TextInput, Button, Modal, Title, Textarea, Select, SimpleGrid, Card, ThemeIcon, RingProgress, Paper, Timeline, Badge, Collapse, Center, Loader, Table, Pagination, Alert, CopyButton, Tooltip, Space, Tabs, Divider, Anchor, Chip } from '@mantine/core';
@@ -312,53 +313,6 @@ function HealthStatusCard({
312
313
  ] }) })
313
314
  ] });
314
315
  }
315
-
316
- // src/features/delivery/_shared.ts
317
- var projectStatusColors = {
318
- active: "blue",
319
- on_track: "green",
320
- at_risk: "yellow",
321
- blocked: "red",
322
- completed: "teal",
323
- paused: "gray"
324
- };
325
- var milestoneStatusColors = {
326
- upcoming: "gray",
327
- in_progress: "blue",
328
- completed: "green",
329
- overdue: "red",
330
- blocked: "orange"
331
- };
332
- var taskStatusColors = {
333
- pending: "gray",
334
- planned: "gray",
335
- in_progress: "blue",
336
- submitted: "yellow",
337
- approved: "green",
338
- rejected: "red",
339
- revision_requested: "orange"
340
- };
341
- var taskTypeColors = {
342
- documentation: "blue",
343
- code: "violet",
344
- report: "cyan",
345
- design: "pink",
346
- other: "gray"
347
- };
348
- var noteTypeColors = {
349
- call_note: "blue",
350
- status_update: "green",
351
- issue: "yellow",
352
- blocker: "red",
353
- agent_learning: "grape"
354
- };
355
- function formatStatusLabel(status) {
356
- return status.split("_").map((word) => word.charAt(0).toUpperCase() + word.slice(1)).join(" ");
357
- }
358
- function calculateProgress(completed, total) {
359
- if (total === 0) return 0;
360
- return Math.round(completed / total * 100);
361
- }
362
316
  var MILESTONE_ICONS = {
363
317
  upcoming: IconClock,
364
318
  in_progress: IconFlag,
@@ -1659,4 +1613,4 @@ function ProjectDetailPage({ projectId, onBack, backLabel = "Projects" }) {
1659
1613
  ] }) }) });
1660
1614
  }
1661
1615
 
1662
- export { AllTasksPage, Checklist, CreateDeliveryEntityModal, DELIVERY_COMMUNICATION_ITEMS, DELIVERY_PROJECT_ITEMS, DELIVERY_WORK_ITEMS, HealthStatusCard, MilestoneTimeline, ProjectDetailPage, ProjectsListPage, ProjectsSidebar, ProjectsSidebarMiddle, ProjectsSidebarTop, TaskCard, UpcomingMilestonesPage, calculateProgress, deliveryManifest, formatStatusLabel, milestoneStatusColors, noteTypeColors, projectStatusColors, taskStatusColors, taskTypeColors };
1616
+ export { AllTasksPage, Checklist, CreateDeliveryEntityModal, DELIVERY_COMMUNICATION_ITEMS, DELIVERY_PROJECT_ITEMS, DELIVERY_WORK_ITEMS, HealthStatusCard, MilestoneTimeline, ProjectDetailPage, ProjectsListPage, ProjectsSidebar, ProjectsSidebarMiddle, ProjectsSidebarTop, TaskCard, UpcomingMilestonesPage, deliveryManifest };
@@ -1,10 +1,10 @@
1
- import { mantineThemeOverride, createCssVariablesResolver, PresetsProvider } from './chunk-T5Z7G2J2.js';
2
- import { PRESETS, getPreset, generateShades } from './chunk-4VQ2PXMI.js';
1
+ import { mantineThemeOverride, createCssVariablesResolver, PresetsProvider } from './chunk-3BAPR3KA.js';
2
+ import { PRESETS, getPreset, generateShades } from './chunk-3FV6HBXS.js';
3
3
  import { AppBackground } from './chunk-WLOQ4IBG.js';
4
- import { ElevasisCoreProvider } from './chunk-AKOD52HS.js';
4
+ import { ElevasisCoreProvider } from './chunk-CQZ3DNQY.js';
5
5
  import { ElevasisLoader } from './chunk-SZHARWKU.js';
6
6
  import { AppearanceProvider } from './chunk-E565XMTQ.js';
7
- import { getErrorInfo, formatErrorMessage, getErrorTitle } from './chunk-HXZQWMKE.js';
7
+ import { getErrorInfo, formatErrorMessage, getErrorTitle } from './chunk-XQHZBA65.js';
8
8
  import { useMemo, useEffect } from 'react';
9
9
  import { Loader, mergeThemeOverrides, MantineProvider } from '@mantine/core';
10
10
  import '@mantine/core/styles.css';