@burdenoff/microfe-eventfullymanaged 2026.723.1 → 2026.728.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/eventfullymanaged/api/eventApi.d.ts +22 -0
- package/dist/eventfullymanaged/api/eventApi.d.ts.map +1 -1
- package/dist/eventfullymanaged/api/eventApi.js +74 -54
- package/dist/eventfullymanaged/api/eventApi.js.map +1 -1
- package/dist/eventfullymanaged/lib/offlineCheckInQueue.d.ts +54 -0
- package/dist/eventfullymanaged/lib/offlineCheckInQueue.d.ts.map +1 -0
- package/dist/eventfullymanaged/lib/offlineCheckInQueue.js +68 -0
- package/dist/eventfullymanaged/lib/offlineCheckInQueue.js.map +1 -0
- package/dist/eventfullymanaged/lib/useOfflineCheckInSync.d.ts +29 -0
- package/dist/eventfullymanaged/lib/useOfflineCheckInSync.d.ts.map +1 -0
- package/dist/eventfullymanaged/lib/useOfflineCheckInSync.js +73 -0
- package/dist/eventfullymanaged/lib/useOfflineCheckInSync.js.map +1 -0
- package/dist/eventfullymanaged/pages/modules/KioskPage.d.ts.map +1 -1
- package/dist/eventfullymanaged/pages/modules/KioskPage.js +381 -311
- package/dist/eventfullymanaged/pages/modules/KioskPage.js.map +1 -1
- package/dist/eventfullymanaged/pages/modules/RegistrationPage.d.ts.map +1 -1
- package/dist/eventfullymanaged/pages/modules/RegistrationPage.js +236 -182
- package/dist/eventfullymanaged/pages/modules/RegistrationPage.js.map +1 -1
- package/dist/eventfullymanaged/types/index.d.ts.map +1 -1
- package/package.json +3 -2
|
@@ -1,23 +1,59 @@
|
|
|
1
1
|
import { useEventfullyManaged as e } from "../../context/EventfullyManagedContext.js";
|
|
2
2
|
import { notify as t } from "../../lib/toast.js";
|
|
3
|
-
import { useAttendeesQuery as n,
|
|
4
|
-
import { ActionMenu as
|
|
5
|
-
import { Pagination as
|
|
6
|
-
import { mutationSucceeded as
|
|
7
|
-
import { formatMoney as
|
|
8
|
-
import { useMemo as
|
|
9
|
-
import { jsx as
|
|
10
|
-
import { Megaphone as
|
|
11
|
-
import { Badge as
|
|
3
|
+
import { useAttendeesQuery as n, useCheckInTokenQuery as r, useDeleteAttendeeMutation as i, useDeletePromoCodeMutation as a, useDeleteRegistrationMutation as o, usePromoCodesQuery as s, useRegistrationsQuery as c, useTicketTypesQuery as l, useUpdateRegistrationMutation as u } from "../../api/eventApi.js";
|
|
4
|
+
import { ActionMenu as d } from "../../components/ActionMenu.js";
|
|
5
|
+
import { Pagination as f, usePagination as p } from "../../components/Pagination.js";
|
|
6
|
+
import { mutationSucceeded as m } from "../../lib/mutationResult.js";
|
|
7
|
+
import { formatMoney as h } from "../../lib/format.js";
|
|
8
|
+
import { useMemo as g, useState as _ } from "react";
|
|
9
|
+
import { Fragment as v, jsx as y, jsxs as b } from "react/jsx-runtime";
|
|
10
|
+
import { Megaphone as x, QrCode as S, Tag as C, TicketPlus as w, UserPlus as T, Users as E } from "lucide-react";
|
|
11
|
+
import { Badge as D, Button as O, EmphasisPanel as k, GlassCard as A, GradientText as j, IllustratedEmptyState as M, NextSteps as N, PagePurpose as P, ResponsiveDialog as F, ResponsiveDialogContent as I, ResponsiveDialogDescription as L, ResponsiveDialogFooter as R, ResponsiveDialogHeader as z, ResponsiveDialogTitle as B, ResponsiveTable as V } from "@burdenoff/fe-libs/ui";
|
|
12
12
|
//#region src/eventfullymanaged/pages/modules/RegistrationPage.tsx
|
|
13
|
-
|
|
13
|
+
function H({ registrationId: e, label: t, onOpenChange: n }) {
|
|
14
|
+
let { data: i, loading: a, error: o } = r(e), s = i?.checkInToken;
|
|
15
|
+
return /* @__PURE__ */ y(F, {
|
|
16
|
+
open: !0,
|
|
17
|
+
onOpenChange: n,
|
|
18
|
+
children: /* @__PURE__ */ b(I, {
|
|
19
|
+
className: "max-w-sm",
|
|
20
|
+
children: [
|
|
21
|
+
/* @__PURE__ */ b(z, { children: [/* @__PURE__ */ y(B, { children: "Check-in QR" }), /* @__PURE__ */ b(L, { children: [t, " scans this code at any check-in station to check in — it works even if the station has no connection at the moment."] })] }),
|
|
22
|
+
/* @__PURE__ */ y("div", {
|
|
23
|
+
className: "flex flex-col items-center gap-3 py-2",
|
|
24
|
+
children: a ? /* @__PURE__ */ y("p", {
|
|
25
|
+
className: "text-sm text-text-secondary",
|
|
26
|
+
children: "Generating…"
|
|
27
|
+
}) : o || !s ? /* @__PURE__ */ y("p", {
|
|
28
|
+
className: "text-sm text-status-danger-text",
|
|
29
|
+
children: "Could not generate a check-in QR for this registration."
|
|
30
|
+
}) : /* @__PURE__ */ b(v, { children: [/* @__PURE__ */ y("img", {
|
|
31
|
+
src: s.qrDataUrl,
|
|
32
|
+
alt: `Check-in QR code for ${t}`,
|
|
33
|
+
className: "h-56 w-56 rounded-card border border-border-seam bg-white p-2"
|
|
34
|
+
}), /* @__PURE__ */ y("code", {
|
|
35
|
+
className: "max-w-full break-all rounded bg-bg-sunken px-2 py-1 text-xs text-text-secondary",
|
|
36
|
+
children: s.token
|
|
37
|
+
})] })
|
|
38
|
+
}),
|
|
39
|
+
/* @__PURE__ */ y(R, { children: /* @__PURE__ */ y(O, {
|
|
40
|
+
type: "button",
|
|
41
|
+
variant: "outline",
|
|
42
|
+
onClick: () => n(!1),
|
|
43
|
+
children: "Close"
|
|
44
|
+
}) })
|
|
45
|
+
]
|
|
46
|
+
})
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
var U = [
|
|
14
50
|
"PENDING",
|
|
15
51
|
"CONFIRMED",
|
|
16
52
|
"WAITLISTED",
|
|
17
53
|
"CANCELLED",
|
|
18
54
|
"CHECKED_IN"
|
|
19
55
|
];
|
|
20
|
-
function
|
|
56
|
+
function W(e) {
|
|
21
57
|
switch ((e ?? "").toUpperCase()) {
|
|
22
58
|
case "CONFIRMED":
|
|
23
59
|
case "CHECKED_IN": return "default";
|
|
@@ -26,47 +62,47 @@ function N(e) {
|
|
|
26
62
|
default: return "secondary";
|
|
27
63
|
}
|
|
28
64
|
}
|
|
29
|
-
function
|
|
30
|
-
if (t == null || t <= 0) return /* @__PURE__ */
|
|
65
|
+
function G({ used: e, max: t }) {
|
|
66
|
+
if (t == null || t <= 0) return /* @__PURE__ */ b("span", {
|
|
31
67
|
className: "text-xs text-text-secondary",
|
|
32
68
|
children: [e, " used"]
|
|
33
69
|
});
|
|
34
70
|
let n = Math.min(100, Math.round(e / t * 100));
|
|
35
|
-
return /* @__PURE__ */
|
|
71
|
+
return /* @__PURE__ */ b("div", {
|
|
36
72
|
className: "min-w-[7rem] space-y-1",
|
|
37
|
-
children: [/* @__PURE__ */
|
|
73
|
+
children: [/* @__PURE__ */ b("div", {
|
|
38
74
|
className: "flex items-center justify-between text-xs tabular-nums text-text-secondary",
|
|
39
|
-
children: [/* @__PURE__ */
|
|
75
|
+
children: [/* @__PURE__ */ b("span", { children: [
|
|
40
76
|
e,
|
|
41
77
|
" / ",
|
|
42
78
|
t
|
|
43
|
-
] }), /* @__PURE__ */
|
|
79
|
+
] }), /* @__PURE__ */ b("span", {
|
|
44
80
|
className: "text-text-muted",
|
|
45
81
|
children: [n, "%"]
|
|
46
82
|
})]
|
|
47
|
-
}), /* @__PURE__ */
|
|
83
|
+
}), /* @__PURE__ */ y("div", {
|
|
48
84
|
className: "h-1.5 w-full overflow-hidden rounded-full bg-bg-sunken",
|
|
49
|
-
children: /* @__PURE__ */
|
|
85
|
+
children: /* @__PURE__ */ y("div", {
|
|
50
86
|
className: `h-full rounded-full ${n >= 90 ? "bg-status-warning" : "bg-action-primary-bg"}`,
|
|
51
87
|
style: { width: `${n}%` }
|
|
52
88
|
})
|
|
53
89
|
})]
|
|
54
90
|
});
|
|
55
91
|
}
|
|
56
|
-
function
|
|
57
|
-
return /* @__PURE__ */
|
|
92
|
+
function K({ icon: e, title: t, count: n, loading: r, action: i, children: a }) {
|
|
93
|
+
return /* @__PURE__ */ b(A, {
|
|
58
94
|
treatment: "plain",
|
|
59
95
|
className: "border-border-seam p-5",
|
|
60
|
-
children: [/* @__PURE__ */
|
|
96
|
+
children: [/* @__PURE__ */ b("div", {
|
|
61
97
|
className: "flex items-center justify-between gap-3",
|
|
62
|
-
children: [/* @__PURE__ */
|
|
98
|
+
children: [/* @__PURE__ */ b("div", {
|
|
63
99
|
className: "flex items-center gap-3",
|
|
64
|
-
children: [/* @__PURE__ */
|
|
100
|
+
children: [/* @__PURE__ */ y("span", {
|
|
65
101
|
className: "flex h-9 w-9 items-center justify-center rounded-input bg-accent-wash text-action-primary",
|
|
66
102
|
children: e
|
|
67
|
-
}), /* @__PURE__ */
|
|
103
|
+
}), /* @__PURE__ */ b("h2", {
|
|
68
104
|
className: "text-lg font-semibold text-text-primary",
|
|
69
|
-
children: [r ? `Loading ${t.toLowerCase()}…` : t, !r && n != null ? /* @__PURE__ */
|
|
105
|
+
children: [r ? `Loading ${t.toLowerCase()}…` : t, !r && n != null ? /* @__PURE__ */ b("span", {
|
|
70
106
|
className: "ml-2 text-sm font-normal text-text-secondary",
|
|
71
107
|
children: [
|
|
72
108
|
"(",
|
|
@@ -76,32 +112,32 @@ function F({ icon: e, title: t, count: n, loading: r, action: i, children: a })
|
|
|
76
112
|
}) : null]
|
|
77
113
|
})]
|
|
78
114
|
}), i]
|
|
79
|
-
}), /* @__PURE__ */
|
|
115
|
+
}), /* @__PURE__ */ y("div", {
|
|
80
116
|
className: "mt-4",
|
|
81
117
|
children: a
|
|
82
118
|
})]
|
|
83
119
|
});
|
|
84
120
|
}
|
|
85
|
-
function
|
|
86
|
-
let e =
|
|
121
|
+
function q() {
|
|
122
|
+
let e = p({ pageSize: 10 }), { data: r, loading: i } = c({
|
|
87
123
|
limit: e.limit,
|
|
88
124
|
offset: e.offset
|
|
89
|
-
}), [
|
|
125
|
+
}), [a] = u(), [s] = o(), [v, x] = _(null), { data: C } = n({
|
|
90
126
|
limit: 200,
|
|
91
127
|
offset: 0
|
|
92
|
-
}), { data:
|
|
128
|
+
}), { data: T } = l({
|
|
93
129
|
limit: 200,
|
|
94
130
|
offset: 0
|
|
95
|
-
}),
|
|
131
|
+
}), E = g(() => {
|
|
96
132
|
let e = /* @__PURE__ */ new Map();
|
|
97
|
-
for (let t of
|
|
133
|
+
for (let t of C?.attendees.items ?? []) t.id && t.fullName && e.set(t.id, t.fullName);
|
|
98
134
|
return e;
|
|
99
|
-
}, [
|
|
135
|
+
}, [C]), O = g(() => {
|
|
100
136
|
let e = /* @__PURE__ */ new Map();
|
|
101
|
-
for (let t of
|
|
137
|
+
for (let t of T?.ticketTypes.items ?? []) t.id && t.name && e.set(t.id, t.name);
|
|
102
138
|
return e;
|
|
103
|
-
}, [
|
|
104
|
-
let r = await
|
|
139
|
+
}, [T]), k = (e) => e ? E.get(e) ?? `Attendee ${e.slice(0, 8)}…` : null, A = g(() => r?.registrations.items ?? [], [r]), j = r?.registrations.total ?? 0, N = async (e, n) => {
|
|
140
|
+
let r = await a({ variables: {
|
|
105
141
|
id: e.id,
|
|
106
142
|
input: {
|
|
107
143
|
eventId: e.eventId,
|
|
@@ -113,129 +149,147 @@ function I() {
|
|
|
113
149
|
status: n
|
|
114
150
|
}
|
|
115
151
|
} });
|
|
116
|
-
|
|
117
|
-
},
|
|
118
|
-
let r = await
|
|
152
|
+
m(r, r.data?.updateRegistration?.id, "Could not update registration") && t.success("Registration updated", `Status set to ${n}`);
|
|
153
|
+
}, P = async (e, n) => {
|
|
154
|
+
let r = await s({ variables: { id: e.id } });
|
|
119
155
|
if (r.error) throw t.error("Could not delete registration", r.error.message), r.error;
|
|
120
156
|
if (!r.data?.deleteRegistration) throw t.error("Could not delete registration", "The server did not confirm the change."), Error("delete-unconfirmed");
|
|
121
157
|
t.success("Registration deleted", n);
|
|
122
|
-
},
|
|
123
|
-
return /* @__PURE__ */
|
|
124
|
-
icon: /* @__PURE__ */
|
|
158
|
+
}, F = (e) => k(e.attendeeId) ?? `Registration ${e.id}`;
|
|
159
|
+
return /* @__PURE__ */ b(K, {
|
|
160
|
+
icon: /* @__PURE__ */ y(w, { className: "h-4 w-4" }),
|
|
125
161
|
title: "Registrations",
|
|
126
|
-
count:
|
|
162
|
+
count: j,
|
|
127
163
|
loading: i,
|
|
128
|
-
children: [
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
ariaLabel: "Registration actions",
|
|
187
|
-
entityName: t,
|
|
188
|
-
deleteLabel: "Delete registration",
|
|
189
|
-
extraItems: M.filter((t) => t !== (e.status ?? "").toUpperCase()).map((t, n) => ({
|
|
164
|
+
children: [
|
|
165
|
+
/* @__PURE__ */ y(V, {
|
|
166
|
+
columns: [
|
|
167
|
+
{
|
|
168
|
+
key: "name",
|
|
169
|
+
header: "Name",
|
|
170
|
+
priority: "primary",
|
|
171
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
172
|
+
className: "font-medium text-text-primary",
|
|
173
|
+
children: F(e)
|
|
174
|
+
})
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
key: "ticket",
|
|
178
|
+
header: "Ticket Type",
|
|
179
|
+
mobileLabel: "Ticket",
|
|
180
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
181
|
+
className: "text-text-secondary",
|
|
182
|
+
children: e.ticketTypeId ? O.get(e.ticketTypeId) ?? "—" : "—"
|
|
183
|
+
})
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
key: "quantity",
|
|
187
|
+
header: "Qty",
|
|
188
|
+
mobileLabel: "Quantity",
|
|
189
|
+
priority: "secondary",
|
|
190
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
191
|
+
className: "tabular-nums text-text-secondary",
|
|
192
|
+
children: e.quantity
|
|
193
|
+
})
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
key: "amount",
|
|
197
|
+
header: "Amount",
|
|
198
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
199
|
+
className: "tabular-nums text-text-primary",
|
|
200
|
+
children: e.totalAmount ? h(Number(e.totalAmount), e.currency) : "—"
|
|
201
|
+
})
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
key: "status",
|
|
205
|
+
header: "Status",
|
|
206
|
+
priority: "primary",
|
|
207
|
+
cell: (e) => /* @__PURE__ */ y(D, {
|
|
208
|
+
variant: W(e.status),
|
|
209
|
+
children: e.status ?? "UNKNOWN"
|
|
210
|
+
})
|
|
211
|
+
}
|
|
212
|
+
],
|
|
213
|
+
data: A,
|
|
214
|
+
rowKey: (e) => e.id,
|
|
215
|
+
emptyState: i ? null : /* @__PURE__ */ y(M, {
|
|
216
|
+
illustration: "empty-data",
|
|
217
|
+
title: "No registrations yet.",
|
|
218
|
+
description: "Register your first attendee to start tracking sign-ups."
|
|
219
|
+
}),
|
|
220
|
+
rowActions: (e) => {
|
|
221
|
+
let t = F(e), n = U.filter((t) => t !== (e.status ?? "").toUpperCase()).map((t, n) => ({
|
|
190
222
|
key: t,
|
|
191
223
|
label: `Set ${t.replace("_", " ").toLowerCase()}`,
|
|
192
|
-
onSelect: () => void
|
|
224
|
+
onSelect: () => void N(e, t),
|
|
193
225
|
separatorBefore: n === 0
|
|
194
|
-
}))
|
|
195
|
-
|
|
226
|
+
}));
|
|
227
|
+
return /* @__PURE__ */ y(d, {
|
|
228
|
+
ariaLabel: "Registration actions",
|
|
229
|
+
entityName: t,
|
|
230
|
+
deleteLabel: "Delete registration",
|
|
231
|
+
extraItems: [{
|
|
232
|
+
key: "view-qr",
|
|
233
|
+
label: "View check-in QR",
|
|
234
|
+
icon: S,
|
|
235
|
+
onSelect: () => x(e.id)
|
|
236
|
+
}, ...n],
|
|
237
|
+
onDelete: () => P(e, t)
|
|
238
|
+
});
|
|
239
|
+
}
|
|
240
|
+
}),
|
|
241
|
+
/* @__PURE__ */ y(f, {
|
|
242
|
+
offset: e.offset,
|
|
243
|
+
limit: e.limit,
|
|
244
|
+
loadedCount: A.length,
|
|
245
|
+
total: j,
|
|
246
|
+
onPrev: e.prevPage,
|
|
247
|
+
onNext: e.nextPage,
|
|
248
|
+
itemLabel: "registrations",
|
|
249
|
+
loading: i
|
|
250
|
+
}),
|
|
251
|
+
v ? (() => {
|
|
252
|
+
let e = A.find((e) => e.id === v);
|
|
253
|
+
return /* @__PURE__ */ y(H, {
|
|
254
|
+
registrationId: v,
|
|
255
|
+
label: e ? F(e) : `Registration ${v}`,
|
|
256
|
+
onOpenChange: (e) => {
|
|
257
|
+
e || x(null);
|
|
258
|
+
}
|
|
196
259
|
});
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
offset: e.offset,
|
|
200
|
-
limit: e.limit,
|
|
201
|
-
loadedCount: E.length,
|
|
202
|
-
total: D,
|
|
203
|
-
onPrev: e.prevPage,
|
|
204
|
-
onNext: e.nextPage,
|
|
205
|
-
itemLabel: "registrations",
|
|
206
|
-
loading: i
|
|
207
|
-
})]
|
|
260
|
+
})() : null
|
|
261
|
+
]
|
|
208
262
|
});
|
|
209
263
|
}
|
|
210
|
-
function
|
|
211
|
-
let { navigate:
|
|
264
|
+
function J() {
|
|
265
|
+
let { navigate: r } = e(), a = p({ pageSize: 10 }), { data: o, loading: s } = n({
|
|
212
266
|
limit: a.limit,
|
|
213
267
|
offset: a.offset
|
|
214
|
-
}), [c] =
|
|
268
|
+
}), [c] = i(), l = g(() => o?.attendees.items ?? [], [o]), u = o?.attendees.total ?? 0, m = async (e) => {
|
|
215
269
|
let n = await c({ variables: { id: e.id } });
|
|
216
270
|
if (n.error) throw t.error("Could not delete attendee", n.error.message), n.error;
|
|
217
271
|
if (!n.data?.deleteAttendee) throw t.error("Could not delete attendee", "The server did not confirm the change."), Error("delete-unconfirmed");
|
|
218
272
|
t.success("Attendee deleted", e.fullName);
|
|
219
273
|
};
|
|
220
|
-
return /* @__PURE__ */
|
|
221
|
-
icon: /* @__PURE__ */
|
|
274
|
+
return /* @__PURE__ */ b(K, {
|
|
275
|
+
icon: /* @__PURE__ */ y(E, { className: "h-4 w-4" }),
|
|
222
276
|
title: "Attendees",
|
|
223
|
-
count:
|
|
277
|
+
count: u,
|
|
224
278
|
loading: s,
|
|
225
|
-
action: /* @__PURE__ */
|
|
279
|
+
action: /* @__PURE__ */ b(O, {
|
|
226
280
|
type: "button",
|
|
227
281
|
size: "sm",
|
|
228
282
|
variant: "outline",
|
|
229
|
-
onClick: () =>
|
|
230
|
-
children: [/* @__PURE__ */
|
|
283
|
+
onClick: () => r("/registration/attendees/create"),
|
|
284
|
+
children: [/* @__PURE__ */ y(T, { className: "h-4 w-4" }), "Add attendee"]
|
|
231
285
|
}),
|
|
232
|
-
children: [/* @__PURE__ */
|
|
286
|
+
children: [/* @__PURE__ */ y(V, {
|
|
233
287
|
columns: [
|
|
234
288
|
{
|
|
235
289
|
key: "name",
|
|
236
290
|
header: "Name",
|
|
237
291
|
priority: "primary",
|
|
238
|
-
cell: (e) => /* @__PURE__ */
|
|
292
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
239
293
|
className: "font-medium text-text-primary",
|
|
240
294
|
children: e.fullName
|
|
241
295
|
})
|
|
@@ -244,7 +298,7 @@ function L() {
|
|
|
244
298
|
key: "email",
|
|
245
299
|
header: "Email",
|
|
246
300
|
priority: "primary",
|
|
247
|
-
cell: (e) => /* @__PURE__ */
|
|
301
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
248
302
|
className: "text-text-secondary",
|
|
249
303
|
children: e.email
|
|
250
304
|
})
|
|
@@ -252,7 +306,7 @@ function L() {
|
|
|
252
306
|
{
|
|
253
307
|
key: "company",
|
|
254
308
|
header: "Company",
|
|
255
|
-
cell: (e) => /* @__PURE__ */
|
|
309
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
256
310
|
className: "text-text-secondary",
|
|
257
311
|
children: [e.company, e.role].filter(Boolean).join(" · ") || "—"
|
|
258
312
|
})
|
|
@@ -260,24 +314,24 @@ function L() {
|
|
|
260
314
|
],
|
|
261
315
|
data: l,
|
|
262
316
|
rowKey: (e) => e.id,
|
|
263
|
-
emptyState: s ? null : /* @__PURE__ */
|
|
317
|
+
emptyState: s ? null : /* @__PURE__ */ y(M, {
|
|
264
318
|
illustration: "empty-people",
|
|
265
319
|
title: "No attendees yet.",
|
|
266
320
|
description: "Add attendees or register one to build your guest list."
|
|
267
321
|
}),
|
|
268
|
-
rowActions: (e) => /* @__PURE__ */
|
|
322
|
+
rowActions: (e) => /* @__PURE__ */ y(d, {
|
|
269
323
|
ariaLabel: `Actions for ${e.fullName}`,
|
|
270
324
|
entityName: e.fullName,
|
|
271
325
|
deleteLabel: "Delete attendee",
|
|
272
|
-
onView: () =>
|
|
273
|
-
onEdit: () =>
|
|
326
|
+
onView: () => r(`/attendees/${e.id}/profile`),
|
|
327
|
+
onEdit: () => r(`/registration/attendees/${e.id}/edit`),
|
|
274
328
|
onDelete: () => m(e)
|
|
275
329
|
})
|
|
276
|
-
}), /* @__PURE__ */
|
|
330
|
+
}), /* @__PURE__ */ y(f, {
|
|
277
331
|
offset: a.offset,
|
|
278
332
|
limit: a.limit,
|
|
279
333
|
loadedCount: l.length,
|
|
280
|
-
total:
|
|
334
|
+
total: u,
|
|
281
335
|
onPrev: a.prevPage,
|
|
282
336
|
onNext: a.nextPage,
|
|
283
337
|
itemLabel: "attendees",
|
|
@@ -285,34 +339,34 @@ function L() {
|
|
|
285
339
|
})]
|
|
286
340
|
});
|
|
287
341
|
}
|
|
288
|
-
function
|
|
289
|
-
let { navigate: n } = e(), r =
|
|
342
|
+
function Y() {
|
|
343
|
+
let { navigate: n } = e(), r = p({ pageSize: 10 }), { data: i, loading: o } = s({
|
|
290
344
|
limit: r.limit,
|
|
291
345
|
offset: r.offset
|
|
292
|
-
}), [c] =
|
|
346
|
+
}), [c] = a(), l = g(() => i?.promoCodes.items ?? [], [i]), u = i?.promoCodes.total ?? 0, m = async (e) => {
|
|
293
347
|
let n = await c({ variables: { id: e.id } });
|
|
294
348
|
if (n.error) throw t.error("Could not delete promo code", n.error.message), n.error;
|
|
295
349
|
t.success("Promo code deleted", e.code);
|
|
296
350
|
};
|
|
297
|
-
return /* @__PURE__ */
|
|
298
|
-
icon: /* @__PURE__ */
|
|
351
|
+
return /* @__PURE__ */ b(K, {
|
|
352
|
+
icon: /* @__PURE__ */ y(C, { className: "h-4 w-4" }),
|
|
299
353
|
title: "Promo Codes",
|
|
300
|
-
count:
|
|
301
|
-
loading:
|
|
302
|
-
action: /* @__PURE__ */
|
|
354
|
+
count: u,
|
|
355
|
+
loading: o,
|
|
356
|
+
action: /* @__PURE__ */ b(O, {
|
|
303
357
|
type: "button",
|
|
304
358
|
size: "sm",
|
|
305
359
|
variant: "outline",
|
|
306
360
|
onClick: () => n("/registration/promo-codes/create"),
|
|
307
|
-
children: [/* @__PURE__ */
|
|
361
|
+
children: [/* @__PURE__ */ y(w, { className: "h-4 w-4" }), "New promo code"]
|
|
308
362
|
}),
|
|
309
|
-
children: [/* @__PURE__ */
|
|
363
|
+
children: [/* @__PURE__ */ y(V, {
|
|
310
364
|
columns: [
|
|
311
365
|
{
|
|
312
366
|
key: "code",
|
|
313
367
|
header: "Code",
|
|
314
368
|
priority: "primary",
|
|
315
|
-
cell: (e) => /* @__PURE__ */
|
|
369
|
+
cell: (e) => /* @__PURE__ */ y("span", {
|
|
316
370
|
className: "font-mono text-sm font-semibold text-text-primary",
|
|
317
371
|
children: e.code
|
|
318
372
|
})
|
|
@@ -321,12 +375,12 @@ function R() {
|
|
|
321
375
|
key: "discount",
|
|
322
376
|
header: "Discount",
|
|
323
377
|
priority: "primary",
|
|
324
|
-
cell: (e) => /* @__PURE__ */
|
|
378
|
+
cell: (e) => /* @__PURE__ */ b("span", {
|
|
325
379
|
className: "flex items-center gap-2",
|
|
326
|
-
children: [/* @__PURE__ */
|
|
380
|
+
children: [/* @__PURE__ */ y(D, {
|
|
327
381
|
variant: "secondary",
|
|
328
382
|
children: e.discountType === "PERCENT" ? "PERCENT" : "FIXED"
|
|
329
|
-
}), /* @__PURE__ */
|
|
383
|
+
}), /* @__PURE__ */ y("span", {
|
|
330
384
|
className: "text-sm text-text-secondary",
|
|
331
385
|
children: e.discountType === "PERCENT" ? `${e.discountValue}%` : e.discountValue
|
|
332
386
|
})]
|
|
@@ -335,7 +389,7 @@ function R() {
|
|
|
335
389
|
{
|
|
336
390
|
key: "usage",
|
|
337
391
|
header: "Usage",
|
|
338
|
-
cell: (e) => /* @__PURE__ */
|
|
392
|
+
cell: (e) => /* @__PURE__ */ y(G, {
|
|
339
393
|
used: e.usedCount,
|
|
340
394
|
max: e.maxUses
|
|
341
395
|
})
|
|
@@ -344,7 +398,7 @@ function R() {
|
|
|
344
398
|
key: "status",
|
|
345
399
|
header: "Status",
|
|
346
400
|
priority: "secondary",
|
|
347
|
-
cell: (e) => /* @__PURE__ */
|
|
401
|
+
cell: (e) => /* @__PURE__ */ y(D, {
|
|
348
402
|
variant: e.isActive ? "default" : "secondary",
|
|
349
403
|
children: e.isActive ? "Active" : "Inactive"
|
|
350
404
|
})
|
|
@@ -352,70 +406,70 @@ function R() {
|
|
|
352
406
|
],
|
|
353
407
|
data: l,
|
|
354
408
|
rowKey: (e) => e.id,
|
|
355
|
-
emptyState:
|
|
409
|
+
emptyState: o ? null : /* @__PURE__ */ y(M, {
|
|
356
410
|
illustration: "empty-data",
|
|
357
411
|
title: "No promo codes yet.",
|
|
358
412
|
description: "Create a code to offer discounts and drive registrations."
|
|
359
413
|
}),
|
|
360
|
-
rowActions: (e) => /* @__PURE__ */
|
|
414
|
+
rowActions: (e) => /* @__PURE__ */ y(d, {
|
|
361
415
|
ariaLabel: `Actions for ${e.code}`,
|
|
362
416
|
entityName: e.code,
|
|
363
417
|
onEdit: () => n(`/registration/promo-codes/${e.id}/edit`),
|
|
364
418
|
onDelete: () => m(e)
|
|
365
419
|
})
|
|
366
|
-
}), /* @__PURE__ */
|
|
420
|
+
}), /* @__PURE__ */ y(f, {
|
|
367
421
|
offset: r.offset,
|
|
368
422
|
limit: r.limit,
|
|
369
423
|
loadedCount: l.length,
|
|
370
|
-
total:
|
|
424
|
+
total: u,
|
|
371
425
|
onPrev: r.prevPage,
|
|
372
426
|
onNext: r.nextPage,
|
|
373
427
|
itemLabel: "promo codes",
|
|
374
|
-
loading:
|
|
428
|
+
loading: o
|
|
375
429
|
})]
|
|
376
430
|
});
|
|
377
431
|
}
|
|
378
|
-
function
|
|
432
|
+
function X() {
|
|
379
433
|
let { navigate: t } = e();
|
|
380
|
-
return /* @__PURE__ */
|
|
434
|
+
return /* @__PURE__ */ b("div", {
|
|
381
435
|
className: "space-y-6 p-6",
|
|
382
436
|
children: [
|
|
383
|
-
/* @__PURE__ */
|
|
384
|
-
/* @__PURE__ */
|
|
437
|
+
/* @__PURE__ */ y(P, { children: "This is where you see who is coming. Registrations are the paid or confirmed sign-ups, attendees are the people behind them, and promo codes let you offer discounts. Register attendees, edit their details, change a registration's status, and manage discount codes — all backed by live GraphQL APIs." }),
|
|
438
|
+
/* @__PURE__ */ y(k, { children: /* @__PURE__ */ b("div", {
|
|
385
439
|
className: "flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between",
|
|
386
|
-
children: [/* @__PURE__ */
|
|
440
|
+
children: [/* @__PURE__ */ b("div", { children: [/* @__PURE__ */ y("h1", {
|
|
387
441
|
className: "text-2xl font-bold text-text-primary",
|
|
388
|
-
children: /* @__PURE__ */
|
|
389
|
-
}), /* @__PURE__ */
|
|
442
|
+
children: /* @__PURE__ */ y(j, { children: "Registration" })
|
|
443
|
+
}), /* @__PURE__ */ y("p", {
|
|
390
444
|
className: "mt-1 text-sm text-text-secondary",
|
|
391
445
|
children: "Track registrations, attendees, and promo codes with backend persistence."
|
|
392
|
-
})] }), /* @__PURE__ */
|
|
446
|
+
})] }), /* @__PURE__ */ b("div", {
|
|
393
447
|
className: "flex flex-wrap gap-2",
|
|
394
448
|
children: [
|
|
395
|
-
/* @__PURE__ */
|
|
449
|
+
/* @__PURE__ */ b(O, {
|
|
396
450
|
type: "button",
|
|
397
451
|
onClick: () => t("/registration/register"),
|
|
398
|
-
children: [/* @__PURE__ */
|
|
452
|
+
children: [/* @__PURE__ */ y(w, { className: "h-4 w-4" }), "Register attendee"]
|
|
399
453
|
}),
|
|
400
|
-
/* @__PURE__ */
|
|
454
|
+
/* @__PURE__ */ b(O, {
|
|
401
455
|
type: "button",
|
|
402
456
|
variant: "outline",
|
|
403
457
|
onClick: () => t("/registration/attendees/create"),
|
|
404
|
-
children: [/* @__PURE__ */
|
|
458
|
+
children: [/* @__PURE__ */ y(T, { className: "h-4 w-4" }), "Add attendee"]
|
|
405
459
|
}),
|
|
406
|
-
/* @__PURE__ */
|
|
460
|
+
/* @__PURE__ */ b(O, {
|
|
407
461
|
type: "button",
|
|
408
462
|
variant: "outline",
|
|
409
463
|
onClick: () => t("/registration/promo-codes/create"),
|
|
410
|
-
children: [/* @__PURE__ */
|
|
464
|
+
children: [/* @__PURE__ */ y(C, { className: "h-4 w-4" }), "New promo code"]
|
|
411
465
|
})
|
|
412
466
|
]
|
|
413
467
|
})]
|
|
414
468
|
}) }),
|
|
415
|
-
/* @__PURE__ */
|
|
416
|
-
/* @__PURE__ */
|
|
417
|
-
/* @__PURE__ */
|
|
418
|
-
/* @__PURE__ */
|
|
469
|
+
/* @__PURE__ */ y(q, {}),
|
|
470
|
+
/* @__PURE__ */ y(J, {}),
|
|
471
|
+
/* @__PURE__ */ y(Y, {}),
|
|
472
|
+
/* @__PURE__ */ y(N, {
|
|
419
473
|
storageKey: "eventfullymanaged-registration",
|
|
420
474
|
title: "Grow your registrations",
|
|
421
475
|
steps: [
|
|
@@ -423,21 +477,21 @@ function z() {
|
|
|
423
477
|
id: "view-networking",
|
|
424
478
|
label: "Set up attendee networking",
|
|
425
479
|
description: "Turn registered attendees into connections with matchmaking.",
|
|
426
|
-
icon: /* @__PURE__ */
|
|
480
|
+
icon: /* @__PURE__ */ y(E, { className: "h-4 w-4" }),
|
|
427
481
|
onClick: () => t("/networking")
|
|
428
482
|
},
|
|
429
483
|
{
|
|
430
484
|
id: "promote",
|
|
431
485
|
label: "Promote with a campaign",
|
|
432
486
|
description: "Send reminders and offers to drive more sign-ups.",
|
|
433
|
-
icon: /* @__PURE__ */
|
|
487
|
+
icon: /* @__PURE__ */ y(x, { className: "h-4 w-4" }),
|
|
434
488
|
onClick: () => t("/communication")
|
|
435
489
|
},
|
|
436
490
|
{
|
|
437
491
|
id: "analyze",
|
|
438
492
|
label: "Snapshot your numbers",
|
|
439
493
|
description: "Capture an analytics snapshot to track registration trends.",
|
|
440
|
-
icon: /* @__PURE__ */
|
|
494
|
+
icon: /* @__PURE__ */ y(C, { className: "h-4 w-4" }),
|
|
441
495
|
onClick: () => t("/analytics")
|
|
442
496
|
}
|
|
443
497
|
]
|
|
@@ -446,6 +500,6 @@ function z() {
|
|
|
446
500
|
});
|
|
447
501
|
}
|
|
448
502
|
//#endregion
|
|
449
|
-
export {
|
|
503
|
+
export { X as default };
|
|
450
504
|
|
|
451
505
|
//# sourceMappingURL=RegistrationPage.js.map
|