@burdenoff/microfe-organization 2026.601.8 → 2026.616.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.
- package/dist/generated/global-operations.js +78 -63
- package/dist/generated/global-operations.js.map +1 -1
- package/dist/generated/global-types.js.map +1 -1
- package/dist/organization-management/UserOrganizationRoutes.js +13 -9
- package/dist/organization-management/UserOrganizationRoutes.js.map +1 -1
- package/dist/organization-management/modules/members/hooks/useInvites.js +79 -65
- package/dist/organization-management/modules/members/hooks/useInvites.js.map +1 -1
- package/dist/organization-management/modules/members/pages/OrganizationInviteAcceptancePage.js +287 -0
- package/dist/organization-management/modules/members/pages/OrganizationInviteAcceptancePage.js.map +1 -0
- package/dist/organization-management/modules/organizations/components/OrganizationForm.js +112 -112
- package/dist/organization-management/modules/organizations/components/OrganizationForm.js.map +1 -1
- package/dist/organization-management/modules/organizations/pages/OrganizationCreatePage.js +8 -7
- package/dist/organization-management/modules/organizations/pages/OrganizationCreatePage.js.map +1 -1
- package/dist/organization-management/modules/workspaces/components/WorkspaceCard.js +2 -5
- package/dist/organization-management/modules/workspaces/components/WorkspaceCard.js.map +1 -1
- package/dist/organization-management/modules/workspaces/components/WorkspaceForm.js +86 -134
- package/dist/organization-management/modules/workspaces/components/WorkspaceForm.js.map +1 -1
- package/dist/organization-management/modules/workspaces/hooks/useWorkspaces.js.map +1 -1
- package/dist/organization-management/modules/workspaces/pages/WorkspaceDetailPage.js +4 -18
- package/dist/organization-management/modules/workspaces/pages/WorkspaceDetailPage.js.map +1 -1
- package/dist/organization-management/modules/workspaces/pages/WorkspacesListPage.js +4 -22
- package/dist/organization-management/modules/workspaces/pages/WorkspacesListPage.js.map +1 -1
- package/package.json +1 -1
package/dist/organization-management/modules/members/pages/OrganizationInviteAcceptancePage.js
ADDED
|
@@ -0,0 +1,287 @@
|
|
|
1
|
+
import { useOrgConsole as e } from "../../../providers/OrgConsoleProvider.js";
|
|
2
|
+
import { useAcceptInvite as t, useOrganizationInvite as n, useRejectInvite as r } from "../hooks/useInvites.js";
|
|
3
|
+
import { InviteStatus as i } from "../../../../generated/global-types.js";
|
|
4
|
+
import { useTr as a } from "../../../shared/hooks/useTr.js";
|
|
5
|
+
import { useOrganizationPageView as o } from "../../../hooks/useOrganizationPageView.js";
|
|
6
|
+
import { useState as s } from "react";
|
|
7
|
+
import { AlertTriangle as c, Ban as l, Building2 as u, CheckCircle as d, Clock as f, Home as p, Loader2 as m, Mail as h, XCircle as g } from "lucide-react";
|
|
8
|
+
import { Badge as _ } from "@burdenoff/fe-libs/ui";
|
|
9
|
+
import { jsx as v, jsxs as y } from "react/jsx-runtime";
|
|
10
|
+
import { useParams as b } from "react-router-dom";
|
|
11
|
+
//#region src/organization-management/modules/members/pages/OrganizationInviteAcceptancePage.tsx
|
|
12
|
+
function x(e) {
|
|
13
|
+
if (!e) return null;
|
|
14
|
+
let t = new Date(e);
|
|
15
|
+
return Number.isNaN(t.getTime()) ? null : t.toLocaleDateString("en-US", {
|
|
16
|
+
year: "numeric",
|
|
17
|
+
month: "long",
|
|
18
|
+
day: "numeric",
|
|
19
|
+
hour: "2-digit",
|
|
20
|
+
minute: "2-digit"
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
function S({ children: e }) {
|
|
24
|
+
return /* @__PURE__ */ v("div", {
|
|
25
|
+
className: "min-h-full bg-[var(--color-bg-canvas)] px-4 py-10 sm:px-6",
|
|
26
|
+
children: /* @__PURE__ */ v("div", {
|
|
27
|
+
className: "mx-auto max-w-2xl",
|
|
28
|
+
children: e
|
|
29
|
+
})
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
function C({ icon: e, iconClass: t, title: n, description: r, email: i, primaryLabel: a, onPrimary: o }) {
|
|
33
|
+
return /* @__PURE__ */ v(S, { children: /* @__PURE__ */ y("div", {
|
|
34
|
+
className: "rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] p-8 text-center",
|
|
35
|
+
children: [
|
|
36
|
+
/* @__PURE__ */ v("div", {
|
|
37
|
+
className: `mx-auto mb-4 flex size-14 items-center justify-center rounded-2xl ${t}`,
|
|
38
|
+
children: /* @__PURE__ */ v(e, { size: 28 })
|
|
39
|
+
}),
|
|
40
|
+
/* @__PURE__ */ v("h1", {
|
|
41
|
+
className: "text-2xl font-bold text-[var(--color-text-primary)]",
|
|
42
|
+
children: n
|
|
43
|
+
}),
|
|
44
|
+
/* @__PURE__ */ v("p", {
|
|
45
|
+
className: "mt-2 text-[var(--color-text-secondary)]",
|
|
46
|
+
children: r
|
|
47
|
+
}),
|
|
48
|
+
i ? /* @__PURE__ */ v("p", {
|
|
49
|
+
className: "mt-1 break-all text-sm text-[var(--color-text-muted)]",
|
|
50
|
+
children: i
|
|
51
|
+
}) : null,
|
|
52
|
+
/* @__PURE__ */ y("button", {
|
|
53
|
+
type: "button",
|
|
54
|
+
onClick: o,
|
|
55
|
+
className: "mt-6 inline-flex items-center gap-2 rounded-lg bg-[var(--color-action-primary-bg)] px-6 py-2.5 font-medium text-[var(--color-action-primary-text)] transition-all duration-200 hover:opacity-90 active:scale-[0.98]",
|
|
56
|
+
children: [/* @__PURE__ */ v(p, { size: 16 }), a]
|
|
57
|
+
})
|
|
58
|
+
]
|
|
59
|
+
}) });
|
|
60
|
+
}
|
|
61
|
+
function w() {
|
|
62
|
+
o("organizations.invite-acceptance");
|
|
63
|
+
let w = a(), { inviteId: T = "" } = b(), { basePath: E = "/organizations", navigate: D, currentUser: O, authToken: k } = e(), A = !!(k || O?.email), { invite: j, loading: M, error: N, refetch: P } = n(T, A), { acceptInvite: F } = t(), { rejectInvite: I } = r(), [L, R] = s(null), [z, B] = s(null), V = () => D(`${E}/invites/organizations`), H = async () => {
|
|
64
|
+
if (T) try {
|
|
65
|
+
R("accept"), B(null), await F(T), D(j?.organizationId ? `${E}/${j.organizationId}` : E);
|
|
66
|
+
} catch (e) {
|
|
67
|
+
B(e instanceof Error ? e.message : w("members.inviteAcceptance.acceptFailed", "Failed to accept invitation"));
|
|
68
|
+
} finally {
|
|
69
|
+
R(null);
|
|
70
|
+
}
|
|
71
|
+
}, U = async () => {
|
|
72
|
+
if (T) try {
|
|
73
|
+
R("reject"), B(null), await I(T), V();
|
|
74
|
+
} catch (e) {
|
|
75
|
+
B(e instanceof Error ? e.message : w("members.inviteAcceptance.rejectFailed", "Failed to reject invitation"));
|
|
76
|
+
} finally {
|
|
77
|
+
R(null);
|
|
78
|
+
}
|
|
79
|
+
};
|
|
80
|
+
if (!A) {
|
|
81
|
+
let e = encodeURIComponent(`${E}/invite/${T}`);
|
|
82
|
+
return /* @__PURE__ */ v(S, { children: /* @__PURE__ */ y("div", {
|
|
83
|
+
className: "rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] p-8",
|
|
84
|
+
children: [
|
|
85
|
+
/* @__PURE__ */ y("div", {
|
|
86
|
+
className: "mb-4 flex items-center gap-3",
|
|
87
|
+
children: [/* @__PURE__ */ v("div", {
|
|
88
|
+
className: "rounded-xl bg-[var(--color-bg-subtle)] p-3",
|
|
89
|
+
children: /* @__PURE__ */ v(h, {
|
|
90
|
+
size: 24,
|
|
91
|
+
className: "text-[var(--color-text-primary)]"
|
|
92
|
+
})
|
|
93
|
+
}), /* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("h1", {
|
|
94
|
+
className: "text-2xl font-bold text-[var(--color-text-primary)]",
|
|
95
|
+
children: w("members.inviteAcceptance.signInRequired", "Sign in to view your invitation")
|
|
96
|
+
}), /* @__PURE__ */ v("p", {
|
|
97
|
+
className: "text-[var(--color-text-secondary)]",
|
|
98
|
+
children: w("members.inviteAcceptance.signInDescription", "Organization invitations require an authenticated account before you can review or accept them.")
|
|
99
|
+
})] })]
|
|
100
|
+
}),
|
|
101
|
+
/* @__PURE__ */ v("p", {
|
|
102
|
+
className: "mb-6 text-sm text-[var(--color-text-muted)]",
|
|
103
|
+
children: w("members.inviteAcceptance.signInHint", "Use the same email address that received the invitation, then come back here to accept or decline it.")
|
|
104
|
+
}),
|
|
105
|
+
/* @__PURE__ */ y("div", {
|
|
106
|
+
className: "flex flex-col gap-3 sm:flex-row",
|
|
107
|
+
children: [/* @__PURE__ */ v("a", {
|
|
108
|
+
href: `/auth/login?returnTo=${e}`,
|
|
109
|
+
className: "inline-flex items-center justify-center gap-2 rounded-lg bg-[var(--color-action-primary-bg)] px-6 py-2.5 font-medium text-[var(--color-action-primary-text)] transition-all duration-200 hover:opacity-90 active:scale-[0.98]",
|
|
110
|
+
children: w("members.inviteAcceptance.signInButton", "Sign In")
|
|
111
|
+
}), /* @__PURE__ */ y("button", {
|
|
112
|
+
type: "button",
|
|
113
|
+
onClick: () => D(E),
|
|
114
|
+
className: "inline-flex items-center justify-center gap-2 rounded-lg border border-[var(--color-border-default)] bg-transparent px-6 py-2.5 font-medium text-[var(--color-text-primary)] transition-all duration-200 hover:bg-[var(--color-bg-subtle)] active:scale-[0.98]",
|
|
115
|
+
children: [/* @__PURE__ */ v(p, { size: 16 }), w("members.inviteAcceptance.backToOrganizations", "Back to Organizations")]
|
|
116
|
+
})]
|
|
117
|
+
})
|
|
118
|
+
]
|
|
119
|
+
}) });
|
|
120
|
+
}
|
|
121
|
+
if (M) return /* @__PURE__ */ v(S, { children: /* @__PURE__ */ v("div", {
|
|
122
|
+
className: "flex min-h-[300px] items-center justify-center rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)]",
|
|
123
|
+
children: /* @__PURE__ */ v(m, {
|
|
124
|
+
size: 28,
|
|
125
|
+
className: "animate-spin text-[var(--color-text-muted)]"
|
|
126
|
+
})
|
|
127
|
+
}) });
|
|
128
|
+
if (N) return /* @__PURE__ */ v(C, {
|
|
129
|
+
icon: c,
|
|
130
|
+
iconClass: "bg-[var(--color-status-error-bgSubtle)] text-[var(--color-status-error-text)]",
|
|
131
|
+
title: w("members.inviteAcceptance.errorTitle", "Error Loading Invitation"),
|
|
132
|
+
description: N.message,
|
|
133
|
+
primaryLabel: w("members.inviteAcceptance.tryAgain", "Try Again"),
|
|
134
|
+
onPrimary: () => {
|
|
135
|
+
P();
|
|
136
|
+
}
|
|
137
|
+
});
|
|
138
|
+
if (!j) return /* @__PURE__ */ v(C, {
|
|
139
|
+
icon: c,
|
|
140
|
+
iconClass: "bg-[var(--color-bg-subtle)] text-[var(--color-text-muted)]",
|
|
141
|
+
title: w("members.inviteAcceptance.notFoundTitle", "Invitation Not Found"),
|
|
142
|
+
description: w("members.inviteAcceptance.notFoundDescription", "This invitation link is invalid, has been removed, or was addressed to a different account."),
|
|
143
|
+
primaryLabel: w("members.inviteAcceptance.goToOrganizations", "Go to Organizations"),
|
|
144
|
+
onPrimary: () => D(E)
|
|
145
|
+
});
|
|
146
|
+
let W = j.expiresAt && new Date(j.expiresAt) < /* @__PURE__ */ new Date(), G = j.status === i.Pending && W ? i.Expired : j.status;
|
|
147
|
+
if (G === i.Accepted) return /* @__PURE__ */ v(C, {
|
|
148
|
+
icon: d,
|
|
149
|
+
iconClass: "bg-[var(--color-status-success-bgSubtle)] text-[var(--color-status-success-text)]",
|
|
150
|
+
title: w("members.inviteAcceptance.alreadyAcceptedTitle", "Invitation Already Accepted"),
|
|
151
|
+
description: w("members.inviteAcceptance.alreadyAcceptedDescription", "You have already accepted this invitation."),
|
|
152
|
+
email: j.email,
|
|
153
|
+
primaryLabel: w("members.inviteAcceptance.goToOrganization", "Go to Organization"),
|
|
154
|
+
onPrimary: () => D(`${E}/${j.organizationId}`)
|
|
155
|
+
});
|
|
156
|
+
if (G === i.Rejected) return /* @__PURE__ */ v(C, {
|
|
157
|
+
icon: g,
|
|
158
|
+
iconClass: "bg-[var(--color-bg-subtle)] text-[var(--color-text-muted)]",
|
|
159
|
+
title: w("members.inviteAcceptance.rejectedTitle", "Invitation Declined"),
|
|
160
|
+
description: w("members.inviteAcceptance.rejectedDescription", "This invitation was previously declined."),
|
|
161
|
+
email: j.email,
|
|
162
|
+
primaryLabel: w("members.inviteAcceptance.goToOrganizations", "Go to Organizations"),
|
|
163
|
+
onPrimary: () => D(E)
|
|
164
|
+
});
|
|
165
|
+
if (G === i.Expired) return /* @__PURE__ */ v(C, {
|
|
166
|
+
icon: f,
|
|
167
|
+
iconClass: "bg-[var(--color-status-warning-bgSubtle)] text-[var(--color-status-warning-text)]",
|
|
168
|
+
title: w("members.inviteAcceptance.expiredTitle", "Invitation Expired"),
|
|
169
|
+
description: w("members.inviteAcceptance.expiredDescription", "This invitation has expired. Please contact an organization admin for a new one."),
|
|
170
|
+
email: j.email,
|
|
171
|
+
primaryLabel: w("members.inviteAcceptance.goToOrganizations", "Go to Organizations"),
|
|
172
|
+
onPrimary: () => D(E)
|
|
173
|
+
});
|
|
174
|
+
if (G === i.Cancelled) return /* @__PURE__ */ v(C, {
|
|
175
|
+
icon: l,
|
|
176
|
+
iconClass: "bg-[var(--color-status-error-bgSubtle)] text-[var(--color-status-error-text)]",
|
|
177
|
+
title: w("members.inviteAcceptance.cancelledTitle", "Invitation Cancelled"),
|
|
178
|
+
description: w("members.inviteAcceptance.cancelledDescription", "This invitation was cancelled by the sender and is no longer valid."),
|
|
179
|
+
email: j.email,
|
|
180
|
+
primaryLabel: w("members.inviteAcceptance.goToOrganizations", "Go to Organizations"),
|
|
181
|
+
onPrimary: () => D(E)
|
|
182
|
+
});
|
|
183
|
+
let K = j.organization?.name ?? j.organizationId, q = x(j.expiresAt), J = L !== null;
|
|
184
|
+
return /* @__PURE__ */ v(S, { children: /* @__PURE__ */ y("div", {
|
|
185
|
+
className: "rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] p-8",
|
|
186
|
+
children: [
|
|
187
|
+
/* @__PURE__ */ y("div", {
|
|
188
|
+
className: "mb-6 flex items-center gap-3",
|
|
189
|
+
children: [/* @__PURE__ */ v("div", {
|
|
190
|
+
className: "rounded-xl bg-[var(--color-bg-subtle)] p-3",
|
|
191
|
+
children: /* @__PURE__ */ v(u, {
|
|
192
|
+
size: 24,
|
|
193
|
+
className: "text-[var(--color-text-primary)]"
|
|
194
|
+
})
|
|
195
|
+
}), /* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("h1", {
|
|
196
|
+
className: "text-2xl font-bold text-[var(--color-text-primary)]",
|
|
197
|
+
children: w("members.inviteAcceptance.pageTitle", "Organization Invitation")
|
|
198
|
+
}), /* @__PURE__ */ y("p", {
|
|
199
|
+
className: "text-[var(--color-text-secondary)]",
|
|
200
|
+
children: [
|
|
201
|
+
w("members.inviteAcceptance.pageSubtitle", "You've been invited to join"),
|
|
202
|
+
" ",
|
|
203
|
+
/* @__PURE__ */ v("span", {
|
|
204
|
+
className: "font-medium text-[var(--color-text-primary)]",
|
|
205
|
+
children: K
|
|
206
|
+
})
|
|
207
|
+
]
|
|
208
|
+
})] })]
|
|
209
|
+
}),
|
|
210
|
+
/* @__PURE__ */ y("dl", {
|
|
211
|
+
className: "space-y-4 rounded-xl bg-[var(--color-bg-subtle)] p-5",
|
|
212
|
+
children: [
|
|
213
|
+
/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
214
|
+
className: "text-sm font-medium text-[var(--color-text-muted)]",
|
|
215
|
+
children: w("members.inviteAcceptance.emailLabel", "Email Address")
|
|
216
|
+
}), /* @__PURE__ */ v("dd", {
|
|
217
|
+
className: "mt-1 break-all text-[var(--color-text-primary)]",
|
|
218
|
+
children: j.email
|
|
219
|
+
})] }),
|
|
220
|
+
/* @__PURE__ */ y("div", {
|
|
221
|
+
className: "flex flex-wrap items-center gap-2",
|
|
222
|
+
children: [/* @__PURE__ */ v("dt", {
|
|
223
|
+
className: "text-sm font-medium text-[var(--color-text-muted)]",
|
|
224
|
+
children: w("members.inviteAcceptance.roleLabel", "Role")
|
|
225
|
+
}), /* @__PURE__ */ v("dd", { children: /* @__PURE__ */ v(_, {
|
|
226
|
+
variant: "secondary",
|
|
227
|
+
children: j.role
|
|
228
|
+
}) })]
|
|
229
|
+
}),
|
|
230
|
+
q ? /* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
231
|
+
className: "text-sm font-medium text-[var(--color-text-muted)]",
|
|
232
|
+
children: w("members.inviteAcceptance.expiresLabel", "Expires")
|
|
233
|
+
}), /* @__PURE__ */ y("dd", {
|
|
234
|
+
className: "mt-1 flex items-center gap-2 text-[var(--color-text-primary)]",
|
|
235
|
+
children: [/* @__PURE__ */ v(f, {
|
|
236
|
+
size: 16,
|
|
237
|
+
className: "text-[var(--color-text-muted)]"
|
|
238
|
+
}), q]
|
|
239
|
+
})] }) : null,
|
|
240
|
+
j.message ? /* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("dt", {
|
|
241
|
+
className: "text-sm font-medium text-[var(--color-text-muted)]",
|
|
242
|
+
children: w("members.inviteAcceptance.messageLabel", "Message")
|
|
243
|
+
}), /* @__PURE__ */ v("dd", {
|
|
244
|
+
className: "mt-1 text-[var(--color-text-secondary)]",
|
|
245
|
+
children: j.message
|
|
246
|
+
})] }) : null
|
|
247
|
+
]
|
|
248
|
+
}),
|
|
249
|
+
z ? /* @__PURE__ */ y("div", {
|
|
250
|
+
className: "mt-4 flex items-center gap-2 rounded-lg border border-[var(--color-status-error-border)] bg-[var(--color-status-error-bgSubtle)] p-3",
|
|
251
|
+
children: [/* @__PURE__ */ v(c, {
|
|
252
|
+
size: 16,
|
|
253
|
+
className: "shrink-0 text-[var(--color-status-error-text)]"
|
|
254
|
+
}), /* @__PURE__ */ v("p", {
|
|
255
|
+
className: "text-sm text-[var(--color-status-error-text)]",
|
|
256
|
+
children: z
|
|
257
|
+
})]
|
|
258
|
+
}) : null,
|
|
259
|
+
/* @__PURE__ */ y("div", {
|
|
260
|
+
className: "mt-6 flex flex-col gap-3 border-t border-[var(--color-border-default)] pt-6 sm:flex-row",
|
|
261
|
+
children: [/* @__PURE__ */ y("button", {
|
|
262
|
+
type: "button",
|
|
263
|
+
onClick: () => void H(),
|
|
264
|
+
disabled: J,
|
|
265
|
+
className: "inline-flex flex-1 items-center justify-center gap-2 rounded-lg bg-[var(--color-status-success-bg)] px-6 py-3 font-medium text-[var(--color-text-inverse)] transition-all duration-200 hover:opacity-90 active:scale-[0.98] disabled:cursor-not-allowed disabled:opacity-50",
|
|
266
|
+
children: [L === "accept" ? /* @__PURE__ */ v(m, {
|
|
267
|
+
size: 16,
|
|
268
|
+
className: "animate-spin"
|
|
269
|
+
}) : /* @__PURE__ */ v(d, { size: 16 }), w("members.inviteAcceptance.acceptButton", "Accept Invitation")]
|
|
270
|
+
}), /* @__PURE__ */ y("button", {
|
|
271
|
+
type: "button",
|
|
272
|
+
onClick: () => void U(),
|
|
273
|
+
disabled: J,
|
|
274
|
+
className: "inline-flex flex-1 items-center justify-center gap-2 rounded-lg border border-[var(--color-border-default)] bg-transparent px-6 py-3 font-medium text-[var(--color-text-primary)] transition-all duration-200 hover:border-[var(--color-status-error-border)] hover:bg-[var(--color-status-error-bgSubtle)] hover:text-[var(--color-status-error-text)] active:scale-[0.98] disabled:cursor-not-allowed disabled:opacity-50",
|
|
275
|
+
children: [L === "reject" ? /* @__PURE__ */ v(m, {
|
|
276
|
+
size: 16,
|
|
277
|
+
className: "animate-spin"
|
|
278
|
+
}) : /* @__PURE__ */ v(g, { size: 16 }), w("members.inviteAcceptance.declineButton", "Decline")]
|
|
279
|
+
})]
|
|
280
|
+
})
|
|
281
|
+
]
|
|
282
|
+
}) });
|
|
283
|
+
}
|
|
284
|
+
//#endregion
|
|
285
|
+
export { w as OrganizationInviteAcceptancePage };
|
|
286
|
+
|
|
287
|
+
//# sourceMappingURL=OrganizationInviteAcceptancePage.js.map
|
package/dist/organization-management/modules/members/pages/OrganizationInviteAcceptancePage.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OrganizationInviteAcceptancePage.js","names":[],"sources":["../../../../../src/organization-management/modules/members/pages/OrganizationInviteAcceptancePage.tsx"],"sourcesContent":["import { useState } from 'react';\nimport { useParams } from 'react-router-dom';\nimport {\n Mail,\n Loader2,\n CheckCircle,\n XCircle,\n Clock,\n AlertTriangle,\n Ban,\n Home,\n Building2,\n} from 'lucide-react';\nimport { Badge } from '@burdenoff/fe-libs/ui';\nimport { useOrganizationInvite, useAcceptInvite, useRejectInvite } from '../hooks/useInvites';\nimport { InviteStatus } from '../../../../generated/global-types';\nimport { useTr } from '../../../shared/hooks/useTr';\nimport { useOrganizationPageView } from '../../../hooks/useOrganizationPageView';\nimport { useOrgConsole } from '../../../providers/OrgConsoleProvider';\n\n/**\n * OrganizationInviteAcceptancePage\n *\n * Per-invite acceptance page reached from the organization invite email link\n * (`/organizations/invite/:inviteId`). Mirrors the workspace invite-acceptance\n * flow: loads the single invite by id, renders the appropriate state machine\n * (PENDING → accept/reject, ACCEPTED/REJECTED/EXPIRED/CANCELLED), and gates the\n * unauthenticated case behind a sign-in CTA that returns the user here.\n *\n * The previous behaviour dropped the recipient on `/organizations/invites`\n * (the workspace-invites list tab) with no invite context, which rendered as\n * an empty page. The email now deep-links here with the invite id.\n */\nfunction formatDate(value?: string | null): string | null {\n if (!value) return null;\n const date = new Date(value);\n if (Number.isNaN(date.getTime())) return null;\n return date.toLocaleDateString('en-US', {\n year: 'numeric',\n month: 'long',\n day: 'numeric',\n hour: '2-digit',\n minute: '2-digit',\n });\n}\n\nfunction PageShell({ children }: { children: React.ReactNode }) {\n return (\n <div className=\"min-h-full bg-[var(--color-bg-canvas)] px-4 py-10 sm:px-6\">\n <div className=\"mx-auto max-w-2xl\">{children}</div>\n </div>\n );\n}\n\ninterface StatusViewProps {\n icon: typeof CheckCircle;\n iconClass: string;\n title: string;\n description: string;\n email?: string;\n primaryLabel: string;\n onPrimary: () => void;\n}\n\nfunction StatusView({\n icon: Icon,\n iconClass,\n title,\n description,\n email,\n primaryLabel,\n onPrimary,\n}: StatusViewProps) {\n return (\n <PageShell>\n <div className=\"rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] p-8 text-center\">\n <div\n className={`mx-auto mb-4 flex size-14 items-center justify-center rounded-2xl ${iconClass}`}\n >\n <Icon size={28} />\n </div>\n <h1 className=\"text-2xl font-bold text-[var(--color-text-primary)]\">{title}</h1>\n <p className=\"mt-2 text-[var(--color-text-secondary)]\">{description}</p>\n {email ? (\n <p className=\"mt-1 break-all text-sm text-[var(--color-text-muted)]\">{email}</p>\n ) : null}\n <button\n type=\"button\"\n onClick={onPrimary}\n className=\"mt-6 inline-flex items-center gap-2 rounded-lg bg-[var(--color-action-primary-bg)] px-6 py-2.5 font-medium text-[var(--color-action-primary-text)] transition-all duration-200 hover:opacity-90 active:scale-[0.98]\"\n >\n <Home size={16} />\n {primaryLabel}\n </button>\n </div>\n </PageShell>\n );\n}\n\nexport function OrganizationInviteAcceptancePage() {\n useOrganizationPageView('organizations.invite-acceptance');\n const tr = useTr();\n const { inviteId = '' } = useParams<{ inviteId: string }>();\n const { basePath = '/organizations', navigate, currentUser, authToken } = useOrgConsole();\n\n const isAuthenticated = Boolean(authToken || currentUser?.email);\n const { invite, loading, error, refetch } = useOrganizationInvite(inviteId, isAuthenticated);\n const { acceptInvite } = useAcceptInvite();\n const { rejectInvite } = useRejectInvite();\n\n const [processing, setProcessing] = useState<'accept' | 'reject' | null>(null);\n const [actionError, setActionError] = useState<string | null>(null);\n\n const goToInvitesList = () => navigate(`${basePath}/invites/organizations`);\n\n const handleAccept = async () => {\n if (!inviteId) return;\n try {\n setProcessing('accept');\n setActionError(null);\n await acceptInvite(inviteId);\n navigate(invite?.organizationId ? `${basePath}/${invite.organizationId}` : basePath);\n } catch (err) {\n setActionError(\n err instanceof Error\n ? err.message\n : tr('members.inviteAcceptance.acceptFailed', 'Failed to accept invitation')\n );\n } finally {\n setProcessing(null);\n }\n };\n\n const handleReject = async () => {\n if (!inviteId) return;\n try {\n setProcessing('reject');\n setActionError(null);\n await rejectInvite(inviteId);\n goToInvitesList();\n } catch (err) {\n setActionError(\n err instanceof Error\n ? err.message\n : tr('members.inviteAcceptance.rejectFailed', 'Failed to reject invitation')\n );\n } finally {\n setProcessing(null);\n }\n };\n\n // Unauthenticated — invitees must sign in with the invited email first.\n if (!isAuthenticated) {\n const returnTo = encodeURIComponent(`${basePath}/invite/${inviteId}`);\n return (\n <PageShell>\n <div className=\"rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] p-8\">\n <div className=\"mb-4 flex items-center gap-3\">\n <div className=\"rounded-xl bg-[var(--color-bg-subtle)] p-3\">\n <Mail size={24} className=\"text-[var(--color-text-primary)]\" />\n </div>\n <div>\n <h1 className=\"text-2xl font-bold text-[var(--color-text-primary)]\">\n {tr('members.inviteAcceptance.signInRequired', 'Sign in to view your invitation')}\n </h1>\n <p className=\"text-[var(--color-text-secondary)]\">\n {tr(\n 'members.inviteAcceptance.signInDescription',\n 'Organization invitations require an authenticated account before you can review or accept them.'\n )}\n </p>\n </div>\n </div>\n <p className=\"mb-6 text-sm text-[var(--color-text-muted)]\">\n {tr(\n 'members.inviteAcceptance.signInHint',\n 'Use the same email address that received the invitation, then come back here to accept or decline it.'\n )}\n </p>\n <div className=\"flex flex-col gap-3 sm:flex-row\">\n <a\n href={`/auth/login?returnTo=${returnTo}`}\n className=\"inline-flex items-center justify-center gap-2 rounded-lg bg-[var(--color-action-primary-bg)] px-6 py-2.5 font-medium text-[var(--color-action-primary-text)] transition-all duration-200 hover:opacity-90 active:scale-[0.98]\"\n >\n {tr('members.inviteAcceptance.signInButton', 'Sign In')}\n </a>\n <button\n type=\"button\"\n onClick={() => navigate(basePath)}\n className=\"inline-flex items-center justify-center gap-2 rounded-lg border border-[var(--color-border-default)] bg-transparent px-6 py-2.5 font-medium text-[var(--color-text-primary)] transition-all duration-200 hover:bg-[var(--color-bg-subtle)] active:scale-[0.98]\"\n >\n <Home size={16} />\n {tr('members.inviteAcceptance.backToOrganizations', 'Back to Organizations')}\n </button>\n </div>\n </div>\n </PageShell>\n );\n }\n\n if (loading) {\n return (\n <PageShell>\n <div className=\"flex min-h-[300px] items-center justify-center rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)]\">\n <Loader2 size={28} className=\"animate-spin text-[var(--color-text-muted)]\" />\n </div>\n </PageShell>\n );\n }\n\n if (error) {\n return (\n <StatusView\n icon={AlertTriangle}\n iconClass=\"bg-[var(--color-status-error-bgSubtle)] text-[var(--color-status-error-text)]\"\n title={tr('members.inviteAcceptance.errorTitle', 'Error Loading Invitation')}\n description={error.message}\n primaryLabel={tr('members.inviteAcceptance.tryAgain', 'Try Again')}\n onPrimary={() => {\n void refetch();\n }}\n />\n );\n }\n\n if (!invite) {\n return (\n <StatusView\n icon={AlertTriangle}\n iconClass=\"bg-[var(--color-bg-subtle)] text-[var(--color-text-muted)]\"\n title={tr('members.inviteAcceptance.notFoundTitle', 'Invitation Not Found')}\n description={tr(\n 'members.inviteAcceptance.notFoundDescription',\n 'This invitation link is invalid, has been removed, or was addressed to a different account.'\n )}\n primaryLabel={tr('members.inviteAcceptance.goToOrganizations', 'Go to Organizations')}\n onPrimary={() => navigate(basePath)}\n />\n );\n }\n\n const isExpiredByDate = invite.expiresAt && new Date(invite.expiresAt) < new Date();\n const effectiveStatus =\n invite.status === InviteStatus.Pending && isExpiredByDate\n ? InviteStatus.Expired\n : invite.status;\n\n if (effectiveStatus === InviteStatus.Accepted) {\n return (\n <StatusView\n icon={CheckCircle}\n iconClass=\"bg-[var(--color-status-success-bgSubtle)] text-[var(--color-status-success-text)]\"\n title={tr('members.inviteAcceptance.alreadyAcceptedTitle', 'Invitation Already Accepted')}\n description={tr(\n 'members.inviteAcceptance.alreadyAcceptedDescription',\n 'You have already accepted this invitation.'\n )}\n email={invite.email}\n primaryLabel={tr('members.inviteAcceptance.goToOrganization', 'Go to Organization')}\n onPrimary={() => navigate(`${basePath}/${invite.organizationId}`)}\n />\n );\n }\n\n if (effectiveStatus === InviteStatus.Rejected) {\n return (\n <StatusView\n icon={XCircle}\n iconClass=\"bg-[var(--color-bg-subtle)] text-[var(--color-text-muted)]\"\n title={tr('members.inviteAcceptance.rejectedTitle', 'Invitation Declined')}\n description={tr(\n 'members.inviteAcceptance.rejectedDescription',\n 'This invitation was previously declined.'\n )}\n email={invite.email}\n primaryLabel={tr('members.inviteAcceptance.goToOrganizations', 'Go to Organizations')}\n onPrimary={() => navigate(basePath)}\n />\n );\n }\n\n if (effectiveStatus === InviteStatus.Expired) {\n return (\n <StatusView\n icon={Clock}\n iconClass=\"bg-[var(--color-status-warning-bgSubtle)] text-[var(--color-status-warning-text)]\"\n title={tr('members.inviteAcceptance.expiredTitle', 'Invitation Expired')}\n description={tr(\n 'members.inviteAcceptance.expiredDescription',\n 'This invitation has expired. Please contact an organization admin for a new one.'\n )}\n email={invite.email}\n primaryLabel={tr('members.inviteAcceptance.goToOrganizations', 'Go to Organizations')}\n onPrimary={() => navigate(basePath)}\n />\n );\n }\n\n if (effectiveStatus === InviteStatus.Cancelled) {\n return (\n <StatusView\n icon={Ban}\n iconClass=\"bg-[var(--color-status-error-bgSubtle)] text-[var(--color-status-error-text)]\"\n title={tr('members.inviteAcceptance.cancelledTitle', 'Invitation Cancelled')}\n description={tr(\n 'members.inviteAcceptance.cancelledDescription',\n 'This invitation was cancelled by the sender and is no longer valid.'\n )}\n email={invite.email}\n primaryLabel={tr('members.inviteAcceptance.goToOrganizations', 'Go to Organizations')}\n onPrimary={() => navigate(basePath)}\n />\n );\n }\n\n // PENDING — show the acceptance UI.\n const organizationName = invite.organization?.name ?? invite.organizationId;\n const expiresLabel = formatDate(invite.expiresAt);\n const busy = processing !== null;\n\n return (\n <PageShell>\n <div className=\"rounded-2xl border border-[var(--color-border-default)] bg-[var(--color-bg-surface)] p-8\">\n <div className=\"mb-6 flex items-center gap-3\">\n <div className=\"rounded-xl bg-[var(--color-bg-subtle)] p-3\">\n <Building2 size={24} className=\"text-[var(--color-text-primary)]\" />\n </div>\n <div>\n <h1 className=\"text-2xl font-bold text-[var(--color-text-primary)]\">\n {tr('members.inviteAcceptance.pageTitle', 'Organization Invitation')}\n </h1>\n <p className=\"text-[var(--color-text-secondary)]\">\n {tr('members.inviteAcceptance.pageSubtitle', \"You've been invited to join\")}{' '}\n <span className=\"font-medium text-[var(--color-text-primary)]\">\n {organizationName}\n </span>\n </p>\n </div>\n </div>\n\n <dl className=\"space-y-4 rounded-xl bg-[var(--color-bg-subtle)] p-5\">\n <div>\n <dt className=\"text-sm font-medium text-[var(--color-text-muted)]\">\n {tr('members.inviteAcceptance.emailLabel', 'Email Address')}\n </dt>\n <dd className=\"mt-1 break-all text-[var(--color-text-primary)]\">{invite.email}</dd>\n </div>\n <div className=\"flex flex-wrap items-center gap-2\">\n <dt className=\"text-sm font-medium text-[var(--color-text-muted)]\">\n {tr('members.inviteAcceptance.roleLabel', 'Role')}\n </dt>\n <dd>\n <Badge variant=\"secondary\">{invite.role}</Badge>\n </dd>\n </div>\n {expiresLabel ? (\n <div>\n <dt className=\"text-sm font-medium text-[var(--color-text-muted)]\">\n {tr('members.inviteAcceptance.expiresLabel', 'Expires')}\n </dt>\n <dd className=\"mt-1 flex items-center gap-2 text-[var(--color-text-primary)]\">\n <Clock size={16} className=\"text-[var(--color-text-muted)]\" />\n {expiresLabel}\n </dd>\n </div>\n ) : null}\n {invite.message ? (\n <div>\n <dt className=\"text-sm font-medium text-[var(--color-text-muted)]\">\n {tr('members.inviteAcceptance.messageLabel', 'Message')}\n </dt>\n <dd className=\"mt-1 text-[var(--color-text-secondary)]\">{invite.message}</dd>\n </div>\n ) : null}\n </dl>\n\n {actionError ? (\n <div className=\"mt-4 flex items-center gap-2 rounded-lg border border-[var(--color-status-error-border)] bg-[var(--color-status-error-bgSubtle)] p-3\">\n <AlertTriangle size={16} className=\"shrink-0 text-[var(--color-status-error-text)]\" />\n <p className=\"text-sm text-[var(--color-status-error-text)]\">{actionError}</p>\n </div>\n ) : null}\n\n <div className=\"mt-6 flex flex-col gap-3 border-t border-[var(--color-border-default)] pt-6 sm:flex-row\">\n <button\n type=\"button\"\n onClick={() => void handleAccept()}\n disabled={busy}\n className=\"inline-flex flex-1 items-center justify-center gap-2 rounded-lg bg-[var(--color-status-success-bg)] px-6 py-3 font-medium text-[var(--color-text-inverse)] transition-all duration-200 hover:opacity-90 active:scale-[0.98] disabled:cursor-not-allowed disabled:opacity-50\"\n >\n {processing === 'accept' ? (\n <Loader2 size={16} className=\"animate-spin\" />\n ) : (\n <CheckCircle size={16} />\n )}\n {tr('members.inviteAcceptance.acceptButton', 'Accept Invitation')}\n </button>\n <button\n type=\"button\"\n onClick={() => void handleReject()}\n disabled={busy}\n className=\"inline-flex flex-1 items-center justify-center gap-2 rounded-lg border border-[var(--color-border-default)] bg-transparent px-6 py-3 font-medium text-[var(--color-text-primary)] transition-all duration-200 hover:border-[var(--color-status-error-border)] hover:bg-[var(--color-status-error-bgSubtle)] hover:text-[var(--color-status-error-text)] active:scale-[0.98] disabled:cursor-not-allowed disabled:opacity-50\"\n >\n {processing === 'reject' ? (\n <Loader2 size={16} className=\"animate-spin\" />\n ) : (\n <XCircle size={16} />\n )}\n {tr('members.inviteAcceptance.declineButton', 'Decline')}\n </button>\n </div>\n </div>\n </PageShell>\n );\n}\n"],"mappings":";;;;;;;;;;;AAiCA,SAAS,EAAW,GAAsC;AACxD,KAAI,CAAC,EAAO,QAAO;CACnB,IAAM,IAAO,IAAI,KAAK,EAAM;AAE5B,QADI,OAAO,MAAM,EAAK,SAAS,CAAC,GAAS,OAClC,EAAK,mBAAmB,SAAS;EACtC,MAAM;EACN,OAAO;EACP,KAAK;EACL,MAAM;EACN,QAAQ;EACT,CAAC;;AAGJ,SAAS,EAAU,EAAE,eAA2C;AAC9D,QACE,kBAAC,OAAD;EAAK,WAAU;YACb,kBAAC,OAAD;GAAK,WAAU;GAAqB;GAAe,CAAA;EAC/C,CAAA;;AAcV,SAAS,EAAW,EAClB,MAAM,GACN,cACA,UACA,gBACA,UACA,iBACA,gBACkB;AAClB,QACE,kBAAC,GAAD,EAAA,UACE,kBAAC,OAAD;EAAK,WAAU;YAAf;GACE,kBAAC,OAAD;IACE,WAAW,qEAAqE;cAEhF,kBAAC,GAAD,EAAM,MAAM,I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