@burdenoff/microfe-support 2026.817.3 → 2026.818.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.
@@ -1,40 +1,21 @@
1
- import { Badge as e, Button as t, Dialog as n, DialogContent as r, DialogDescription as i, DialogFooter as ee, DialogHeader as te, DialogTitle as ne, Input as a, Label as o, Select as re, SelectContent as ie, SelectItem as s, SelectTrigger as ae, SelectValue as oe, Textarea as se } from "../components/ui.js";
2
- import { useCreateJobApplicationMutation as ce, useGetJobApplicationsQuery as le, useGetJobPostingsQuery as ue } from "../../generated/global-operations.js";
3
- import { JobApplicationStatus as c, JobPostingStatus as de } from "../../generated/global-types.js";
4
- import { nativeNotify as l } from "../../utils/nativeBridge.js";
5
- import { useEffect as u, useRef as fe, useState as d } from "react";
6
- import { AlertCircle as pe, Briefcase as f, ChevronDown as me, Filter as he, Grid as ge, List as _e, Loader2 as p, Paperclip as m, Plus as ve, Search as ye, UserPlus as be } from "lucide-react";
7
- import { useLocation as xe, useNavigate as Se } from "react-router";
1
+ import { Badge as e, Button as t, Checkbox as n, Dialog as r, DialogContent as i, DialogDescription as a, DialogFooter as ee, DialogHeader as te, DialogTitle as ne, Input as o, Label as s, Select as re, SelectContent as ie, SelectItem as ae, SelectTrigger as oe, SelectValue as se, Textarea as ce } from "../components/ui.js";
2
+ import { useBulkRandomizeAndSendAssignmentMutation as le, useBulkSendRoundMessageMutation as ue, useCreateJobApplicationMutation as c, useGetJobApplicationsQuery as l, useGetJobPostingQuery as u, useGetJobPostingsQuery as de } from "../../generated/global-operations.js";
3
+ import { JobPostingStatus as d } from "../../generated/global-types.js";
4
+ import { nativeNotify as f } from "../../utils/nativeBridge.js";
5
+ import { roundStatusConfig as fe, roundStatusOrder as p, statusColors as m, statusLabels as h, statusOrder as g } from "../constants/pipeline.js";
6
+ import { useEffect as _, useRef as v, useState as y } from "react";
7
+ import { AlertCircle as pe, Briefcase as b, CheckCircle2 as me, ChevronDown as he, Filter as x, Grid as ge, List as _e, Loader2 as S, Paperclip as C, Plus as ve, Search as ye, Send as be, Shuffle as w, SkipForward as T, UserPlus as E, XCircle as xe } from "lucide-react";
8
+ import { useLocation as Se, useNavigate as D } from "react-router";
8
9
  import { graphqlFetch as Ce } from "@burdenoff/fe-libs/shared/graphql/fetch";
9
- import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
10
+ import { Fragment as O, jsx as k, jsxs as A } from "react/jsx-runtime";
10
11
  import { IllustratedEmptyState as we, PagePurpose as Te } from "@burdenoff/fe-libs/ui";
11
12
  //#region src/support/pages/JobApplicationsPage.tsx
12
- var v = [
13
- c.New,
14
- c.Screening,
15
- c.Shortlisted,
16
- c.Interview,
17
- c.Hired,
18
- c.Rejected,
19
- c.Archived
20
- ], y = {
21
- NEW: "bg-status-info-bg-subtle text-status-info-text",
22
- SCREENING: "bg-status-warning-bg-subtle text-status-warning-text",
23
- SHORTLISTED: "bg-accent-purple-subtle text-accent-purple",
24
- INTERVIEW: "bg-accent-blue-subtle text-accent-blue",
25
- HIRED: "bg-status-success-bg-subtle text-status-success-text",
26
- REJECTED: "bg-status-error-bg-subtle text-status-error-text",
27
- ARCHIVED: "bg-bg-sunken text-text-secondary"
28
- }, b = {
29
- NEW: "New",
30
- SCREENING: "Screening",
31
- SHORTLISTED: "Shortlisted",
32
- INTERVIEW: "Interview",
33
- HIRED: "Hired",
34
- REJECTED: "Rejected",
35
- ARCHIVED: "Archived"
36
- };
37
- function x(e) {
13
+ var j = 50, M = 100;
14
+ function N(e, t) {
15
+ let n = new Set(e);
16
+ return n.has(t) ? n.delete(t) : n.add(t), n;
17
+ }
18
+ function P(e) {
38
19
  return new Date(e).toLocaleDateString("en-US", {
39
20
  month: "short",
40
21
  day: "numeric",
@@ -50,9 +31,9 @@ function Ee(e) {
50
31
  let r = Math.floor(n / 60);
51
32
  if (r < 24) return `${r}h ago`;
52
33
  let i = Math.floor(r / 24);
53
- return i < 30 ? `${i}d ago` : x(e);
34
+ return i < 30 ? `${i}d ago` : P(e);
54
35
  }
55
- var S = "__none__", De = [
36
+ var F = "__none__", De = [
56
37
  "LinkedIn",
57
38
  "Referral",
58
39
  "Indeed",
@@ -63,18 +44,18 @@ var S = "__none__", De = [
63
44
  "application/pdf",
64
45
  "application/msword",
65
46
  "application/vnd.openxmlformats-officedocument.wordprocessingml.document"
66
- ]), C = {
47
+ ]), je = {
67
48
  name: "",
68
49
  email: "",
69
50
  phone: "",
70
- jobPostingId: S,
51
+ jobPostingId: F,
71
52
  position: "",
72
53
  source: "",
73
54
  linkedin: "",
74
55
  portfolio: "",
75
56
  coverLetter: ""
76
57
  };
77
- function je(e) {
58
+ function Me(e) {
78
59
  return new Promise((t, n) => {
79
60
  let r = new FileReader();
80
61
  r.onload = () => {
@@ -88,33 +69,293 @@ function je(e) {
88
69
  }, r.onerror = () => n(r.error ?? /* @__PURE__ */ Error("Failed to read file")), r.readAsDataURL(e);
89
70
  });
90
71
  }
91
- function w() {
92
- let c = Se(), x = xe().search, [w, Me] = d(""), [T, Ne] = d(""), [E, Pe] = d(""), [D, Fe] = d(""), [O, Ie] = d(""), [k, Le] = d(!1), [A, j] = d("list"), [Re, M] = d(!1), [N, P] = d(C), [F, I] = d({}), [L, R] = d(null), [z, B] = d(""), [V, H] = d(!1), [U, ze] = d({}), W = fe(U);
93
- W.current = U, u(() => {
94
- let e = setTimeout(() => Ne(w), 300);
72
+ var Ne = {
73
+ message: "ROUND_MESSAGE",
74
+ assignment: "ASSIGNMENT"
75
+ };
76
+ function Pe({ mode: e, open: o, onClose: c, applications: l, jobPostingId: de }) {
77
+ let [d, fe] = y(""), [p, m] = y(""), [h, g] = y(!1), [v, b] = y(null), { data: he, loading: x, error: ge } = u({
78
+ variables: { id: de },
79
+ skip: !o || !de
80
+ }), [_e, { loading: C }] = le({ refetchQueries: ["GetJobApplications", "GetJobApplicationInterviewRounds"] }), [ve, { loading: ye }] = ue({ refetchQueries: ["GetJobApplications", "GetJobApplicationInterviewRounds"] }), w = C || ye, E = he?.jobPosting?.rounds ?? [], Se = E.filter((t) => e === "assignment" ? t.isAssignmentRound : !0), D = E.find((e) => e.id === d), Ce = (D ? E.filter((e) => e.name.trim().toLowerCase() === D.name.trim().toLowerCase() && e.roundType === D.roundType) : []).length === 1, we = Ne[e], Te = !!d && x, j = null;
81
+ l.length > M ? j = `Select no more than ${M} candidates for one bulk send.` : d && ge ? j = "Could not load the posting rounds. Nothing will be sent. Try again." : d && !x && !D && (j = "The selected round is no longer available. Choose another round.");
82
+ let N = D ? l.map((e) => {
83
+ let t = e.interviewRounds.find((e) => e.roundConfigId === D.id), n = Ce ? e.interviewRounds.find((e) => !e.roundConfigId && e.name.trim().toLowerCase() === D.name.trim().toLowerCase() && e.roundType === D.roundType) : void 0, r = t ?? n;
84
+ return {
85
+ applicationId: e.id,
86
+ name: `${e.firstName} ${e.lastName}`.trim(),
87
+ round: r ? {
88
+ id: r.id,
89
+ alreadySent: r.emailLogs.some((e) => e.emailType === we)
90
+ } : null
91
+ };
92
+ }) : [];
93
+ _(() => {
94
+ o || (fe(""), m(""), g(!1), b(null));
95
+ }, [o]);
96
+ let P = N.filter((e) => e.round ? h || !e.round.alreadySent : !1), Ee = N.filter((e) => e.round?.alreadySent).length, F = N.filter((e) => !e.round).length, De = new Set(l.map((e) => e.id)).size, Oe = !Te && !j && De > 0 && N.length === De;
97
+ return /* @__PURE__ */ k(r, {
98
+ open: o,
99
+ onOpenChange: (e) => !e && c(),
100
+ children: /* @__PURE__ */ A(i, {
101
+ className: "sm:max-w-lg max-h-[90vh] overflow-y-auto",
102
+ children: [/* @__PURE__ */ A(te, { children: [/* @__PURE__ */ k(ne, { children: e === "assignment" ? "Randomize & Send Assignment" : "Send Message" }), /* @__PURE__ */ A(a, { children: [
103
+ e === "assignment" ? "Pick a random active assignment for the posting and email it to every selected candidate at once." : "Send the same message to every selected candidate at once.",
104
+ " ",
105
+ l.length,
106
+ " candidate",
107
+ l.length === 1 ? "" : "s",
108
+ " selected."
109
+ ] })] }), v ? /* @__PURE__ */ A("div", {
110
+ className: "space-y-4",
111
+ children: [/* @__PURE__ */ A("div", {
112
+ className: "space-y-2",
113
+ children: [
114
+ /* @__PURE__ */ A("div", {
115
+ className: "flex items-center gap-2 text-sm text-status-success-text",
116
+ children: [
117
+ /* @__PURE__ */ k(me, { size: 16 }),
118
+ "Sent to ",
119
+ v.succeeded,
120
+ " candidate",
121
+ v.succeeded === 1 ? "" : "s"
122
+ ]
123
+ }),
124
+ v.skipped > 0 && /* @__PURE__ */ A("div", {
125
+ className: "flex items-center gap-2 text-sm text-status-warning-text",
126
+ children: [
127
+ /* @__PURE__ */ k(T, { size: 16 }),
128
+ "Skipped ",
129
+ v.skipped,
130
+ " — already sent (use force to resend)"
131
+ ]
132
+ }),
133
+ v.failed > 0 && /* @__PURE__ */ A("div", {
134
+ className: "flex items-center gap-2 text-sm text-status-error-text",
135
+ children: [
136
+ /* @__PURE__ */ k(xe, { size: 16 }),
137
+ "Failed for ",
138
+ v.failed,
139
+ " candidate",
140
+ v.failed === 1 ? "" : "s"
141
+ ]
142
+ })
143
+ ]
144
+ }), /* @__PURE__ */ k(ee, { children: /* @__PURE__ */ k(t, {
145
+ onClick: c,
146
+ children: "Done"
147
+ }) })]
148
+ }) : /* @__PURE__ */ A("div", {
149
+ className: "space-y-4",
150
+ children: [
151
+ /* @__PURE__ */ A("div", {
152
+ className: "space-y-1.5",
153
+ children: [
154
+ /* @__PURE__ */ k(s, {
155
+ htmlFor: "bulk-round-config",
156
+ children: "Target round"
157
+ }),
158
+ /* @__PURE__ */ A(re, {
159
+ value: d,
160
+ onValueChange: fe,
161
+ disabled: x,
162
+ children: [/* @__PURE__ */ k(oe, {
163
+ id: "bulk-round-config",
164
+ children: /* @__PURE__ */ k(se, { placeholder: "Select a round" })
165
+ }), /* @__PURE__ */ k(ie, { children: Se.map((e) => /* @__PURE__ */ A(ae, {
166
+ value: e.id,
167
+ children: [
168
+ "Round ",
169
+ e.roundNumber,
170
+ " — ",
171
+ e.name
172
+ ]
173
+ }, e.id)) })]
174
+ }),
175
+ Se.length === 0 && !x && /* @__PURE__ */ k("p", {
176
+ className: "text-xs text-status-warning-text",
177
+ children: e === "assignment" ? "This posting has no round configured as an assignment round yet." : "This posting has no interview rounds configured yet."
178
+ })
179
+ ]
180
+ }),
181
+ e === "message" && /* @__PURE__ */ A("div", {
182
+ className: "space-y-1.5",
183
+ children: [/* @__PURE__ */ k(s, {
184
+ htmlFor: "bulk-message",
185
+ children: "Message"
186
+ }), /* @__PURE__ */ k(ce, {
187
+ id: "bulk-message",
188
+ value: p,
189
+ onChange: (e) => m(e.target.value),
190
+ placeholder: "e.g. Hey, this is a quick task for you — complete it and submit here: https://…",
191
+ rows: 5
192
+ })]
193
+ }),
194
+ d && /* @__PURE__ */ A("div", {
195
+ className: "space-y-1.5",
196
+ children: [
197
+ /* @__PURE__ */ k("p", {
198
+ className: "text-xs font-medium text-text-secondary",
199
+ children: "Preview"
200
+ }),
201
+ Te ? /* @__PURE__ */ A("div", {
202
+ className: "flex items-center gap-2 text-sm text-text-secondary",
203
+ children: [/* @__PURE__ */ k(S, {
204
+ size: 14,
205
+ className: "animate-spin"
206
+ }), "Checking candidates…"]
207
+ }) : j ? /* @__PURE__ */ A("div", {
208
+ className: "flex items-start gap-2 text-sm text-status-error-text",
209
+ children: [/* @__PURE__ */ k(pe, {
210
+ size: 14,
211
+ className: "mt-0.5 shrink-0"
212
+ }), /* @__PURE__ */ k("span", { children: j })]
213
+ }) : /* @__PURE__ */ A("div", {
214
+ className: "text-xs text-text-secondary space-y-1",
215
+ children: [
216
+ /* @__PURE__ */ A("p", { children: [
217
+ "Will send to",
218
+ " ",
219
+ /* @__PURE__ */ k("span", {
220
+ className: "font-medium text-text-primary",
221
+ children: P.length
222
+ }),
223
+ " ",
224
+ "candidate",
225
+ P.length === 1 ? "" : "s"
226
+ ] }),
227
+ Ee > 0 && /* @__PURE__ */ A("p", { children: [
228
+ Ee,
229
+ " already sent",
230
+ " ",
231
+ h ? "(will resend — force is on)" : "(will be skipped)"
232
+ ] }),
233
+ F > 0 && /* @__PURE__ */ A("p", { children: [F, " have no round for this stage yet (skipped)"] })
234
+ ]
235
+ }),
236
+ /* @__PURE__ */ A("label", {
237
+ className: "flex items-center gap-2 pt-1 cursor-pointer",
238
+ children: [/* @__PURE__ */ k(n, {
239
+ checked: h,
240
+ onCheckedChange: (e) => g(e === !0)
241
+ }), /* @__PURE__ */ k("span", {
242
+ className: "text-xs text-text-primary",
243
+ children: "Resend to already-sent candidates"
244
+ })]
245
+ })
246
+ ]
247
+ }),
248
+ /* @__PURE__ */ A(ee, { children: [/* @__PURE__ */ k(t, {
249
+ variant: "outline",
250
+ onClick: c,
251
+ disabled: w,
252
+ children: "Cancel"
253
+ }), /* @__PURE__ */ k(t, {
254
+ onClick: async () => {
255
+ if (!Oe) return;
256
+ let t = [], n = /* @__PURE__ */ new Set();
257
+ for (let e of N) {
258
+ if (!e.round) continue;
259
+ let r = `${e.applicationId}:${e.round.id}`;
260
+ n.has(r) || (n.add(r), t.push({
261
+ applicationId: e.applicationId,
262
+ roundId: e.round.id
263
+ }));
264
+ }
265
+ if (!(t.length === 0 || t.length > M)) try {
266
+ if (e === "assignment") {
267
+ let e = (await _e({ variables: { input: {
268
+ items: t,
269
+ force: h
270
+ } } })).data?.bulkRandomizeAndSendAssignment;
271
+ if (!e) throw Error("Assignment send returned no result");
272
+ b({
273
+ succeeded: e.succeeded.length,
274
+ skipped: e.skipped.length,
275
+ failed: e.failed.length
276
+ });
277
+ } else {
278
+ let e = (await ve({ variables: { input: {
279
+ items: t,
280
+ message: p.trim(),
281
+ force: h
282
+ } } })).data?.bulkSendRoundMessage;
283
+ if (!e) throw Error("Message send returned no result");
284
+ b({
285
+ succeeded: e.succeeded.length,
286
+ skipped: e.skipped.length,
287
+ failed: e.failed.length
288
+ });
289
+ }
290
+ f("success");
291
+ } catch (e) {
292
+ console.error("Bulk send failed:", e), f("error");
293
+ }
294
+ },
295
+ disabled: w || !d || !Oe || e === "message" && !p.trim() || P.length === 0,
296
+ children: w ? /* @__PURE__ */ A(O, { children: [/* @__PURE__ */ k(S, {
297
+ size: 16,
298
+ className: "animate-spin mr-2"
299
+ }), "Sending…"] }) : /* @__PURE__ */ A(O, { children: [/* @__PURE__ */ k(be, {
300
+ size: 16,
301
+ className: "mr-2"
302
+ }), "Send"] })
303
+ })] })
304
+ ]
305
+ })]
306
+ })
307
+ });
308
+ }
309
+ function I() {
310
+ let le = D(), ue = Se().search, [u, me] = y(""), [T, xe] = y(""), [P, Ne] = y(/* @__PURE__ */ new Set()), [I, Fe] = y(/* @__PURE__ */ new Set()), [L, Ie] = y(""), [R, Le] = y(""), [z, Re] = y(!1), [ze, Be] = y("list"), [Ve, B] = y(/* @__PURE__ */ new Set()), [He, V] = y(null), [Ue, H] = y(!1), [U, W] = y(je), [G, We] = y({}), [K, q] = y(null), [Ge, J] = y(""), [Ke, qe] = y(!1), [Je, Ye] = y(!1), [Y, Xe] = y({}), X = v(j), Ze = v(Y);
311
+ Ze.current = Y, _(() => {
312
+ let e = setTimeout(() => xe(u), 300);
95
313
  return () => clearTimeout(e);
96
- }, [w]);
97
- let { data: G, loading: K, error: q, fetchMore: Be } = le({
314
+ }, [u]);
315
+ let Qe = {
316
+ ...T ? { search: T } : {},
317
+ ...P.size > 0 ? { statuses: Array.from(P) } : {},
318
+ ...I.size > 0 ? { roundStatuses: Array.from(I) } : {},
319
+ ...L ? { productId: L } : {},
320
+ ...R ? { jobPostingId: R } : {}
321
+ }, Z = JSON.stringify({
322
+ search: T,
323
+ statuses: Array.from(P).sort(),
324
+ roundStatuses: Array.from(I).sort(),
325
+ productId: L,
326
+ jobPostingId: R
327
+ }), $e = v(Z);
328
+ $e.current = Z, _(() => {
329
+ B(/* @__PURE__ */ new Set()), V(null), Ye(!1), X.current = j;
330
+ }, [Z]);
331
+ let { data: et, loading: tt, error: nt, fetchMore: rt } = l({
98
332
  variables: {
99
- filter: {
100
- ...T ? { search: T } : {},
101
- ...E ? { status: E } : {},
102
- ...D ? { productId: D } : {},
103
- ...O ? { jobPostingId: O } : {}
104
- },
105
- limit: 50,
333
+ filter: Qe,
334
+ limit: j,
106
335
  offset: 0
107
336
  },
108
337
  fetchPolicy: "cache-and-network"
109
- }), { data: J, loading: Y } = ue({
338
+ }), { data: it, loading: at } = de({
110
339
  variables: {
111
340
  limit: 200,
112
341
  offset: 0
113
342
  },
114
343
  fetchPolicy: "cache-and-network"
115
- }), [Ve] = ce(), He = (J?.jobPostings?.items ?? []).filter((e) => e.status === de.Open), X = G?.jobApplications?.items ?? [], Ue = G?.jobApplications?.total ?? 0, Z = G?.jobApplications?.hasMore ?? !1, We = (J?.jobPostings?.items ?? []).reduce((e, t) => (e[t.id] = t, e), {}), Ge = Array.from(new Set(X.flatMap((e) => e.productId ? [e.productId] : []))).sort(), Q = Ge.join(",");
116
- u(() => {
117
- let e = Q ? Q.split(",").filter((e) => !W.current[e]) : [];
344
+ }), [ot] = c(), st = (it?.jobPostings?.items ?? []).filter((e) => e.status === d.Open), ct = et?.jobApplications?.items ?? [], lt = /* @__PURE__ */ new Map();
345
+ for (let e of ct) lt.set(e.id, e);
346
+ let Q = Array.from(lt.values()), ut = et?.jobApplications?.total ?? 0, dt = et?.jobApplications?.hasMore ?? !1, ft = Q.map((e) => e.id).join(",");
347
+ _(() => {
348
+ let e = new Set(ft ? ft.split(",") : []);
349
+ B((t) => {
350
+ let n = new Set(Array.from(t).filter((t) => e.has(t)));
351
+ return n.size === t.size && Array.from(n).every((e) => t.has(e)) ? t : n;
352
+ });
353
+ }, [ft]);
354
+ let pt = (it?.jobPostings?.items ?? []).reduce((e, t) => (e[t.id] = t, e), {}), $ = Q.filter((e) => Ve.has(e.id)), mt = R ? $.filter((e) => e.jobPostingId === R) : [], ht = mt.length !== $.length, gt = $.length > M, _t = !!R && $.length > 0 && !ht && !gt, vt = `Select all ${Q.length} visible`;
355
+ Q.length > M && (vt = `Select candidates individually (maximum ${M})`), $.length > 0 && (vt = `${$.length} selected`);
356
+ let yt = Array.from(new Set(Q.flatMap((e) => e.productId ? [e.productId] : []))).sort(), bt = yt.join(",");
357
+ _(() => {
358
+ let e = bt ? bt.split(",").filter((e) => !Ze.current[e]) : [];
118
359
  e.length !== 0 && e.forEach((e) => {
119
360
  Ce({
120
361
  gateway: "global",
@@ -122,31 +363,47 @@ function w() {
122
363
  variables: { id: e }
123
364
  }).then((t) => {
124
365
  let n = t.data?.platformProduct?.name;
125
- n && ze((t) => ({
366
+ n && Xe((t) => ({
126
367
  ...t,
127
368
  [e]: n
128
369
  }));
129
370
  }).catch(() => {});
130
371
  });
131
- }, [Q]);
132
- let Ke = () => {
133
- Z && Be({
134
- variables: { offset: X.length },
135
- updateQuery: (e, { fetchMoreResult: t }) => t ? { jobApplications: {
136
- ...t.jobApplications,
137
- items: [...e.jobApplications?.items ?? [], ...t.jobApplications?.items ?? []]
138
- } } : e
139
- });
140
- }, $ = () => {
141
- P(C), I({}), R(null), B("");
142
- }, qe = (e) => {
372
+ }, [bt]);
373
+ let xt = async () => {
374
+ if (!dt || Je) return;
375
+ let e = X.current, t = Z;
376
+ Ye(!0);
377
+ try {
378
+ let n = await rt({
379
+ variables: { offset: e },
380
+ updateQuery: (e, { fetchMoreResult: t }) => {
381
+ if (!t) return e;
382
+ let n = /* @__PURE__ */ new Map();
383
+ for (let t of e.jobApplications?.items ?? []) n.set(t.id, t);
384
+ for (let e of t.jobApplications?.items ?? []) n.set(e.id, e);
385
+ return { jobApplications: {
386
+ ...t.jobApplications,
387
+ items: Array.from(n.values())
388
+ } };
389
+ }
390
+ });
391
+ $e.current === t && (X.current = e + (n.data.jobApplications?.items.length ?? j));
392
+ } catch (e) {
393
+ console.error("Failed to load more applications:", e), f("error");
394
+ } finally {
395
+ $e.current === t && Ye(!1);
396
+ }
397
+ }, St = () => {
398
+ W(je), We({}), q(null), J("");
399
+ }, Ct = (e) => {
143
400
  let t = e.target.files?.[0] ?? null;
144
- if (B(""), !t) {
145
- R(null);
401
+ if (J(""), !t) {
402
+ q(null);
146
403
  return;
147
404
  }
148
405
  if (t.size > Oe) {
149
- B("Resume must be 10 MB or smaller."), R(null), e.target.value = "";
406
+ J("Resume must be 10 MB or smaller."), q(null), e.target.value = "";
150
407
  return;
151
408
  }
152
409
  let n = t.name.toLowerCase().split(".").pop() ?? "";
@@ -155,586 +412,669 @@ function w() {
155
412
  "doc",
156
413
  "docx"
157
414
  ].includes(n)) {
158
- B("Resume must be a PDF, DOC, or DOCX file."), R(null), e.target.value = "";
415
+ J("Resume must be a PDF, DOC, or DOCX file."), q(null), e.target.value = "";
159
416
  return;
160
417
  }
161
- R(t);
162
- }, Je = () => {
418
+ q(t);
419
+ }, wt = () => {
163
420
  let e = {};
164
- return N.name.trim() || (e.name = "Name is required"), N.email.trim() ? /^\S+@\S+\.\S+$/.test(N.email.trim()) || (e.email = "Enter a valid email") : e.email = "Email is required", N.source.trim() || (e.source = "Source is required"), N.jobPostingId === S && !N.position.trim() && (e.position = "Position is required when no job posting is selected"), I(e), Object.keys(e).length === 0;
165
- }, Ye = async (e) => {
166
- if (e.preventDefault(), Je()) {
167
- H(!0);
421
+ return U.name.trim() || (e.name = "Name is required"), U.email.trim() ? /^\S+@\S+\.\S+$/.test(U.email.trim()) || (e.email = "Enter a valid email") : e.email = "Email is required", U.source.trim() || (e.source = "Source is required"), U.jobPostingId === F && !U.position.trim() && (e.position = "Position is required when no job posting is selected"), We(e), Object.keys(e).length === 0;
422
+ }, Tt = async (e) => {
423
+ if (e.preventDefault(), wt()) {
424
+ qe(!0);
168
425
  try {
169
426
  let e, t, n;
170
- L && (t = await je(L), e = L.name, n = L.type || void 0);
171
- let r = N.jobPostingId !== S, i = (await Ve({
427
+ K && (t = await Me(K), e = K.name, n = K.type || void 0);
428
+ let r = U.jobPostingId !== F, i = (await ot({
172
429
  variables: { input: {
173
- name: N.name.trim(),
174
- email: N.email.trim(),
175
- phone: N.phone.trim() || void 0,
176
- jobPostingId: r ? N.jobPostingId : void 0,
177
- position: r ? void 0 : N.position.trim() || void 0,
178
- source: N.source.trim(),
179
- linkedin: N.linkedin.trim() || void 0,
180
- portfolio: N.portfolio.trim() || void 0,
181
- coverLetter: N.coverLetter.trim() || void 0,
430
+ name: U.name.trim(),
431
+ email: U.email.trim(),
432
+ phone: U.phone.trim() || void 0,
433
+ jobPostingId: r ? U.jobPostingId : void 0,
434
+ position: r ? void 0 : U.position.trim() || void 0,
435
+ source: U.source.trim(),
436
+ linkedin: U.linkedin.trim() || void 0,
437
+ portfolio: U.portfolio.trim() || void 0,
438
+ coverLetter: U.coverLetter.trim() || void 0,
182
439
  resumeFileName: e,
183
440
  resumeBase64: t,
184
441
  resumeMimeType: n
185
442
  } },
186
443
  refetchQueries: ["GetJobApplications"]
187
444
  })).data?.createJobApplication?.id;
188
- l("success"), M(!1), $(), i && c(`/support/applications/${i}${x}`);
445
+ f("success"), H(!1), St(), i && le(`/support/applications/${i}${ue}`);
189
446
  } catch (e) {
190
- console.error("Failed to create candidate:", e), l("error");
447
+ console.error("Failed to create candidate:", e), f("error");
191
448
  } finally {
192
- H(!1);
449
+ qe(!1);
193
450
  }
194
451
  }
195
- }, Xe = v.reduce((e, t) => (e[t] = X.filter((e) => e.status === t), e), {}), Ze = (t, n = !1) => {
196
- let r = t.jobPostingId ? We[t.jobPostingId]?.title : void 0;
197
- return /* @__PURE__ */ g("button", {
198
- type: "button",
199
- onClick: () => c(`/support/applications/${t.id}${x}`),
200
- className: `w-full text-left bg-bg-surface border border-border-seam rounded-lg shadow-[var(--shadow-pop)] hover:border-border-strong hover:shadow-[var(--shadow-pop-hover)] transition-[box-shadow,border-color] duration-200 group ${n ? "p-3" : "p-4"}`,
201
- children: /* @__PURE__ */ _("div", {
202
- className: `flex ${n ? "flex-col" : "items-start"} justify-between gap-3`,
203
- children: [/* @__PURE__ */ _("div", {
204
- className: "flex-1 min-w-0",
205
- children: [
206
- /* @__PURE__ */ _("div", {
207
- className: "flex items-center gap-2 mb-1 flex-wrap",
208
- children: [
209
- /* @__PURE__ */ _("h3", {
210
- className: "font-semibold text-text-primary truncate group-hover:text-primary transition-colors text-sm",
211
- children: [
212
- t.firstName,
213
- " ",
214
- t.lastName
215
- ]
216
- }),
217
- /* @__PURE__ */ g(e, {
218
- variant: "secondary",
219
- className: `${y[t.status] || y.NEW} ${t.status === "NEW" ? "motion-safe:animate-vc-glow-pulse" : ""}`,
220
- children: b[t.status] || t.status
221
- }),
222
- r && /* @__PURE__ */ g(e, {
223
- variant: "outline",
224
- title: `Job posting: ${r}`,
225
- children: r
226
- }),
227
- t.productId && U[t.productId] && /* @__PURE__ */ g(e, {
228
- variant: "secondary",
229
- className: "bg-accent-purple-subtle text-accent-purple",
230
- title: `Product: ${U[t.productId]}`,
231
- children: U[t.productId]
232
- }),
233
- t.resumeFileName && /* @__PURE__ */ _(e, {
234
- variant: "secondary",
235
- className: "bg-accent-blue-subtle text-accent-blue gap-1",
236
- children: [/* @__PURE__ */ g(m, { size: n ? 10 : 11 }), "Resume"]
237
- })
238
- ]
239
- }),
240
- /* @__PURE__ */ _("p", {
241
- className: `text-text-secondary mb-1 ${n ? "text-xs" : "text-sm"}`,
242
- children: [/* @__PURE__ */ g("span", {
243
- className: "font-medium",
244
- children: t.position
245
- }), t.department && /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g("span", {
246
- className: "mx-1.5 text-text-secondary/50",
247
- children: "·"
248
- }), /* @__PURE__ */ g("span", { children: t.department })] })]
249
- }),
250
- /* @__PURE__ */ g("p", {
251
- className: `text-text-secondary truncate ${n ? "text-[11px]" : "text-xs"}`,
252
- children: t.email
253
- })
254
- ]
255
- }), /* @__PURE__ */ g("div", {
256
- className: `text-text-secondary whitespace-nowrap ${n ? "text-[11px]" : "text-xs"}`,
257
- children: Ee(t.createdAt)
258
- })]
259
- })
452
+ }, Et = g.reduce((e, t) => (e[t] = Q.filter((e) => e.status === t), e), {}), Dt = (t, r = !1) => {
453
+ let i = t.jobPostingId ? pt[t.jobPostingId]?.title : void 0, a = Ve.has(t.id);
454
+ return /* @__PURE__ */ A("div", {
455
+ className: `w-full bg-bg-surface border rounded-lg shadow-[var(--shadow-pop)] hover:border-border-strong hover:shadow-[var(--shadow-pop-hover)] transition-[box-shadow,border-color] duration-200 group flex items-start gap-2 ${r ? "p-3" : "p-4"} ${a ? "border-primary" : "border-border-seam"}`,
456
+ children: [/* @__PURE__ */ k("div", {
457
+ className: "pt-0.5",
458
+ children: /* @__PURE__ */ k(n, {
459
+ checked: a,
460
+ onCheckedChange: () => B((e) => N(e, t.id)),
461
+ "aria-label": `Select ${t.firstName} ${t.lastName}`
462
+ })
463
+ }), /* @__PURE__ */ k("button", {
464
+ type: "button",
465
+ onClick: () => le(`/support/applications/${t.id}${ue}`),
466
+ className: "flex-1 min-w-0 text-left",
467
+ children: /* @__PURE__ */ A("div", {
468
+ className: `flex ${r ? "flex-col" : "items-start"} justify-between gap-3`,
469
+ children: [/* @__PURE__ */ A("div", {
470
+ className: "flex-1 min-w-0",
471
+ children: [
472
+ /* @__PURE__ */ A("div", {
473
+ className: "flex items-center gap-2 mb-1 flex-wrap",
474
+ children: [
475
+ /* @__PURE__ */ A("h3", {
476
+ className: "font-semibold text-text-primary truncate group-hover:text-primary transition-colors text-sm",
477
+ children: [
478
+ t.firstName,
479
+ " ",
480
+ t.lastName
481
+ ]
482
+ }),
483
+ /* @__PURE__ */ k(e, {
484
+ variant: "secondary",
485
+ className: `${m[t.status] || m.NEW} ${t.status === "NEW" ? "motion-safe:animate-vc-glow-pulse" : ""}`,
486
+ children: h[t.status] || t.status
487
+ }),
488
+ i && /* @__PURE__ */ k(e, {
489
+ variant: "outline",
490
+ title: `Job posting: ${i}`,
491
+ children: i
492
+ }),
493
+ t.productId && Y[t.productId] && /* @__PURE__ */ k(e, {
494
+ variant: "secondary",
495
+ className: "bg-accent-purple-subtle text-accent-purple",
496
+ title: `Product: ${Y[t.productId]}`,
497
+ children: Y[t.productId]
498
+ }),
499
+ t.resumeFileName && /* @__PURE__ */ A(e, {
500
+ variant: "secondary",
501
+ className: "bg-accent-blue-subtle text-accent-blue gap-1",
502
+ children: [/* @__PURE__ */ k(C, { size: r ? 10 : 11 }), "Resume"]
503
+ })
504
+ ]
505
+ }),
506
+ /* @__PURE__ */ A("p", {
507
+ className: `text-text-secondary mb-1 ${r ? "text-xs" : "text-sm"}`,
508
+ children: [/* @__PURE__ */ k("span", {
509
+ className: "font-medium",
510
+ children: t.position
511
+ }), t.department && /* @__PURE__ */ A(O, { children: [/* @__PURE__ */ k("span", {
512
+ className: "mx-1.5 text-text-secondary/50",
513
+ children: "·"
514
+ }), /* @__PURE__ */ k("span", { children: t.department })] })]
515
+ }),
516
+ /* @__PURE__ */ k("p", {
517
+ className: `text-text-secondary truncate ${r ? "text-[11px]" : "text-xs"}`,
518
+ children: t.email
519
+ })
520
+ ]
521
+ }), /* @__PURE__ */ k("div", {
522
+ className: `text-text-secondary whitespace-nowrap ${r ? "text-[11px]" : "text-xs"}`,
523
+ children: Ee(t.createdAt)
524
+ })]
525
+ })
526
+ })]
260
527
  }, t.id);
261
528
  };
262
- return K && X.length === 0 ? /* @__PURE__ */ _("div", {
529
+ return tt && Q.length === 0 ? /* @__PURE__ */ A("div", {
263
530
  className: "p-6",
264
- children: [/* @__PURE__ */ _("div", {
531
+ children: [/* @__PURE__ */ A("div", {
265
532
  className: "flex items-center gap-3 mb-6",
266
- children: [/* @__PURE__ */ g(f, {
533
+ children: [/* @__PURE__ */ k(b, {
267
534
  size: 24,
268
535
  className: "text-text-primary"
269
- }), /* @__PURE__ */ g("h1", {
536
+ }), /* @__PURE__ */ k("h1", {
270
537
  className: "text-2xl font-bold text-text-primary",
271
538
  children: "Job Applications"
272
539
  })]
273
- }), /* @__PURE__ */ _("div", {
540
+ }), /* @__PURE__ */ A("div", {
274
541
  className: "flex flex-col items-center justify-center py-16",
275
- children: [/* @__PURE__ */ g(p, {
542
+ children: [/* @__PURE__ */ k(S, {
276
543
  size: 32,
277
544
  className: "animate-spin text-text-secondary mb-4"
278
- }), /* @__PURE__ */ g("p", {
545
+ }), /* @__PURE__ */ k("p", {
279
546
  className: "text-sm text-text-secondary",
280
547
  children: "Loading applications…"
281
548
  })]
282
549
  })]
283
- }) : q ? /* @__PURE__ */ _("div", {
550
+ }) : nt ? /* @__PURE__ */ A("div", {
284
551
  className: "p-6",
285
- children: [/* @__PURE__ */ _("div", {
552
+ children: [/* @__PURE__ */ A("div", {
286
553
  className: "flex items-center gap-3 mb-6",
287
- children: [/* @__PURE__ */ g(f, {
554
+ children: [/* @__PURE__ */ k(b, {
288
555
  size: 24,
289
556
  className: "text-text-primary"
290
- }), /* @__PURE__ */ g("h1", {
557
+ }), /* @__PURE__ */ k("h1", {
291
558
  className: "text-2xl font-bold text-text-primary",
292
559
  children: "Job Applications"
293
560
  })]
294
- }), /* @__PURE__ */ _("div", {
561
+ }), /* @__PURE__ */ A("div", {
295
562
  className: "flex flex-col items-center justify-center py-16 text-center",
296
563
  children: [
297
- /* @__PURE__ */ g("div", {
564
+ /* @__PURE__ */ k("div", {
298
565
  className: "p-4 rounded-2xl bg-status-error-bg-subtle text-status-error-text mb-4",
299
- children: /* @__PURE__ */ g(pe, { size: 48 })
566
+ children: /* @__PURE__ */ k(pe, { size: 48 })
300
567
  }),
301
- /* @__PURE__ */ g("h3", {
568
+ /* @__PURE__ */ k("h3", {
302
569
  className: "text-lg font-semibold text-text-primary mb-2",
303
570
  children: "Failed to load applications"
304
571
  }),
305
- /* @__PURE__ */ g("p", {
572
+ /* @__PURE__ */ k("p", {
306
573
  className: "text-sm text-text-secondary",
307
- children: q.message
574
+ children: nt.message
308
575
  })
309
576
  ]
310
577
  })]
311
- }) : /* @__PURE__ */ _("div", {
578
+ }) : /* @__PURE__ */ A("div", {
312
579
  className: "p-6",
313
580
  children: [
314
- /* @__PURE__ */ _("div", {
581
+ /* @__PURE__ */ A("div", {
315
582
  className: "flex items-center justify-between mb-6",
316
- children: [/* @__PURE__ */ _("div", {
583
+ children: [/* @__PURE__ */ A("div", {
317
584
  className: "flex items-center gap-3",
318
585
  children: [
319
- /* @__PURE__ */ g(f, {
586
+ /* @__PURE__ */ k(b, {
320
587
  size: 24,
321
588
  className: "text-text-primary"
322
589
  }),
323
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("h1", {
590
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("h1", {
324
591
  className: "text-2xl font-bold text-text-primary",
325
592
  children: "Job Applications"
326
- }), /* @__PURE__ */ g("p", {
593
+ }), /* @__PURE__ */ k("p", {
327
594
  className: "text-sm text-text-secondary",
328
595
  children: "Careers form submissions"
329
596
  })] }),
330
- /* @__PURE__ */ g(e, {
597
+ /* @__PURE__ */ k(e, {
331
598
  variant: "secondary",
332
599
  className: "ml-2",
333
- children: Ue
600
+ children: ut
334
601
  })
335
602
  ]
336
- }), /* @__PURE__ */ _(t, {
337
- onClick: () => M(!0),
338
- children: [/* @__PURE__ */ g(ve, { size: 18 }), "Add Candidate"]
603
+ }), /* @__PURE__ */ A(t, {
604
+ onClick: () => H(!0),
605
+ children: [/* @__PURE__ */ k(ve, { size: 18 }), "Add Candidate"]
339
606
  })]
340
607
  }),
341
- /* @__PURE__ */ g(Te, {
608
+ Q.length > 0 && /* @__PURE__ */ A("div", {
609
+ className: "flex items-center gap-2 mb-4 -mt-2",
610
+ children: [
611
+ /* @__PURE__ */ k(n, {
612
+ checked: Q.length > 0 && Q.every((e) => Ve.has(e.id)),
613
+ disabled: Q.length > M,
614
+ onCheckedChange: (e) => B(e ? new Set(Q.map((e) => e.id)) : /* @__PURE__ */ new Set()),
615
+ "aria-label": "Select all visible applications"
616
+ }),
617
+ /* @__PURE__ */ k("span", {
618
+ className: "text-xs text-text-secondary",
619
+ children: vt
620
+ }),
621
+ $.length > 0 && /* @__PURE__ */ k("button", {
622
+ type: "button",
623
+ onClick: () => B(/* @__PURE__ */ new Set()),
624
+ className: "text-xs text-text-secondary hover:text-text-primary underline",
625
+ children: "Clear"
626
+ })
627
+ ]
628
+ }),
629
+ $.length > 0 && /* @__PURE__ */ A("div", {
630
+ className: "flex flex-col sm:flex-row sm:items-center justify-between gap-3 mb-4 p-3 rounded-lg border border-primary/30 bg-primary/5",
631
+ children: [/* @__PURE__ */ A("p", {
632
+ className: "text-sm text-text-primary font-medium",
633
+ children: [
634
+ $.length,
635
+ " candidate",
636
+ $.length === 1 ? "" : "s",
637
+ " ",
638
+ "selected"
639
+ ]
640
+ }), /* @__PURE__ */ A("div", {
641
+ className: "flex items-center gap-2",
642
+ children: [
643
+ !R && /* @__PURE__ */ k("p", {
644
+ className: "text-xs text-text-secondary",
645
+ children: "Filter to one job posting to enable bulk send"
646
+ }),
647
+ ht && /* @__PURE__ */ k("p", {
648
+ className: "text-xs text-status-error-text",
649
+ children: "Some selected candidates do not belong to this posting"
650
+ }),
651
+ gt && /* @__PURE__ */ A("p", {
652
+ className: "text-xs text-status-error-text",
653
+ children: [
654
+ "Select no more than ",
655
+ M,
656
+ " candidates"
657
+ ]
658
+ }),
659
+ /* @__PURE__ */ A(t, {
660
+ variant: "outline",
661
+ size: "sm",
662
+ disabled: !_t,
663
+ onClick: () => V("message"),
664
+ className: "gap-2",
665
+ children: [/* @__PURE__ */ k(be, { size: 14 }), "Send Message"]
666
+ }),
667
+ /* @__PURE__ */ A(t, {
668
+ variant: "outline",
669
+ size: "sm",
670
+ disabled: !_t,
671
+ onClick: () => V("assignment"),
672
+ className: "gap-2",
673
+ children: [/* @__PURE__ */ k(w, { size: 14 }), "Randomize & Send Assignment"]
674
+ })
675
+ ]
676
+ })]
677
+ }),
678
+ /* @__PURE__ */ k(Te, {
342
679
  className: "mb-6",
343
680
  children: "Candidates who apply through your careers pages show up here. Review resumes and move applicants through your hiring pipeline — from new submission to screening, interview and hire — so promising people get a timely response. Open an application to see the full profile and resume."
344
681
  }),
345
- /* @__PURE__ */ _("div", {
682
+ /* @__PURE__ */ A("div", {
346
683
  className: "flex flex-col sm:flex-row items-stretch sm:items-center gap-4 p-4 rounded-xl border border-border-seam bg-bg-surface mb-6",
347
684
  children: [
348
- /* @__PURE__ */ _("div", {
685
+ /* @__PURE__ */ A("div", {
349
686
  className: "relative flex-1",
350
- children: [/* @__PURE__ */ g(ye, {
687
+ children: [/* @__PURE__ */ k(ye, {
351
688
  size: 18,
352
689
  className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"
353
- }), /* @__PURE__ */ g(a, {
690
+ }), /* @__PURE__ */ k(o, {
354
691
  type: "text",
355
692
  "aria-label": "Search applications",
356
693
  placeholder: "Search by name, email, or position...",
357
- value: w,
358
- onChange: (e) => Me(e.target.value),
694
+ value: u,
695
+ onChange: (e) => me(e.target.value),
359
696
  className: "pl-10"
360
697
  })]
361
698
  }),
362
- /* @__PURE__ */ _("div", {
699
+ /* @__PURE__ */ A("div", {
363
700
  className: "flex items-center gap-1 p-1 rounded-lg border bg-bg-sunken/50",
364
- children: [/* @__PURE__ */ g(t, {
365
- variant: A === "list" ? "secondary" : "ghost",
701
+ children: [/* @__PURE__ */ k(t, {
702
+ variant: ze === "list" ? "secondary" : "ghost",
366
703
  size: "sm",
367
- onClick: () => j("list"),
704
+ onClick: () => Be("list"),
368
705
  className: "px-3",
369
706
  "aria-label": "Show applications as a list",
370
- children: /* @__PURE__ */ g(_e, { size: 18 })
371
- }), /* @__PURE__ */ g(t, {
372
- variant: A === "kanban" ? "secondary" : "ghost",
707
+ children: /* @__PURE__ */ k(_e, { size: 18 })
708
+ }), /* @__PURE__ */ k(t, {
709
+ variant: ze === "kanban" ? "secondary" : "ghost",
373
710
  size: "sm",
374
- onClick: () => j("kanban"),
711
+ onClick: () => Be("kanban"),
375
712
  className: "px-3",
376
713
  "aria-label": "Show applications as a kanban board",
377
- children: /* @__PURE__ */ g(ge, { size: 18 })
714
+ children: /* @__PURE__ */ k(ge, { size: 18 })
378
715
  })]
379
716
  }),
380
- /* @__PURE__ */ _(t, {
381
- variant: k ? "secondary" : "outline",
717
+ /* @__PURE__ */ A(t, {
718
+ variant: z ? "secondary" : "outline",
382
719
  size: "sm",
383
- onClick: () => Le(!k),
720
+ onClick: () => Re(!z),
384
721
  className: "gap-2",
385
722
  children: [
386
- /* @__PURE__ */ g(he, { size: 16 }),
723
+ /* @__PURE__ */ k(x, { size: 16 }),
387
724
  "Filters",
388
- /* @__PURE__ */ g(me, {
725
+ /* @__PURE__ */ k(he, {
389
726
  size: 14,
390
- className: k ? "rotate-180 transition-transform" : "transition-transform"
727
+ className: z ? "rotate-180 transition-transform" : "transition-transform"
391
728
  })
392
729
  ]
393
730
  })
394
731
  ]
395
732
  }),
396
- k && /* @__PURE__ */ g("div", {
397
- className: "mb-6 p-4 bg-bg-surface border border-border-seam rounded-lg",
398
- children: /* @__PURE__ */ _("div", {
399
- className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",
400
- children: [
401
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
402
- htmlFor: "job-app-status-filter",
403
- className: "block text-xs font-medium text-text-secondary mb-1",
404
- children: "Status"
405
- }), /* @__PURE__ */ _("select", {
406
- id: "job-app-status-filter",
407
- value: E,
408
- onChange: (e) => Pe(e.target.value),
409
- className: "w-full px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50",
410
- children: [
411
- /* @__PURE__ */ g("option", {
412
- value: "",
413
- children: "All statuses"
414
- }),
415
- /* @__PURE__ */ g("option", {
416
- value: "NEW",
417
- children: "New"
418
- }),
419
- /* @__PURE__ */ g("option", {
420
- value: "SCREENING",
421
- children: "Screening"
422
- }),
423
- /* @__PURE__ */ g("option", {
424
- value: "SHORTLISTED",
425
- children: "Shortlisted"
426
- }),
427
- /* @__PURE__ */ g("option", {
428
- value: "INTERVIEW",
429
- children: "Interview"
430
- }),
431
- /* @__PURE__ */ g("option", {
432
- value: "HIRED",
433
- children: "Hired"
434
- }),
435
- /* @__PURE__ */ g("option", {
436
- value: "REJECTED",
437
- children: "Rejected"
438
- }),
439
- /* @__PURE__ */ g("option", {
440
- value: "ARCHIVED",
441
- children: "Archived"
442
- })
443
- ]
444
- })] }),
445
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
733
+ z && /* @__PURE__ */ A("div", {
734
+ className: "mb-6 p-4 bg-bg-surface border border-border-seam rounded-lg space-y-4",
735
+ children: [
736
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ A("p", {
737
+ className: "block text-xs font-medium text-text-secondary mb-1.5",
738
+ children: ["Status ", /* @__PURE__ */ k("span", {
739
+ className: "font-normal",
740
+ children: "(select any number)"
741
+ })]
742
+ }), /* @__PURE__ */ A("div", {
743
+ className: "flex flex-wrap gap-1.5",
744
+ children: [g.map((e) => {
745
+ let t = P.has(e);
746
+ return /* @__PURE__ */ k("button", {
747
+ type: "button",
748
+ onClick: () => Ne((t) => N(t, e)),
749
+ "aria-pressed": t,
750
+ className: `px-2.5 py-1 rounded-full text-xs font-medium border transition-colors ${t ? `${m[e]} border-transparent` : "bg-bg-surface text-text-secondary border-border-seam hover:border-border-strong"}`,
751
+ children: h[e]
752
+ }, e);
753
+ }), P.size > 0 && /* @__PURE__ */ k("button", {
754
+ type: "button",
755
+ onClick: () => Ne(/* @__PURE__ */ new Set()),
756
+ className: "px-2.5 py-1 rounded-full text-xs font-medium text-text-secondary hover:text-text-primary underline",
757
+ children: "Clear"
758
+ })]
759
+ })] }),
760
+ /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ A("p", {
761
+ className: "block text-xs font-medium text-text-secondary mb-1.5",
762
+ children: ["Interview round stage ", /* @__PURE__ */ k("span", {
763
+ className: "font-normal",
764
+ children: "(select any number)"
765
+ })]
766
+ }), /* @__PURE__ */ A("div", {
767
+ className: "flex flex-wrap gap-1.5",
768
+ children: [p.map((e) => {
769
+ let t = I.has(e), n = fe[e];
770
+ return /* @__PURE__ */ k("button", {
771
+ type: "button",
772
+ onClick: () => Fe((t) => N(t, e)),
773
+ "aria-pressed": t,
774
+ className: `px-2.5 py-1 rounded-full text-xs font-medium border transition-colors ${t ? `${n.className} border-transparent` : "bg-bg-surface text-text-secondary border-border-seam hover:border-border-strong"}`,
775
+ children: n.label
776
+ }, e);
777
+ }), I.size > 0 && /* @__PURE__ */ k("button", {
778
+ type: "button",
779
+ onClick: () => Fe(/* @__PURE__ */ new Set()),
780
+ className: "px-2.5 py-1 rounded-full text-xs font-medium text-text-secondary hover:text-text-primary underline",
781
+ children: "Clear"
782
+ })]
783
+ })] }),
784
+ /* @__PURE__ */ A("div", {
785
+ className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",
786
+ children: [/* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("label", {
446
787
  htmlFor: "job-app-product-filter",
447
788
  className: "block text-xs font-medium text-text-secondary mb-1",
448
789
  children: "Product"
449
- }), /* @__PURE__ */ _("select", {
790
+ }), /* @__PURE__ */ A("select", {
450
791
  id: "job-app-product-filter",
451
- value: D,
452
- onChange: (e) => Fe(e.target.value),
792
+ value: L,
793
+ onChange: (e) => Ie(e.target.value),
453
794
  className: "w-full px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50",
454
- children: [/* @__PURE__ */ g("option", {
795
+ children: [/* @__PURE__ */ k("option", {
455
796
  value: "",
456
797
  children: "All products"
457
- }), Ge.map((e) => /* @__PURE__ */ g("option", {
798
+ }), yt.map((e) => /* @__PURE__ */ k("option", {
458
799
  value: e,
459
- children: U[e] || e
800
+ children: Y[e] || e
460
801
  }, e))]
461
- })] }),
462
- /* @__PURE__ */ _("div", { children: [/* @__PURE__ */ g("label", {
802
+ })] }), /* @__PURE__ */ A("div", { children: [/* @__PURE__ */ k("label", {
463
803
  htmlFor: "job-app-posting-filter",
464
804
  className: "block text-xs font-medium text-text-secondary mb-1",
465
805
  children: "Job Posting"
466
- }), /* @__PURE__ */ _("select", {
806
+ }), /* @__PURE__ */ A("select", {
467
807
  id: "job-app-posting-filter",
468
- value: O,
469
- onChange: (e) => Ie(e.target.value),
470
- disabled: Y,
808
+ value: R,
809
+ onChange: (e) => Le(e.target.value),
810
+ disabled: at,
471
811
  className: "w-full px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50 disabled:opacity-50",
472
- children: [/* @__PURE__ */ g("option", {
812
+ children: [/* @__PURE__ */ k("option", {
473
813
  value: "",
474
814
  children: "All postings"
475
- }), (J?.jobPostings?.items ?? []).map((e) => /* @__PURE__ */ g("option", {
815
+ }), (it?.jobPostings?.items ?? []).map((e) => /* @__PURE__ */ k("option", {
476
816
  value: e.id,
477
817
  children: e.title
478
818
  }, e.id))]
479
- })] })
480
- ]
481
- })
819
+ })] })]
820
+ })
821
+ ]
482
822
  }),
483
- X.length === 0 ? /* @__PURE__ */ g(we, {
823
+ Q.length === 0 ? /* @__PURE__ */ k(we, {
484
824
  illustration: "empty-people",
485
825
  title: "No applications yet",
486
826
  description: "Job applications from your careers pages will appear here."
487
- }) : /* @__PURE__ */ _(h, { children: [A === "list" ? /* @__PURE__ */ g("div", {
827
+ }) : /* @__PURE__ */ A(O, { children: [ze === "list" ? /* @__PURE__ */ k("div", {
488
828
  className: "space-y-3",
489
- children: X.map((e) => Ze(e))
490
- }) : /* @__PURE__ */ g("div", {
829
+ children: Q.map((e) => Dt(e))
830
+ }) : /* @__PURE__ */ k("div", {
491
831
  className: "flex gap-4 overflow-x-auto pb-4",
492
- children: v.map((t) => {
493
- let n = Xe[t] ?? [];
494
- return /* @__PURE__ */ _("div", {
832
+ children: g.map((t) => {
833
+ let n = Et[t] ?? [];
834
+ return /* @__PURE__ */ A("div", {
495
835
  className: "flex flex-col gap-3 w-[280px] flex-shrink-0 max-h-[calc(100vh-280px)]",
496
- children: [/* @__PURE__ */ _("div", {
836
+ children: [/* @__PURE__ */ A("div", {
497
837
  className: "flex items-center justify-between px-1",
498
- children: [/* @__PURE__ */ g("h3", {
838
+ children: [/* @__PURE__ */ k("h3", {
499
839
  className: "text-sm font-semibold text-text-primary",
500
- children: b[t]
501
- }), /* @__PURE__ */ g(e, {
840
+ children: h[t]
841
+ }), /* @__PURE__ */ k(e, {
502
842
  variant: "secondary",
503
- className: y[t],
843
+ className: m[t],
504
844
  children: n.length
505
845
  })]
506
- }), /* @__PURE__ */ _("div", {
846
+ }), /* @__PURE__ */ A("div", {
507
847
  className: "flex flex-col gap-3 overflow-y-auto pr-1",
508
- children: [n.length === 0 && /* @__PURE__ */ g("div", {
848
+ children: [n.length === 0 && /* @__PURE__ */ k("div", {
509
849
  className: "text-center py-6 px-3 rounded-lg border border-dashed border-border-seam bg-bg-sunken/30",
510
- children: /* @__PURE__ */ g("p", {
850
+ children: /* @__PURE__ */ k("p", {
511
851
  className: "text-xs text-text-secondary",
512
852
  children: "No applications"
513
853
  })
514
- }), n.map((e) => Ze(e, !0))]
854
+ }), n.map((e) => Dt(e, !0))]
515
855
  })]
516
856
  }, t);
517
857
  })
518
- }), Z && /* @__PURE__ */ g("div", {
858
+ }), dt && /* @__PURE__ */ k("div", {
519
859
  className: "flex justify-center mt-6",
520
- children: /* @__PURE__ */ _(t, {
860
+ children: /* @__PURE__ */ A(t, {
521
861
  variant: "outline",
522
862
  size: "sm",
523
- onClick: Ke,
524
- disabled: K,
863
+ onClick: () => void xt(),
864
+ disabled: Je,
525
865
  className: "gap-2",
526
- children: [K ? /* @__PURE__ */ g(p, {
866
+ children: [Je ? /* @__PURE__ */ k(S, {
527
867
  size: 14,
528
868
  className: "animate-spin"
529
869
  }) : null, "Load more"]
530
870
  })
531
871
  })] }),
532
- /* @__PURE__ */ g(n, {
533
- open: Re,
872
+ /* @__PURE__ */ k(r, {
873
+ open: Ue,
534
874
  onOpenChange: (e) => {
535
- M(e), e || $();
875
+ H(e), e || St();
536
876
  },
537
- children: /* @__PURE__ */ _(r, {
877
+ children: /* @__PURE__ */ A(i, {
538
878
  className: "sm:max-w-2xl max-h-[90vh] overflow-y-auto",
539
879
  children: [
540
- /* @__PURE__ */ _(te, { children: [/* @__PURE__ */ g(ne, { children: "Add Candidate" }), /* @__PURE__ */ g(i, { children: "Manually add a candidate to the hiring pipeline. Resumes are optional and can be attached as PDF, DOC, or DOCX (max 10 MB)." })] }),
541
- /* @__PURE__ */ _("form", {
880
+ /* @__PURE__ */ A(te, { children: [/* @__PURE__ */ k(ne, { children: "Add Candidate" }), /* @__PURE__ */ k(a, { children: "Manually add a candidate to the hiring pipeline. Resumes are optional and can be attached as PDF, DOC, or DOCX (max 10 MB)." })] }),
881
+ /* @__PURE__ */ A("form", {
542
882
  id: "add-candidate-form",
543
- onSubmit: Ye,
883
+ onSubmit: Tt,
544
884
  className: "space-y-4",
545
885
  children: [
546
- /* @__PURE__ */ _("div", {
886
+ /* @__PURE__ */ A("div", {
547
887
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
548
- children: [/* @__PURE__ */ _("div", {
888
+ children: [/* @__PURE__ */ A("div", {
549
889
  className: "space-y-1.5",
550
890
  children: [
551
- /* @__PURE__ */ _(o, {
891
+ /* @__PURE__ */ A(s, {
552
892
  htmlFor: "candidate-name",
553
- children: ["Name ", /* @__PURE__ */ g("span", {
893
+ children: ["Name ", /* @__PURE__ */ k("span", {
554
894
  className: "text-status-error-text",
555
895
  children: "*"
556
896
  })]
557
897
  }),
558
- /* @__PURE__ */ g(a, {
898
+ /* @__PURE__ */ k(o, {
559
899
  id: "candidate-name",
560
- value: N.name,
561
- onChange: (e) => P((t) => ({
900
+ value: U.name,
901
+ onChange: (e) => W((t) => ({
562
902
  ...t,
563
903
  name: e.target.value
564
904
  })),
565
905
  placeholder: "Full name",
566
- "aria-invalid": !!F.name
906
+ "aria-invalid": !!G.name
567
907
  }),
568
- F.name && /* @__PURE__ */ g("p", {
908
+ G.name && /* @__PURE__ */ k("p", {
569
909
  className: "text-xs text-status-error-text",
570
- children: F.name
910
+ children: G.name
571
911
  })
572
912
  ]
573
- }), /* @__PURE__ */ _("div", {
913
+ }), /* @__PURE__ */ A("div", {
574
914
  className: "space-y-1.5",
575
915
  children: [
576
- /* @__PURE__ */ _(o, {
916
+ /* @__PURE__ */ A(s, {
577
917
  htmlFor: "candidate-email",
578
- children: ["Email ", /* @__PURE__ */ g("span", {
918
+ children: ["Email ", /* @__PURE__ */ k("span", {
579
919
  className: "text-status-error-text",
580
920
  children: "*"
581
921
  })]
582
922
  }),
583
- /* @__PURE__ */ g(a, {
923
+ /* @__PURE__ */ k(o, {
584
924
  id: "candidate-email",
585
925
  type: "email",
586
- value: N.email,
587
- onChange: (e) => P((t) => ({
926
+ value: U.email,
927
+ onChange: (e) => W((t) => ({
588
928
  ...t,
589
929
  email: e.target.value
590
930
  })),
591
931
  placeholder: "email@example.com",
592
- "aria-invalid": !!F.email
932
+ "aria-invalid": !!G.email
593
933
  }),
594
- F.email && /* @__PURE__ */ g("p", {
934
+ G.email && /* @__PURE__ */ k("p", {
595
935
  className: "text-xs text-status-error-text",
596
- children: F.email
936
+ children: G.email
597
937
  })
598
938
  ]
599
939
  })]
600
940
  }),
601
- /* @__PURE__ */ _("div", {
941
+ /* @__PURE__ */ A("div", {
602
942
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
603
- children: [/* @__PURE__ */ _("div", {
943
+ children: [/* @__PURE__ */ A("div", {
604
944
  className: "space-y-1.5",
605
- children: [/* @__PURE__ */ g(o, {
945
+ children: [/* @__PURE__ */ k(s, {
606
946
  htmlFor: "candidate-phone",
607
947
  children: "Phone"
608
- }), /* @__PURE__ */ g(a, {
948
+ }), /* @__PURE__ */ k(o, {
609
949
  id: "candidate-phone",
610
- value: N.phone,
611
- onChange: (e) => P((t) => ({
950
+ value: U.phone,
951
+ onChange: (e) => W((t) => ({
612
952
  ...t,
613
953
  phone: e.target.value
614
954
  })),
615
955
  placeholder: "+91 98765 43210"
616
956
  })]
617
- }), /* @__PURE__ */ _("div", {
957
+ }), /* @__PURE__ */ A("div", {
618
958
  className: "space-y-1.5",
619
959
  children: [
620
- /* @__PURE__ */ _(o, {
960
+ /* @__PURE__ */ A(s, {
621
961
  htmlFor: "candidate-source",
622
- children: ["Source ", /* @__PURE__ */ g("span", {
962
+ children: ["Source ", /* @__PURE__ */ k("span", {
623
963
  className: "text-status-error-text",
624
964
  children: "*"
625
965
  })]
626
966
  }),
627
- /* @__PURE__ */ g(a, {
967
+ /* @__PURE__ */ k(o, {
628
968
  id: "candidate-source",
629
969
  list: "candidate-source-suggestions",
630
- value: N.source,
631
- onChange: (e) => P((t) => ({
970
+ value: U.source,
971
+ onChange: (e) => W((t) => ({
632
972
  ...t,
633
973
  source: e.target.value
634
974
  })),
635
975
  placeholder: "e.g. LinkedIn",
636
- "aria-invalid": !!F.source
976
+ "aria-invalid": !!G.source
637
977
  }),
638
- /* @__PURE__ */ g("datalist", {
978
+ /* @__PURE__ */ k("datalist", {
639
979
  id: "candidate-source-suggestions",
640
- children: De.map((e) => /* @__PURE__ */ g("option", { value: e }, e))
980
+ children: De.map((e) => /* @__PURE__ */ k("option", { value: e }, e))
641
981
  }),
642
- F.source && /* @__PURE__ */ g("p", {
982
+ G.source && /* @__PURE__ */ k("p", {
643
983
  className: "text-xs text-status-error-text",
644
- children: F.source
984
+ children: G.source
645
985
  })
646
986
  ]
647
987
  })]
648
988
  }),
649
- /* @__PURE__ */ _("div", {
989
+ /* @__PURE__ */ A("div", {
650
990
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
651
- children: [/* @__PURE__ */ _("div", {
991
+ children: [/* @__PURE__ */ A("div", {
652
992
  className: "space-y-1.5",
653
993
  children: [
654
- /* @__PURE__ */ g(o, {
994
+ /* @__PURE__ */ k(s, {
655
995
  htmlFor: "candidate-job-posting",
656
996
  children: "Job Posting"
657
997
  }),
658
- /* @__PURE__ */ _(re, {
659
- value: N.jobPostingId,
660
- onValueChange: (e) => P((t) => ({
998
+ /* @__PURE__ */ A(re, {
999
+ value: U.jobPostingId,
1000
+ onValueChange: (e) => W((t) => ({
661
1001
  ...t,
662
1002
  jobPostingId: e
663
1003
  })),
664
- disabled: Y,
665
- children: [/* @__PURE__ */ g(ae, {
1004
+ disabled: at,
1005
+ children: [/* @__PURE__ */ k(oe, {
666
1006
  id: "candidate-job-posting",
667
- children: /* @__PURE__ */ g(oe, { placeholder: "Select an open posting" })
668
- }), /* @__PURE__ */ _(ie, { children: [/* @__PURE__ */ g(s, {
669
- value: S,
1007
+ children: /* @__PURE__ */ k(se, { placeholder: "Select an open posting" })
1008
+ }), /* @__PURE__ */ A(ie, { children: [/* @__PURE__ */ k(ae, {
1009
+ value: F,
670
1010
  children: "No posting (manual entry)"
671
- }), He.map((e) => /* @__PURE__ */ g(s, {
1011
+ }), st.map((e) => /* @__PURE__ */ k(ae, {
672
1012
  value: e.id,
673
1013
  children: e.title
674
1014
  }, e.id))] })]
675
1015
  }),
676
- /* @__PURE__ */ g("p", {
1016
+ /* @__PURE__ */ k("p", {
677
1017
  className: "text-xs text-text-secondary",
678
1018
  children: "Position and department are derived from the selected posting."
679
1019
  })
680
1020
  ]
681
- }), /* @__PURE__ */ _("div", {
1021
+ }), /* @__PURE__ */ A("div", {
682
1022
  className: "space-y-1.5",
683
1023
  children: [
684
- /* @__PURE__ */ _(o, {
1024
+ /* @__PURE__ */ A(s, {
685
1025
  htmlFor: "candidate-position",
686
1026
  children: [
687
1027
  "Position",
688
1028
  " ",
689
- N.jobPostingId === S && /* @__PURE__ */ g("span", {
1029
+ U.jobPostingId === F && /* @__PURE__ */ k("span", {
690
1030
  className: "text-status-error-text",
691
1031
  children: "*"
692
1032
  })
693
1033
  ]
694
1034
  }),
695
- /* @__PURE__ */ g(a, {
1035
+ /* @__PURE__ */ k(o, {
696
1036
  id: "candidate-position",
697
- value: N.position,
698
- onChange: (e) => P((t) => ({
1037
+ value: U.position,
1038
+ onChange: (e) => W((t) => ({
699
1039
  ...t,
700
1040
  position: e.target.value
701
1041
  })),
702
1042
  placeholder: "e.g. Product Engineer",
703
- disabled: N.jobPostingId !== S,
704
- "aria-invalid": !!F.position
1043
+ disabled: U.jobPostingId !== F,
1044
+ "aria-invalid": !!G.position
705
1045
  }),
706
- F.position && /* @__PURE__ */ g("p", {
1046
+ G.position && /* @__PURE__ */ k("p", {
707
1047
  className: "text-xs text-status-error-text",
708
- children: F.position
1048
+ children: G.position
709
1049
  })
710
1050
  ]
711
1051
  })]
712
1052
  }),
713
- /* @__PURE__ */ _("div", {
1053
+ /* @__PURE__ */ A("div", {
714
1054
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
715
- children: [/* @__PURE__ */ _("div", {
1055
+ children: [/* @__PURE__ */ A("div", {
716
1056
  className: "space-y-1.5",
717
- children: [/* @__PURE__ */ g(o, {
1057
+ children: [/* @__PURE__ */ k(s, {
718
1058
  htmlFor: "candidate-linkedin",
719
1059
  children: "LinkedIn"
720
- }), /* @__PURE__ */ g(a, {
1060
+ }), /* @__PURE__ */ k(o, {
721
1061
  id: "candidate-linkedin",
722
- value: N.linkedin,
723
- onChange: (e) => P((t) => ({
1062
+ value: U.linkedin,
1063
+ onChange: (e) => W((t) => ({
724
1064
  ...t,
725
1065
  linkedin: e.target.value
726
1066
  })),
727
1067
  placeholder: "https://linkedin.com/in/…"
728
1068
  })]
729
- }), /* @__PURE__ */ _("div", {
1069
+ }), /* @__PURE__ */ A("div", {
730
1070
  className: "space-y-1.5",
731
- children: [/* @__PURE__ */ g(o, {
1071
+ children: [/* @__PURE__ */ k(s, {
732
1072
  htmlFor: "candidate-portfolio",
733
1073
  children: "Portfolio"
734
- }), /* @__PURE__ */ g(a, {
1074
+ }), /* @__PURE__ */ k(o, {
735
1075
  id: "candidate-portfolio",
736
- value: N.portfolio,
737
- onChange: (e) => P((t) => ({
1076
+ value: U.portfolio,
1077
+ onChange: (e) => W((t) => ({
738
1078
  ...t,
739
1079
  portfolio: e.target.value
740
1080
  })),
@@ -742,15 +1082,15 @@ function w() {
742
1082
  })]
743
1083
  })]
744
1084
  }),
745
- /* @__PURE__ */ _("div", {
1085
+ /* @__PURE__ */ A("div", {
746
1086
  className: "space-y-1.5",
747
- children: [/* @__PURE__ */ g(o, {
1087
+ children: [/* @__PURE__ */ k(s, {
748
1088
  htmlFor: "candidate-cover-letter",
749
1089
  children: "Cover Letter"
750
- }), /* @__PURE__ */ g(se, {
1090
+ }), /* @__PURE__ */ k(ce, {
751
1091
  id: "candidate-cover-letter",
752
- value: N.coverLetter,
753
- onChange: (e) => P((t) => ({
1092
+ value: U.coverLetter,
1093
+ onChange: (e) => W((t) => ({
754
1094
  ...t,
755
1095
  coverLetter: e.target.value
756
1096
  })),
@@ -758,62 +1098,69 @@ function w() {
758
1098
  rows: 4
759
1099
  })]
760
1100
  }),
761
- /* @__PURE__ */ _("div", {
1101
+ /* @__PURE__ */ A("div", {
762
1102
  className: "space-y-1.5",
763
1103
  children: [
764
- /* @__PURE__ */ g(o, {
1104
+ /* @__PURE__ */ k(s, {
765
1105
  htmlFor: "candidate-resume",
766
1106
  children: "Resume (optional)"
767
1107
  }),
768
- /* @__PURE__ */ g(a, {
1108
+ /* @__PURE__ */ k(o, {
769
1109
  id: "candidate-resume",
770
1110
  type: "file",
771
1111
  accept: ke,
772
- onChange: qe
1112
+ onChange: Ct
773
1113
  }),
774
- /* @__PURE__ */ _("p", {
1114
+ /* @__PURE__ */ A("p", {
775
1115
  className: "text-xs text-text-secondary flex items-center gap-1",
776
1116
  children: [
777
- /* @__PURE__ */ g(m, { size: 11 }),
1117
+ /* @__PURE__ */ k(C, { size: 11 }),
778
1118
  "PDF, DOC, or DOCX up to 10 MB.",
779
- L ? ` Selected: ${L.name}` : ""
1119
+ K ? ` Selected: ${K.name}` : ""
780
1120
  ]
781
1121
  }),
782
- z && /* @__PURE__ */ g("p", {
1122
+ Ge && /* @__PURE__ */ k("p", {
783
1123
  className: "text-xs text-status-error-text",
784
- children: z
1124
+ children: Ge
785
1125
  })
786
1126
  ]
787
1127
  })
788
1128
  ]
789
1129
  }),
790
- /* @__PURE__ */ _(ee, { children: [/* @__PURE__ */ g(t, {
1130
+ /* @__PURE__ */ A(ee, { children: [/* @__PURE__ */ k(t, {
791
1131
  type: "button",
792
1132
  variant: "outline",
793
1133
  onClick: () => {
794
- M(!1), $();
1134
+ H(!1), St();
795
1135
  },
796
- disabled: V,
1136
+ disabled: Ke,
797
1137
  children: "Cancel"
798
- }), /* @__PURE__ */ g(t, {
1138
+ }), /* @__PURE__ */ k(t, {
799
1139
  type: "submit",
800
1140
  form: "add-candidate-form",
801
- disabled: V,
802
- children: V ? /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g(p, {
1141
+ disabled: Ke,
1142
+ children: Ke ? /* @__PURE__ */ A(O, { children: [/* @__PURE__ */ k(S, {
803
1143
  size: 16,
804
1144
  className: "animate-spin mr-2"
805
- }), "Adding…"] }) : /* @__PURE__ */ _(h, { children: [/* @__PURE__ */ g(be, {
1145
+ }), "Adding…"] }) : /* @__PURE__ */ A(O, { children: [/* @__PURE__ */ k(E, {
806
1146
  size: 16,
807
1147
  className: "mr-2"
808
1148
  }), "Add Candidate"] })
809
1149
  })] })
810
1150
  ]
811
1151
  })
1152
+ }),
1153
+ He && /* @__PURE__ */ k(Pe, {
1154
+ mode: He,
1155
+ open: !!He,
1156
+ onClose: () => V(null),
1157
+ applications: mt,
1158
+ jobPostingId: R
812
1159
  })
813
1160
  ]
814
1161
  });
815
1162
  }
816
1163
  //#endregion
817
- export { w as JobApplicationsPage };
1164
+ export { I as JobApplicationsPage };
818
1165
 
819
1166
  //# sourceMappingURL=JobApplicationsPage.js.map