@burdenoff/microfe-workspaces 2026.1108.1 → 2026.1110.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 (102) hide show
  1. package/dist/WorkspacesRoot.js +10 -9
  2. package/dist/WorkspacesRoutes.js +1 -2
  3. package/dist/components/CreateProjectDialog.js +22 -22
  4. package/dist/components/CreateWorkspaceDialog.js +8 -9
  5. package/dist/components/InviteMemberDialog.js +18 -23
  6. package/dist/components/MemberListItem.js +16 -17
  7. package/dist/components/ProjectCard.js +14 -15
  8. package/dist/components/ProjectMemberPickerDialog.js +92 -93
  9. package/dist/components/RenameProjectDialog.js +12 -17
  10. package/dist/components/WorkspaceCard.js +6 -7
  11. package/dist/components/WorkspaceContextPathSync.js +4 -5
  12. package/dist/components/WorkspacesErrorBoundary.js +6 -11
  13. package/dist/components/index.js +8 -7
  14. package/dist/components/tags/ProjectTagsWidget.js +56 -57
  15. package/dist/components/tags/WorkspaceTagsEditor.js +2 -3
  16. package/dist/constants/permissions.js +1 -2
  17. package/dist/generated/global-operations.js +1 -2
  18. package/dist/generated/wspace-operations.js +1 -2
  19. package/dist/hooks/index.js +9 -8
  20. package/dist/hooks/useMemberMutations.js +165 -166
  21. package/dist/hooks/useOpenWorkspace.js +1 -2
  22. package/dist/hooks/useOrgsWithPermission.js +2 -3
  23. package/dist/hooks/usePendingInvitations.d.ts +1 -1
  24. package/dist/hooks/usePendingInvitations.js +2 -3
  25. package/dist/hooks/useProjectMemberMutations.js +23 -24
  26. package/dist/hooks/useProjectMembers.d.ts +2 -2
  27. package/dist/hooks/useProjectMembers.js +2 -3
  28. package/dist/hooks/useProjectMutations.js +68 -69
  29. package/dist/hooks/useProjects.d.ts +3 -3
  30. package/dist/hooks/useProjects.js +5 -6
  31. package/dist/hooks/useScopedNavigation.js +1 -2
  32. package/dist/hooks/useTenants.d.ts +2 -2
  33. package/dist/hooks/useTenants.js +3 -4
  34. package/dist/hooks/useTr.js +1 -2
  35. package/dist/hooks/useWorkspaceActivity.d.ts +1 -1
  36. package/dist/hooks/useWorkspaceActivity.js +2 -3
  37. package/dist/hooks/useWorkspaceMembers.d.ts +5 -5
  38. package/dist/hooks/useWorkspaceMembers.js +7 -8
  39. package/dist/hooks/useWorkspaceMutations.js +70 -71
  40. package/dist/hooks/useWorkspacePermissions.js +1 -2
  41. package/dist/hooks/useWorkspaceRoles.d.ts +1 -1
  42. package/dist/hooks/useWorkspaceRoles.js +3 -4
  43. package/dist/hooks/useWorkspaces.d.ts +3 -3
  44. package/dist/hooks/useWorkspaces.js +4 -5
  45. package/dist/hooks/useWorkspacesEventEmitter.js +1 -2
  46. package/dist/hooks/useWorkspacesPageView.js +1 -2
  47. package/dist/index.js +15 -15
  48. package/dist/pages/ActivityListPage.js +28 -29
  49. package/dist/pages/CreateWorkspacePage.js +137 -138
  50. package/dist/pages/InviteAcceptancePage.js +65 -66
  51. package/dist/pages/MembersListPage.js +203 -204
  52. package/dist/pages/PendingInvitesPage.js +63 -64
  53. package/dist/pages/ProjectDetailPage.js +71 -72
  54. package/dist/pages/ProjectMembersPage.js +116 -117
  55. package/dist/pages/ProjectsListPage.js +62 -67
  56. package/dist/pages/WorkspaceDetailPage.js +153 -154
  57. package/dist/pages/WorkspaceInvitePage.js +88 -92
  58. package/dist/pages/WorkspaceSettingsPage.js +32 -33
  59. package/dist/pages/WorkspacesListPage.js +40 -41
  60. package/dist/pages/dashboard/DashboardCustomizer.js +98 -94
  61. package/dist/pages/dashboard/DashboardGrid.js +1 -2
  62. package/dist/pages/dashboard/DashboardPage.js +12 -13
  63. package/dist/pages/dashboard/WidgetWrapper.js +21 -21
  64. package/dist/pages/dashboard/config.js +3 -4
  65. package/dist/pages/dashboard/hooks/useDashboardData.d.ts +5 -5
  66. package/dist/pages/dashboard/hooks/useDashboardData.js +9 -10
  67. package/dist/pages/dashboard/hooks/useDashboardPreferences.js +7 -8
  68. package/dist/pages/dashboard/reorder.js +11 -14
  69. package/dist/pages/dashboard/widgets/AgentsWidget.js +13 -14
  70. package/dist/pages/dashboard/widgets/GroupsWidget.js +9 -10
  71. package/dist/pages/dashboard/widgets/MembersWidget.js +10 -11
  72. package/dist/pages/dashboard/widgets/ProjectsWidget.js +11 -12
  73. package/dist/pages/dashboard/widgets/QuickActionsWidget.js +28 -29
  74. package/dist/pages/dashboard/widgets/RecentActivityWidget.js +22 -23
  75. package/dist/pages/dashboard/widgets/SessionsWidget.js +28 -29
  76. package/dist/pages/dashboard/widgets/StorageWidget.js +19 -20
  77. package/dist/pages/dashboard/widgets/TagCloudWidget.js +9 -10
  78. package/dist/pages/dashboard/widgets/TipsWidget.js +5 -6
  79. package/dist/pages/dashboard/widgets/UpcomingEventsWidget.js +17 -18
  80. package/dist/pages/dashboard/widgets/VibesWidget.js +13 -14
  81. package/dist/pages/dashboard/widgets/WelcomeWidget.js +12 -13
  82. package/dist/pages/dashboard/widgets/WorkflowRunsWidget.js +16 -17
  83. package/dist/pages/dashboard/widgets/WorkflowStatsWidget.js +11 -12
  84. package/dist/pages/dashboard/widgets/WorkflowsOverviewWidget.js +17 -18
  85. package/dist/pages/dashboard/widgets/WorkspacesWidget.js +7 -8
  86. package/dist/pages/dashboard/widgets/tipsCatalog.js +1 -2
  87. package/dist/providers/WorkspacesProvider.js +1 -2
  88. package/dist/store/workspacesStore.d.ts +1 -1
  89. package/dist/store/workspacesStore.js +1 -2
  90. package/dist/test/happydom.d.ts +1 -0
  91. package/dist/translations/en.js +1 -2
  92. package/dist/utils/formatters.js +1 -2
  93. package/dist/utils/i18n.js +1 -2
  94. package/dist/utils/invitationDisplay.js +1 -2
  95. package/dist/utils/nativeBridge.js +1 -2
  96. package/dist/utils/pinnedRequest.js +2 -3
  97. package/dist/utils/projectTags.js +2 -3
  98. package/dist/utils/slug.js +1 -2
  99. package/dist/utils/telemetryError.js +13 -16
  100. package/dist/utils/tokenHelpers.js +1 -2
  101. package/dist/utils/workspaceBulkInviteCsv.js +3 -8
  102. package/package.json +72 -55
@@ -1,14 +1,14 @@
1
- import { useWorkspacesContext as e } from "../providers/WorkspacesProvider.js";
2
- import { useWorkspace as t } from "../hooks/useWorkspaces.js";
3
- import { useScopedNavigation as n } from "../hooks/useScopedNavigation.js";
4
- import { tWithFallback as r } from "../utils/i18n.js";
5
- import { useWorkspacesPageView as i } from "../hooks/useWorkspacesPageView.js";
6
- import { useWorkspaceInvitations as a } from "../hooks/useWorkspaceMembers.js";
7
- import { useBulkCreateInvitations as ee, useCancelInvitation as te, useCreateInvitation as o, useResendInvitation as ne } from "../hooks/useMemberMutations.js";
8
- import { getProjectDisplayNames as re, getRoleDisplayNames as ie } from "../utils/invitationDisplay.js";
9
- import { useWorkspacePermissions as ae } from "../hooks/useWorkspacePermissions.js";
10
- import { useWorkspaceRoles as oe } from "../hooks/useWorkspaceRoles.js";
11
- import { useProjects as se } from "../hooks/useProjects.js";
1
+ import { tWithFallback as e } from "../utils/i18n.js";
2
+ import { getProjectDisplayNames as t, getRoleDisplayNames as n } from "../utils/invitationDisplay.js";
3
+ import { useScopedNavigation as r } from "../hooks/useScopedNavigation.js";
4
+ import { useWorkspacesContext as i } from "../providers/WorkspacesProvider.js";
5
+ import { useWorkspace as a } from "../hooks/useWorkspaces.js";
6
+ import { useWorkspacePermissions as ee } from "../hooks/useWorkspacePermissions.js";
7
+ import { useWorkspaceRoles as te } from "../hooks/useWorkspaceRoles.js";
8
+ import { useProjects as o } from "../hooks/useProjects.js";
9
+ import { useWorkspaceInvitations as ne } from "../hooks/useWorkspaceMembers.js";
10
+ import { useBulkCreateInvitations as re, useCancelInvitation as ie, useCreateInvitation as ae, useResendInvitation as oe } from "../hooks/useMemberMutations.js";
11
+ import { useWorkspacesPageView as se } from "../hooks/useWorkspacesPageView.js";
12
12
  import { downloadWorkspaceBulkInviteTemplate as ce, parseWorkspaceBulkInviteCsv as le } from "../utils/workspaceBulkInviteCsv.js";
13
13
  import { useMemo as s, useRef as ue, useState as c } from "react";
14
14
  import { AlertCircle as l, ArrowLeft as de, CheckCircle2 as u, Download as fe, Loader2 as d, Mail as pe, RefreshCw as me, Send as f, Upload as he, UserPlus as ge, XCircle as p } from "lucide-react";
@@ -17,8 +17,8 @@ import { Fragment as ve, jsx as m, jsxs as h } from "react/jsx-runtime";
17
17
  import { AlertDialog as ye, AlertDialogAction as be, AlertDialogCancel as xe, AlertDialogContent as Se, AlertDialogDescription as Ce, AlertDialogFooter as we, AlertDialogHeader as Te, AlertDialogTitle as Ee, Badge as g, Button as _, CardContent as v, CardHeader as y, CardTitle as b, Checkbox as x, GlassCard as S, IllustratedEmptyState as De, Input as Oe, NextSteps as ke, PagePurpose as Ae, ResponsiveTable as je, Skeleton as C, Tabs as Me, TabsContent as Ne, TabsList as Pe, TabsTrigger as Fe, Tooltip as w, TooltipContent as T, TooltipProvider as Ie, TooltipTrigger as E } from "@burdenoff/fe-libs/ui";
18
18
  import { useI18n as Le } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
19
19
  import { useNavigate as Re, useParams as ze } from "react-router";
20
- //#region src/pages/WorkspaceInvitePage.tsx
21
- var Be = 1024 * 1024, D = 500, Ve = [
20
+ // src/pages/WorkspaceInvitePage.tsx
21
+ var Be = 1048576, D = 500, Ve = [
22
22
  {
23
23
  key: "rowNumber",
24
24
  header: "#",
@@ -57,7 +57,7 @@ var Be = 1024 * 1024, D = 500, Ve = [
57
57
  className: "animate-spin"
58
58
  }), "Sending..."]
59
59
  }) : e.status.kind === "invited" ? /* @__PURE__ */ h("span", {
60
- className: "inline-flex items-center gap-1 text-green-700 dark:text-green-400",
60
+ className: "inline-flex items-center gap-1 text-status-success-text",
61
61
  children: [/* @__PURE__ */ m(u, { size: 14 }), "Invited"]
62
62
  }) : e.status.kind === "failed" ? /* @__PURE__ */ h("span", {
63
63
  className: "inline-flex items-center gap-1 text-status-error-text",
@@ -220,9 +220,9 @@ function Ke({ selectedRoleIds: e, onRoleToggle: t, selectedProjectIds: n, onProj
220
220
  });
221
221
  }
222
222
  function k() {
223
- let { workspaceId: _e } = ze(), { t: x } = Le(), w = Re(), { basePath: T = "/workspaces", workspaceId: Ie } = e(), { withCurrentSearch: E } = n(), k = _e || Ie || "";
224
- i("workspaces.invite", { workspaceId: k || void 0 });
225
- let { canInviteMember: qe, isLoading: Je } = ae(), { data: Ye, isLoading: Xe, error: Ze } = t(k), { data: A = [], isLoading: Qe } = oe(k), { data: j, isLoading: $e } = se({ archived: !1 }, { limit: 100 }, k), { data: et, isLoading: tt, isFetching: M, error: nt, refetch: rt } = a(k, "PENDING", { limit: 50 }, { retry: !1 }), N = s(() => (j?.items ?? []).filter((e) => !e.archived), [j?.items]), [it, at] = c("single"), [P, ot] = c(""), [F, st] = c([]), [I, ct] = c([]), [lt, L] = c(null), [ut, dt] = c(null), [ft, R] = c(null), [pt, z] = c(null), [B, V] = c(null), [H, U] = c([]), [mt, ht] = c(null), [gt, W] = c(!1), [G, _t] = c(!1), vt = ue(null), [K, yt] = c(null), { mutateAsync: bt, isPending: q } = o(k), { mutateAsync: xt, isPending: St } = ee(), { mutate: Ct, isPending: J } = ne(k), { mutate: wt, isPending: Y } = te(k), [Tt, X] = c(null), Z = et?.items ?? [], Et = q || St || G, Dt = s(() => A.filter((e) => F.includes(e.id)).map((e) => e.name), [A, F]), Ot = s(() => N.filter((e) => I.includes(e.id)).map((e) => e.name), [N, I]), Q = s(() => H.filter((e) => e.errors.length === 0 && e.status.kind !== "invited"), [H]), $ = s(() => H.filter((e) => e.errors.length > 0), [H]);
223
+ let { workspaceId: _e } = ze(), { t: x } = Le(), w = Re(), { basePath: T = "/workspaces", workspaceId: Ie } = i(), { withCurrentSearch: E } = r(), k = _e || Ie || "";
224
+ se("workspaces.invite", { workspaceId: k || void 0 });
225
+ let { canInviteMember: qe, isLoading: Je } = ee(), { data: Ye, isLoading: Xe, error: Ze } = a(k), { data: A = [], isLoading: Qe } = te(k), { data: j, isLoading: $e } = o({ archived: !1 }, { limit: 100 }, k), { data: et, isLoading: tt, isFetching: M, error: nt, refetch: rt } = ne(k, "PENDING", { limit: 50 }, { retry: !1 }), N = s(() => (j?.items ?? []).filter((e) => !e.archived), [j?.items]), [it, at] = c("single"), [P, ot] = c(""), [F, st] = c([]), [I, ct] = c([]), [lt, L] = c(null), [ut, dt] = c(null), [ft, R] = c(null), [pt, z] = c(null), [B, V] = c(null), [H, U] = c([]), [mt, ht] = c(null), [gt, _t] = c(!1), [W, vt] = c(!1), yt = ue(null), [G, bt] = c(null), { mutateAsync: xt, isPending: K } = ae(k), { mutateAsync: St, isPending: q } = re(), { mutate: Ct, isPending: J } = oe(k), { mutate: wt, isPending: Y } = ie(k), [Tt, X] = c(null), Z = et?.items ?? [], Et = K || q || W, Dt = s(() => A.filter((e) => F.includes(e.id)).map((e) => e.name), [A, F]), Ot = s(() => N.filter((e) => I.includes(e.id)).map((e) => e.name), [N, I]), Q = s(() => H.filter((e) => e.errors.length === 0 && e.status.kind !== "invited"), [H]), $ = s(() => H.filter((e) => e.errors.length > 0), [H]);
226
226
  if (!k) return /* @__PURE__ */ m("div", {
227
227
  className: "space-y-4 p-6",
228
228
  children: /* @__PURE__ */ h("div", {
@@ -230,18 +230,18 @@ function k() {
230
230
  children: [
231
231
  /* @__PURE__ */ m("h1", {
232
232
  className: "text-2xl font-bold",
233
- children: r(x, "workspaceInvite.noWorkspaceTitle", "Select a workspace first")
233
+ children: e(x, "workspaceInvite.noWorkspaceTitle", "Select a workspace first")
234
234
  }),
235
235
  /* @__PURE__ */ m("p", {
236
236
  className: "mt-2 text-text-secondary",
237
- children: r(x, "workspaceInvite.noWorkspaceDescription", "Choose a current workspace from the header or open a workspace detail page before inviting members.")
237
+ children: e(x, "workspaceInvite.noWorkspaceDescription", "Choose a current workspace from the header or open a workspace detail page before inviting members.")
238
238
  }),
239
239
  /* @__PURE__ */ m("div", {
240
240
  className: "mt-4",
241
241
  children: /* @__PURE__ */ m(_, {
242
242
  onClick: () => w(E(`${T}/list`)),
243
243
  variant: "outline",
244
- children: r(x, "workspaceInvite.backToWorkspaces", "Back to Workspaces")
244
+ children: e(x, "workspaceInvite.backToWorkspaces", "Back to Workspaces")
245
245
  })
246
246
  })
247
247
  ]
@@ -261,10 +261,10 @@ function k() {
261
261
  className: "space-y-2 text-center",
262
262
  children: [/* @__PURE__ */ m("h2", {
263
263
  className: "text-lg font-semibold",
264
- children: r(x, "workspaceInvite.accessDenied", "Access Denied")
264
+ children: e(x, "workspaceInvite.accessDenied", "Access Denied")
265
265
  }), /* @__PURE__ */ m("p", {
266
266
  className: "text-sm text-text-secondary",
267
- children: r(x, "workspaceInvite.accessDeniedDescription", "You don't have permission to invite members into this workspace.")
267
+ children: e(x, "workspaceInvite.accessDeniedDescription", "You don't have permission to invite members into this workspace.")
268
268
  })]
269
269
  })
270
270
  });
@@ -274,10 +274,10 @@ function k() {
274
274
  variant: "ghost",
275
275
  onClick: () => w(E(`${T}/list`)),
276
276
  className: "gap-2",
277
- children: [/* @__PURE__ */ m(de, { size: 18 }), r(x, "workspaceInvite.backToWorkspaces", "Back to Workspaces")]
277
+ children: [/* @__PURE__ */ m(de, { size: 18 }), e(x, "workspaceInvite.backToWorkspaces", "Back to Workspaces")]
278
278
  }), /* @__PURE__ */ m("div", {
279
279
  className: "rounded-xl border bg-bg-surface p-8 text-center text-status-error-text",
280
- children: r(x, "workspaceInvite.workspaceLoadError", "Unable to load workspace invite details.")
280
+ children: e(x, "workspaceInvite.workspaceLoadError", "Unable to load workspace invite details.")
281
281
  })]
282
282
  });
283
283
  let kt = (e, t) => {
@@ -285,12 +285,9 @@ function k() {
285
285
  }, At = (e, t) => {
286
286
  ct((n) => t ? [...n, e].filter((e, t, n) => n.indexOf(e) === t) : n.filter((t) => t !== e));
287
287
  }, jt = async (e) => {
288
- if (e.preventDefault(), L(null), dt(null), V(null), !P.trim()) {
289
- L("Email is required.");
290
- return;
291
- }
292
- try {
293
- await bt(Ge(k, P.trim().toLowerCase(), F, I)), ot(""), dt(`Invitation sent to ${P.trim().toLowerCase()}.`);
288
+ if (e.preventDefault(), L(null), dt(null), V(null), !P.trim()) L("Email is required.");
289
+ else try {
290
+ await xt(Ge(k, P.trim().toLowerCase(), F, I)), ot(""), dt(`Invitation sent to ${P.trim().toLowerCase()}.`);
294
291
  } catch (e) {
295
292
  L(O(e));
296
293
  }
@@ -305,22 +302,22 @@ function k() {
305
302
  }
306
303
  let t = new FileReader();
307
304
  t.onload = () => {
308
- let n = le(typeof t.result == "string" ? t.result : "");
309
- U(n.slice(0, D).map((e) => ({
305
+ let n = typeof t.result == "string" ? t.result : "", r = le(n), i = r.slice(0, D);
306
+ U(i.map((e) => ({
310
307
  ...e,
311
308
  status: { kind: "idle" }
312
- }))), ht(e.name), R(n.length > D ? `Only the first ${D} rows were loaded. Split larger CSV files into smaller batches.` : null), z(null), V(null);
309
+ }))), ht(e.name), R(r.length > D ? `Only the first ${D} rows were loaded. Split larger CSV files into smaller batches.` : null), z(null), V(null);
313
310
  }, t.onerror = () => {
314
311
  R("Failed to read CSV file.");
315
312
  }, t.readAsText(e);
316
313
  }, Nt = async () => {
317
- if (!(Q.length === 0 || G)) {
318
- R(null), z(null), V(null), _t(!0), U((e) => e.map((e) => e.errors.length === 0 && e.status.kind !== "invited" ? {
314
+ if (!(Q.length === 0 || W)) {
315
+ R(null), z(null), V(null), vt(!0), U((e) => e.map((e) => e.errors.length === 0 && e.status.kind !== "invited" ? {
319
316
  ...e,
320
317
  status: { kind: "sending" }
321
318
  } : e));
322
319
  try {
323
- await xt(Q.map((e) => Ge(k, e.email, F, I))), U((e) => e.map((e) => e.status.kind === "sending" ? {
320
+ await St(Q.map((e) => Ge(k, e.email, F, I))), U((e) => e.map((e) => e.status.kind === "sending" ? {
324
321
  ...e,
325
322
  status: { kind: "invited" }
326
323
  } : e)), z(`Sent ${Q.length} workspace invitation${Q.length === 1 ? "" : "s"}.`);
@@ -334,7 +331,7 @@ function k() {
334
331
  }
335
332
  } : e)), R(t);
336
333
  } finally {
337
- _t(!1);
334
+ vt(!1);
338
335
  }
339
336
  }
340
337
  }, Pt = (e) => {
@@ -355,19 +352,19 @@ function k() {
355
352
  });
356
353
  };
357
354
  return /* @__PURE__ */ h(ve, { children: [/* @__PURE__ */ m(ye, {
358
- open: !!K,
359
- onOpenChange: (e) => !e && yt(null),
360
- children: /* @__PURE__ */ h(Se, { children: [/* @__PURE__ */ h(Te, { children: [/* @__PURE__ */ m(Ee, { children: "Cancel pending invitation?" }), /* @__PURE__ */ m(Ce, { children: K ? `This will revoke the pending invite for ${K.email}. They will need a new invitation to join later.` : "This will revoke the pending invitation." })] }), /* @__PURE__ */ h(we, { children: [/* @__PURE__ */ m(xe, {
355
+ open: !!G,
356
+ onOpenChange: (e) => !e && bt(null),
357
+ children: /* @__PURE__ */ h(Se, { children: [/* @__PURE__ */ h(Te, { children: [/* @__PURE__ */ m(Ee, { children: "Cancel pending invitation?" }), /* @__PURE__ */ m(Ce, { children: G ? `This will revoke the pending invite for ${G.email}. They will need a new invitation to join later.` : "This will revoke the pending invitation." })] }), /* @__PURE__ */ h(we, { children: [/* @__PURE__ */ m(xe, {
361
358
  disabled: Y,
362
359
  children: "Keep invitation"
363
360
  }), /* @__PURE__ */ h(be, {
364
361
  onClick: () => {
365
- K && (V(null), X(K.id), wt(K.id, {
362
+ G && (V(null), X(G.id), wt(G.id, {
366
363
  onSuccess: () => {
367
364
  V({
368
365
  tone: "success",
369
- message: `Invitation cancelled for ${K.email}.`
370
- }), yt(null);
366
+ message: `Invitation cancelled for ${G.email}.`
367
+ }), bt(null);
371
368
  },
372
369
  onError: (e) => {
373
370
  V({
@@ -391,7 +388,7 @@ function k() {
391
388
  variant: "ghost",
392
389
  onClick: () => w(E(`${T}/${k}`)),
393
390
  className: "-ml-2 mb-2 gap-2",
394
- children: [/* @__PURE__ */ m(de, { size: 18 }), r(x, "workspaceInvite.backToWorkspace", "Back to Workspace")]
391
+ children: [/* @__PURE__ */ m(de, { size: 18 }), e(x, "workspaceInvite.backToWorkspace", "Back to Workspace")]
395
392
  }),
396
393
  /* @__PURE__ */ h("div", {
397
394
  className: "flex items-center gap-2",
@@ -400,7 +397,7 @@ function k() {
400
397
  size: 24
401
398
  }), /* @__PURE__ */ m("h1", {
402
399
  className: "text-2xl font-bold sm:text-3xl",
403
- children: r(x, "workspaceInvite.title", "Invite Members")
400
+ children: e(x, "workspaceInvite.title", "Invite Members")
404
401
  })]
405
402
  }),
406
403
  /* @__PURE__ */ h("p", {
@@ -409,19 +406,19 @@ function k() {
409
406
  Ye.name,
410
407
  " —",
411
408
  " ",
412
- r(x, "workspaceInvite.subtitle", "Invite people into this workspace and optionally grant project access.")
409
+ e(x, "workspaceInvite.subtitle", "Invite people into this workspace and optionally grant project access.")
413
410
  ]
414
411
  })
415
412
  ] })
416
413
  }),
417
- /* @__PURE__ */ m(Ae, { children: r(x, "workspaceInvite.purpose", "Use this page to bring new people into the workspace. First choose the roles and projects they should get the moment they accept, then send a single invitation by email or upload a CSV to invite many people at once. Invitations you have already sent appear at the bottom, where you can resend or cancel them.") }),
414
+ /* @__PURE__ */ m(Ae, { children: e(x, "workspaceInvite.purpose", "Use this page to bring new people into the workspace. First choose the roles and projects they should get the moment they accept, then send a single invitation by email or upload a CSV to invite many people at once. Invitations you have already sent appear at the bottom, where you can resend or cancel them.") }),
418
415
  /* @__PURE__ */ m(ke, {
419
416
  storageKey: "workspaces-workspace-invite",
420
417
  steps: [
421
418
  {
422
419
  id: "pick-access",
423
- label: r(x, "workspaceInvite.stepAccess", "Pick the roles and projects to grant"),
424
- description: r(x, "workspaceInvite.stepAccessDesc", "These are applied automatically when each person accepts."),
420
+ label: e(x, "workspaceInvite.stepAccess", "Pick the roles and projects to grant"),
421
+ description: e(x, "workspaceInvite.stepAccessDesc", "These are applied automatically when each person accepts."),
425
422
  icon: /* @__PURE__ */ m(ge, { size: 16 }),
426
423
  onClick: () => document.getElementById("invite-access-section")?.scrollIntoView({
427
424
  behavior: "smooth",
@@ -430,8 +427,8 @@ function k() {
430
427
  },
431
428
  {
432
429
  id: "send-invite",
433
- label: r(x, "workspaceInvite.stepSend", "Send the invitation"),
434
- description: r(x, "workspaceInvite.stepSendDesc", "Enter one email, or switch to the Bulk CSV tab to invite many at once."),
430
+ label: e(x, "workspaceInvite.stepSend", "Send the invitation"),
431
+ description: e(x, "workspaceInvite.stepSendDesc", "Enter one email, or switch to the Bulk CSV tab to invite many at once."),
435
432
  icon: /* @__PURE__ */ m(f, { size: 16 }),
436
433
  onClick: () => document.getElementById("invite-send-section")?.scrollIntoView({
437
434
  behavior: "smooth",
@@ -440,8 +437,8 @@ function k() {
440
437
  },
441
438
  {
442
439
  id: "review-pending",
443
- label: r(x, "workspaceInvite.stepPending", "Track your pending invitations"),
444
- description: r(x, "workspaceInvite.stepPendingDesc", "Resend or cancel invitations that have not been accepted yet."),
440
+ label: e(x, "workspaceInvite.stepPending", "Track your pending invitations"),
441
+ description: e(x, "workspaceInvite.stepPendingDesc", "Resend or cancel invitations that have not been accepted yet."),
445
442
  icon: /* @__PURE__ */ m(pe, { size: 16 }),
446
443
  onClick: () => document.getElementById("invite-pending-section")?.scrollIntoView({
447
444
  behavior: "smooth",
@@ -454,7 +451,7 @@ function k() {
454
451
  treatment: "plain",
455
452
  id: "invite-access-section",
456
453
  className: "border-border-seam",
457
- children: [/* @__PURE__ */ m(y, { children: /* @__PURE__ */ m(b, { children: r(x, "workspaceInvite.setupTitle", "Access to grant on acceptance") }) }), /* @__PURE__ */ m(v, { children: /* @__PURE__ */ m(Ke, {
454
+ children: [/* @__PURE__ */ m(y, { children: /* @__PURE__ */ m(b, { children: e(x, "workspaceInvite.setupTitle", "Access to grant on acceptance") }) }), /* @__PURE__ */ m(v, { children: /* @__PURE__ */ m(Ke, {
458
455
  selectedRoleIds: F,
459
456
  onRoleToggle: kt,
460
457
  selectedProjectIds: I,
@@ -511,17 +508,17 @@ function k() {
511
508
  treatment: "plain",
512
509
  id: "invite-send-section",
513
510
  className: "border-border-seam",
514
- children: [/* @__PURE__ */ m(y, { children: /* @__PURE__ */ m(b, { children: r(x, "workspaceInvite.sendTitle", "Send invitations") }) }), /* @__PURE__ */ m(v, { children: /* @__PURE__ */ h(Me, {
511
+ children: [/* @__PURE__ */ m(y, { children: /* @__PURE__ */ m(b, { children: e(x, "workspaceInvite.sendTitle", "Send invitations") }) }), /* @__PURE__ */ m(v, { children: /* @__PURE__ */ h(Me, {
515
512
  value: it,
516
513
  onValueChange: (e) => at(e),
517
514
  className: "space-y-5",
518
515
  children: [
519
516
  /* @__PURE__ */ h(Pe, { children: [/* @__PURE__ */ m(Fe, {
520
517
  value: "single",
521
- children: r(x, "workspaceInvite.modeSingle", "Single")
518
+ children: e(x, "workspaceInvite.modeSingle", "Single")
522
519
  }), /* @__PURE__ */ m(Fe, {
523
520
  value: "bulk",
524
- children: r(x, "workspaceInvite.modeBulk", "Bulk CSV")
521
+ children: e(x, "workspaceInvite.modeBulk", "Bulk CSV")
525
522
  })] }),
526
523
  /* @__PURE__ */ h(Ne, {
527
524
  value: "single",
@@ -532,7 +529,7 @@ function k() {
532
529
  children: [/* @__PURE__ */ m(l, { className: "size-4 shrink-0" }), /* @__PURE__ */ m("span", { children: lt })]
533
530
  }) : null,
534
531
  ut ? /* @__PURE__ */ h("div", {
535
- className: "flex items-center gap-2 rounded-md border border-green-500/20 bg-green-500/10 p-3 text-sm text-green-700 dark:text-green-400",
532
+ className: "flex items-center gap-2 rounded-md border border-status-success/30 bg-status-success/10 p-3 text-sm text-status-success-text",
536
533
  children: [/* @__PURE__ */ m(u, { className: "size-4 shrink-0" }), /* @__PURE__ */ m("span", { children: ut })]
537
534
  }) : null,
538
535
  /* @__PURE__ */ h("form", {
@@ -543,22 +540,22 @@ function k() {
543
540
  children: [/* @__PURE__ */ m("label", {
544
541
  htmlFor: "workspace-invite-email",
545
542
  className: "text-sm font-medium",
546
- children: r(x, "workspaceInvite.emailLabel", "Email Address")
543
+ children: e(x, "workspaceInvite.emailLabel", "Email Address")
547
544
  }), /* @__PURE__ */ m(Oe, {
548
545
  id: "workspace-invite-email",
549
546
  type: "email",
550
- placeholder: r(x, "workspaceInvite.emailPlaceholder", "member@example.com"),
547
+ placeholder: e(x, "workspaceInvite.emailPlaceholder", "member@example.com"),
551
548
  value: P,
552
549
  onChange: (e) => ot(e.target.value),
553
- disabled: q
550
+ disabled: K
554
551
  })]
555
552
  }), /* @__PURE__ */ m("div", {
556
553
  className: "flex justify-end",
557
554
  children: /* @__PURE__ */ h(_, {
558
555
  type: "submit",
559
- disabled: q,
556
+ disabled: K,
560
557
  className: "gap-2",
561
- children: [q ? /* @__PURE__ */ m(d, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(f, { className: "size-4" }), r(x, "workspaceInvite.sendSingleButton", "Send Invitation")]
558
+ children: [K ? /* @__PURE__ */ m(d, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(f, { className: "size-4" }), e(x, "workspaceInvite.sendSingleButton", "Send Invitation")]
562
559
  })
563
560
  })]
564
561
  })
@@ -573,7 +570,7 @@ function k() {
573
570
  children: [/* @__PURE__ */ m(l, { className: "size-4 shrink-0" }), /* @__PURE__ */ m("span", { children: ft })]
574
571
  }) : null,
575
572
  pt ? /* @__PURE__ */ h("div", {
576
- className: "flex items-center gap-2 rounded-md border border-green-500/20 bg-green-500/10 p-3 text-sm text-green-700 dark:text-green-400",
573
+ className: "flex items-center gap-2 rounded-md border border-status-success/30 bg-status-success/10 p-3 text-sm text-status-success-text",
577
574
  children: [/* @__PURE__ */ m(u, { className: "size-4 shrink-0" }), /* @__PURE__ */ m("span", { children: pt })]
578
575
  }) : null,
579
576
  /* @__PURE__ */ h("div", {
@@ -583,7 +580,7 @@ function k() {
583
580
  children: [
584
581
  /* @__PURE__ */ m("p", {
585
582
  className: "text-sm text-text-secondary",
586
- children: r(x, "workspaceInvite.bulkDescription", "Upload a CSV with one email column. All valid rows will receive the currently selected roles and projects.")
583
+ children: e(x, "workspaceInvite.bulkDescription", "Upload a CSV with one email column. All valid rows will receive the currently selected roles and projects.")
587
584
  }),
588
585
  /* @__PURE__ */ h("div", {
589
586
  className: "rounded-md border bg-bg-sunken/30 px-3 py-2 text-xs text-text-secondary",
@@ -615,16 +612,16 @@ function k() {
615
612
  variant: "outline",
616
613
  onClick: ce,
617
614
  className: "gap-2",
618
- children: [/* @__PURE__ */ m(fe, { size: 16 }), r(x, "workspaceInvite.downloadTemplate", "Download template")]
615
+ children: [/* @__PURE__ */ m(fe, { size: 16 }), e(x, "workspaceInvite.downloadTemplate", "Download template")]
619
616
  })]
620
617
  }),
621
618
  /* @__PURE__ */ h("div", {
622
619
  onDragOver: (e) => {
623
- e.preventDefault(), W(!0);
620
+ e.preventDefault(), _t(!0);
624
621
  },
625
- onDragLeave: () => W(!1),
622
+ onDragLeave: () => _t(!1),
626
623
  onDrop: (e) => {
627
- e.preventDefault(), W(!1);
624
+ e.preventDefault(), _t(!1);
628
625
  let t = e.dataTransfer.files?.[0];
629
626
  t ? Mt(t) : R("Please upload a .csv file.");
630
627
  },
@@ -645,7 +642,7 @@ function k() {
645
642
  })]
646
643
  }),
647
644
  /* @__PURE__ */ m("input", {
648
- ref: vt,
645
+ ref: yt,
649
646
  type: "file",
650
647
  accept: ".csv,text/csv",
651
648
  onChange: (e) => {
@@ -653,12 +650,12 @@ function k() {
653
650
  t && Mt(t), e.target.value = "";
654
651
  },
655
652
  className: "hidden",
656
- "aria-label": r(x, "workspaceInvite.chooseCsvFileAriaLabel", "Choose CSV file")
653
+ "aria-label": e(x, "workspaceInvite.chooseCsvFileAriaLabel", "Choose CSV file")
657
654
  }),
658
655
  /* @__PURE__ */ m(_, {
659
656
  type: "button",
660
- onClick: () => vt.current?.click(),
661
- children: r(x, "workspaceInvite.chooseFile", "Choose file")
657
+ onClick: () => yt.current?.click(),
658
+ children: e(x, "workspaceInvite.chooseFile", "Choose file")
662
659
  })
663
660
  ]
664
661
  }),
@@ -701,9 +698,9 @@ function k() {
701
698
  children: /* @__PURE__ */ h(_, {
702
699
  type: "button",
703
700
  onClick: Nt,
704
- disabled: Q.length === 0 || St || G,
701
+ disabled: Q.length === 0 || q || W,
705
702
  className: "gap-2",
706
- children: [St || G ? /* @__PURE__ */ m(d, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(f, { className: "size-4" }), r(x, "workspaceInvite.sendBulkButton", "Send Bulk Invites")]
703
+ children: [q || W ? /* @__PURE__ */ m(d, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(f, { className: "size-4" }), e(x, "workspaceInvite.sendBulkButton", "Send Bulk Invites")]
707
704
  })
708
705
  })
709
706
  ]
@@ -719,7 +716,7 @@ function k() {
719
716
  className: "flex items-center gap-2",
720
717
  children: [
721
718
  /* @__PURE__ */ m(pe, { className: "size-5 text-primary" }),
722
- r(x, "workspaceInvite.pendingTitle", "Pending Invitations"),
719
+ e(x, "workspaceInvite.pendingTitle", "Pending Invitations"),
723
720
  /* @__PURE__ */ m(g, {
724
721
  variant: "secondary",
725
722
  className: "tabular-nums",
@@ -727,7 +724,7 @@ function k() {
727
724
  })
728
725
  ]
729
726
  }) }), /* @__PURE__ */ h(v, { children: [B ? /* @__PURE__ */ h("div", {
730
- className: `mb-4 flex items-center gap-2 rounded-md border p-3 text-sm ${B.tone === "success" ? "border-green-500/20 bg-green-500/10 text-green-700 dark:text-green-400" : "border-status-error-border/20 bg-status-error-bg/10 text-status-error-text"}`,
727
+ className: `mb-4 flex items-center gap-2 rounded-md border p-3 text-sm ${B.tone === "success" ? "border-status-success/30 bg-status-success/10 text-status-success-text" : "border-status-error-border/20 bg-status-error-bg/10 text-status-error-text"}`,
731
728
  children: [B.tone === "success" ? /* @__PURE__ */ m(u, { className: "size-4 shrink-0" }) : /* @__PURE__ */ m(l, { className: "size-4 shrink-0" }), /* @__PURE__ */ m("span", { children: B.message })]
732
729
  }) : null, tt ? /* @__PURE__ */ h("div", {
733
730
  className: "space-y-3",
@@ -735,7 +732,7 @@ function k() {
735
732
  }) : nt && Z.length === 0 ? /* @__PURE__ */ h("div", {
736
733
  role: "alert",
737
734
  className: "space-y-3 rounded-md border border-status-error-border/20 bg-status-error-bg/10 p-3 text-sm text-status-error-text",
738
- children: [/* @__PURE__ */ m("p", { children: r(x, "workspaceInvite.pendingLoadFailed", "Failed to load pending invitations for this workspace.") }), /* @__PURE__ */ m(_, {
735
+ children: [/* @__PURE__ */ m("p", { children: e(x, "workspaceInvite.pendingLoadFailed", "Failed to load pending invitations for this workspace.") }), /* @__PURE__ */ m(_, {
739
736
  type: "button",
740
737
  variant: "outline",
741
738
  size: "sm",
@@ -744,18 +741,18 @@ function k() {
744
741
  onClick: () => {
745
742
  rt();
746
743
  },
747
- children: M ? r(x, "workspaceInvite.retrying", "Retrying…") : r(x, "workspaceInvite.tryAgain", "Try again")
744
+ children: M ? e(x, "workspaceInvite.retrying", "Retrying…") : e(x, "workspaceInvite.tryAgain", "Try again")
748
745
  })]
749
746
  }) : Z.length === 0 ? /* @__PURE__ */ m(De, {
750
747
  illustration: "empty-notifications",
751
- title: r(x, "workspaceInvite.pendingEmptyTitle", "No pending invitations"),
752
- description: r(x, "workspaceInvite.pendingEmpty", "Invitations you send for this workspace will show up here until they are accepted, so you can resend or cancel them.")
748
+ title: e(x, "workspaceInvite.pendingEmptyTitle", "No pending invitations"),
749
+ description: e(x, "workspaceInvite.pendingEmpty", "Invitations you send for this workspace will show up here until they are accepted, so you can resend or cancel them.")
753
750
  }) : /* @__PURE__ */ h("div", {
754
751
  className: "space-y-3",
755
752
  children: [nt ? /* @__PURE__ */ h("div", {
756
753
  role: "alert",
757
754
  className: "flex flex-wrap items-center justify-between gap-3 rounded-md border border-status-error-border/20 bg-status-error-bg/10 p-3 text-sm text-status-error-text",
758
- children: [/* @__PURE__ */ m("span", { children: r(x, "workspaceInvite.pendingStaleWarning", "Pending invitations may be outdated. Try again to refresh this list.") }), /* @__PURE__ */ m(_, {
755
+ children: [/* @__PURE__ */ m("span", { children: e(x, "workspaceInvite.pendingStaleWarning", "Pending invitations may be outdated. Try again to refresh this list.") }), /* @__PURE__ */ m(_, {
759
756
  type: "button",
760
757
  variant: "outline",
761
758
  size: "sm",
@@ -764,10 +761,10 @@ function k() {
764
761
  onClick: () => {
765
762
  rt();
766
763
  },
767
- children: M ? r(x, "workspaceInvite.retrying", "Retrying…") : r(x, "workspaceInvite.tryAgain", "Try again")
764
+ children: M ? e(x, "workspaceInvite.retrying", "Retrying…") : e(x, "workspaceInvite.tryAgain", "Try again")
768
765
  })]
769
766
  }) : null, Z.map((e) => {
770
- let t = ie(e), n = re(e), r = Tt === e.id && (J || Y);
767
+ let r = n(e), i = t(e), a = Tt === e.id && (J || Y);
771
768
  return /* @__PURE__ */ m("div", {
772
769
  className: "rounded-lg border p-4",
773
770
  children: /* @__PURE__ */ h("div", {
@@ -800,7 +797,7 @@ function k() {
800
797
  children: "Roles"
801
798
  }), /* @__PURE__ */ m("div", {
802
799
  className: "flex flex-wrap gap-2",
803
- children: t.length > 0 ? t.map((t, n) => /* @__PURE__ */ m(g, {
800
+ children: r.length > 0 ? r.map((t, n) => /* @__PURE__ */ m(g, {
804
801
  variant: "outline",
805
802
  children: t
806
803
  }, `${e.id}-${e.roleIds[n] ?? t}`)) : /* @__PURE__ */ m("span", {
@@ -813,7 +810,7 @@ function k() {
813
810
  children: "Projects"
814
811
  }), /* @__PURE__ */ m("div", {
815
812
  className: "flex flex-wrap gap-2",
816
- children: n.length > 0 ? n.map((t, n) => /* @__PURE__ */ m(g, {
813
+ children: i.length > 0 ? i.map((t, n) => /* @__PURE__ */ m(g, {
817
814
  variant: "secondary",
818
815
  children: t
819
816
  }, `${e.id}-project-${t}-${n}`)) : /* @__PURE__ */ m("span", {
@@ -830,14 +827,14 @@ function k() {
830
827
  disabled: J || Y,
831
828
  onClick: () => Pt(e),
832
829
  className: "gap-2",
833
- children: [r && J ? /* @__PURE__ */ m(me, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(me, { className: "size-4" }), "Resend"]
830
+ children: [a && J ? /* @__PURE__ */ m(me, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(me, { className: "size-4" }), "Resend"]
834
831
  }), /* @__PURE__ */ h(_, {
835
832
  type: "button",
836
833
  variant: "outline",
837
834
  disabled: J || Y,
838
- onClick: () => yt(e),
835
+ onClick: () => bt(e),
839
836
  className: "gap-2",
840
- children: [r && Y ? /* @__PURE__ */ m(d, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(p, { className: "size-4" }), "Cancel"]
837
+ children: [a && Y ? /* @__PURE__ */ m(d, { className: "size-4 animate-spin" }) : /* @__PURE__ */ m(p, { className: "size-4" }), "Cancel"]
841
838
  })]
842
839
  })]
843
840
  })
@@ -849,13 +846,12 @@ function k() {
849
846
  })] });
850
847
  }
851
848
  function qe() {
852
- let { workspaceId: t } = ze(), { workspaceId: n } = e();
849
+ let { workspaceId: e } = ze(), { workspaceId: t } = i();
853
850
  return /* @__PURE__ */ m(_e, {
854
- scopeId: t || n || null,
851
+ scopeId: e || t || null,
855
852
  gateway: "workspace",
856
853
  debug: !1,
857
854
  children: /* @__PURE__ */ m(k, {})
858
855
  });
859
856
  }
860
- //#endregion
861
857
  export { qe as WorkspaceInvitePage };