@burdenoff/microfe-support 2026.902.3 → 2026.903.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,13 +1,13 @@
1
- import { Badge as e, Button as t, Card as n, CardContent as r, CardHeader as i, CardTitle as ee, Dialog as a, DialogContent as te, DialogDescription as o, DialogFooter as s, DialogHeader as ne, DialogTitle as re, Input as ie, Label as c, Select as l, SelectContent as u, SelectItem as d, SelectTrigger as f, SelectValue as p, Textarea as ae } from "../components/ui.js";
2
- import { useAssignInterviewersToRoundMutation as oe, useCreateInterviewRoundMutation as se, useGetInterviewersQuery as m, useGetJobApplicationInterviewRoundsQuery as ce, useGetJobApplicationQuery as h, useGetJobApplicationResumePreviewUrlLazyQuery as g, useGetJobApplicationResumeUrlLazyQuery as le, useGetJobPostingQuery as _, useRandomizeAndSendAssignmentMutation as v, useRecordAssignmentSubmissionMutation as ue, useRemoveInterviewerFromRoundMutation as y, useReplyToJobApplicationMutation as b, useSendRoundMessageToCandidateMutation as de, useSubmitInterviewFeedbackMutation as fe, useUpdateInterviewFeedbackMutation as pe, useUpdateInterviewRoundMutation as me, useUpdateJobApplicationStatusMutation as he } from "../../generated/global-operations.js";
1
+ import { Badge as e, Button as t, Card as n, CardContent as r, CardHeader as i, CardTitle as ee, Dialog as a, DialogContent as te, DialogDescription as o, DialogFooter as s, DialogHeader as c, DialogTitle as ne, Input as re, Label as l, Select as u, SelectContent as d, SelectItem as f, SelectTrigger as p, SelectValue as m, Textarea as ie } from "../components/ui.js";
2
+ import { useAssignInterviewersToRoundMutation as ae, useCreateInterviewRoundMutation as oe, useGetInterviewersQuery as se, useGetJobApplicationInterviewRoundsQuery as ce, useGetJobApplicationQuery as h, useGetJobApplicationResumePreviewUrlLazyQuery as g, useGetJobApplicationResumeUrlLazyQuery as le, useGetJobPostingQuery as _, useRandomizeAndSendAssignmentMutation as v, useRecordAssignmentSubmissionMutation as ue, useRemoveInterviewerFromRoundMutation as y, useReplyToJobApplicationMutation as b, useSendRoundMessageToCandidateMutation as de, useSubmitInterviewFeedbackMutation as fe, useUpdateInterviewFeedbackMutation as pe, useUpdateInterviewRoundMutation as me, useUpdateJobApplicationStatusMutation as he } from "../../generated/global-operations.js";
3
3
  import { InterviewRoundStatus as x, InterviewRoundType as S, InterviewVerdict as ge, InterviewerRole as C } from "../../generated/global-types.js";
4
+ import { roundStatusConfig as w, roundStatusOrder as T } from "../constants/pipeline.js";
4
5
  import _e from "../../node_modules/dompurify/dist/purify.es.js";
5
- import { nativeCopyText as ve, nativeImpact as w } from "../../utils/nativeBridge.js";
6
+ import { nativeCopyText as ve, nativeImpact as E } from "../../utils/nativeBridge.js";
6
7
  /* empty css */
7
- import { roundStatusConfig as T, roundStatusOrder as E } from "../constants/pipeline.js";
8
- import { RichTextEditor as ye } from "../components/careers/RichTextEditor.js";
9
- import { useEffect as D, useState as O } from "react";
10
- import { AlertCircle as be, Archive as xe, ArrowLeft as k, Briefcase as A, Building2 as j, Calendar as M, CheckCircle as N, Clock as P, Copy as F, Download as I, Edit3 as L, ExternalLink as R, Eye as z, FileText as B, Globe as V, Inbox as H, Link2 as U, Linkedin as Se, Loader2 as W, Mail as G, MessageSquare as Ce, Package as K, Phone as we, Plus as Te, Send as Ee, Star as De, User as Oe, UserPlus as ke, UserX as Ae, Users as q, XCircle as J } from "lucide-react";
8
+ import { RichTextEditor as D } from "../components/careers/RichTextEditor.js";
9
+ import { useEffect as O, useState as k } from "react";
10
+ import { AlertCircle as A, Archive as ye, ArrowLeft as j, Briefcase as M, Building2 as N, Calendar as P, CheckCircle as F, Clock as be, Copy as I, Download as L, Edit3 as R, ExternalLink as xe, Eye as z, FileText as B, Globe as V, Inbox as H, Link2 as U, Linkedin as Se, Loader2 as W, Mail as G, MessageSquare as Ce, Package as K, Phone as we, Plus as Te, Send as Ee, Star as De, User as Oe, UserPlus as ke, UserX as Ae, Users as q, XCircle as J } from "lucide-react";
11
11
  import { useLocation as je, useNavigate as Me, useParams as Ne } from "react-router";
12
12
  import { graphqlFetch as Pe } from "@burdenoff/fe-libs/shared/graphql/fetch";
13
13
  import { Fragment as Fe, jsx as Y, jsxs as X } from "react/jsx-runtime";
@@ -41,7 +41,7 @@ var Z = "__custom__", Be = {
41
41
  HIRED: {
42
42
  label: "Hired",
43
43
  color: "text-status-success-text",
44
- icon: N,
44
+ icon: F,
45
45
  bg: "bg-status-success-bg-subtle border-border-subtle"
46
46
  },
47
47
  REJECTED: {
@@ -53,7 +53,7 @@ var Z = "__custom__", Be = {
53
53
  ARCHIVED: {
54
54
  label: "Archived",
55
55
  color: "text-text-secondary",
56
- icon: xe,
56
+ icon: ye,
57
57
  bg: "bg-bg-canvas border-border-subtle"
58
58
  }
59
59
  };
@@ -100,32 +100,32 @@ function We(e) {
100
100
  return null;
101
101
  }
102
102
  }
103
- function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading: s, onAssign: ne, onRemoveInterviewer: re, onSendMessage: oe, onSubmitFeedback: se, onUpdateFeedback: m }) {
104
- let [ce, h] = O(!1), [g, le] = O(null), [_, y] = O(""), [b, de] = O(""), [fe, pe] = O(""), [he, x] = O(""), [C, ve] = O(a.submittedRepoUrl ?? ""), [w, ye] = O(a.submittedVideoUrl ?? ""), [D, xe] = O(a.submittedNotes ?? ""), [k, A] = O(null), [j, N] = O(a.notes ?? ""), [P, F] = O(!1), [I, { loading: R }] = v({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [z, { loading: V }] = ue({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [H, { loading: U }] = me({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplications"] }), Se = a.roundType === S.TakeHome || !!a.roundConfig?.isAssignmentRound, G = !!a.assignment, K = !!(a.submittedRepoUrl || a.submittedVideoUrl || a.submittedAt), we = G || K, Oe = a.emailLogs.find((e) => e.emailType === "ASSIGNMENT")?.sentAt, q = T[a.status] ?? T.SCHEDULED, J = () => {
103
+ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading: s, onAssign: c, onRemoveInterviewer: ne, onSendMessage: ae, onSubmitFeedback: oe, onUpdateFeedback: se }) {
104
+ let [ce, h] = k(!1), [g, le] = k(null), [_, y] = k(""), [b, de] = k(""), [fe, pe] = k(""), [he, x] = k(""), [C, ve] = k(a.submittedRepoUrl ?? ""), [E, D] = k(a.submittedVideoUrl ?? ""), [O, ye] = k(a.submittedNotes ?? ""), [j, M] = k(null), [N, F] = k(a.notes ?? ""), [be, I] = k(!1), [L, { loading: xe }] = v({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [z, { loading: V }] = ue({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [H, { loading: U }] = me({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplications"] }), Se = a.roundType === S.TakeHome || !!a.roundConfig?.isAssignmentRound, G = !!a.assignment, K = !!(a.submittedRepoUrl || a.submittedVideoUrl || a.submittedAt), we = G || K, Oe = a.emailLogs.find((e) => e.emailType === "ASSIGNMENT")?.sentAt, q = w[a.status] ?? w.SCHEDULED, J = () => {
105
105
  le(null), y(""), de(""), pe(""), x("");
106
106
  }, je = async () => {
107
- A(null);
107
+ M(null);
108
108
  try {
109
- await I({ variables: { input: {
109
+ await L({ variables: { input: {
110
110
  applicationId: te,
111
111
  roundId: a.id
112
112
  } } });
113
113
  } catch (e) {
114
- console.error("Failed to randomize and send assignment:", e), A("Failed to randomize and send assignment.");
114
+ console.error("Failed to randomize and send assignment:", e), M("Failed to randomize and send assignment.");
115
115
  }
116
116
  }, Me = async () => {
117
- A(null);
118
- let e = C.trim() || void 0, t = w.trim() || void 0, n = D.trim() || void 0;
117
+ M(null);
118
+ let e = C.trim() || void 0, t = E.trim() || void 0, n = O.trim() || void 0;
119
119
  if (e && !We(e)) {
120
- A("GitHub repo URL must start with http:// or https://.");
120
+ M("GitHub repo URL must start with http:// or https://.");
121
121
  return;
122
122
  }
123
123
  if (t && !We(t)) {
124
- A("Jam video URL must start with http:// or https://.");
124
+ M("Jam video URL must start with http:// or https://.");
125
125
  return;
126
126
  }
127
127
  if (!e && !t && !n) {
128
- A("Please provide at least a repo URL, video URL, or notes.");
128
+ M("Please provide at least a repo URL, video URL, or notes.");
129
129
  return;
130
130
  }
131
131
  try {
@@ -136,7 +136,7 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
136
136
  notes: n
137
137
  } } });
138
138
  } catch (e) {
139
- console.error("Failed to record assignment submission:", e), A("Failed to record submission.");
139
+ console.error("Failed to record assignment submission:", e), M("Failed to record submission.");
140
140
  }
141
141
  }, Ne = async (e) => {
142
142
  if (e !== a.status) try {
@@ -151,8 +151,8 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
151
151
  try {
152
152
  await H({ variables: {
153
153
  id: a.id,
154
- input: { notes: j.trim() || null }
155
- } }), F(!0), setTimeout(() => F(!1), 2e3);
154
+ input: { notes: N.trim() || null }
155
+ } }), I(!0), setTimeout(() => I(!1), 2e3);
156
156
  } catch (e) {
157
157
  console.error("Failed to save round notes:", e);
158
158
  }
@@ -184,26 +184,26 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
184
184
  onChange: (e) => Ne(e.target.value),
185
185
  disabled: U,
186
186
  className: `text-xs font-medium rounded-full pl-2 pr-1.5 py-0.5 border-0 focus:outline-none focus:ring-2 focus:ring-primary/30 disabled:opacity-50 ${q.className}`,
187
- children: E.map((e) => /* @__PURE__ */ Y("option", {
187
+ children: T.map((e) => /* @__PURE__ */ Y("option", {
188
188
  value: e,
189
- children: T[e].label
189
+ children: w[e].label
190
190
  }, e))
191
191
  })
192
192
  ]
193
193
  }), a.scheduledAt && /* @__PURE__ */ X("p", {
194
194
  className: "text-xs text-text-secondary flex items-center gap-1",
195
- children: [/* @__PURE__ */ Y(M, { size: 12 }), Q(a.scheduledAt)]
195
+ children: [/* @__PURE__ */ Y(P, { size: 12 }), Q(a.scheduledAt)]
196
196
  })] }), /* @__PURE__ */ X("div", {
197
197
  className: "flex items-center gap-2",
198
198
  children: [/* @__PURE__ */ X(t, {
199
199
  variant: "outline",
200
200
  size: "sm",
201
- onClick: ne,
201
+ onClick: c,
202
202
  children: [/* @__PURE__ */ Y(ke, { size: 14 }), "Assign"]
203
203
  }), /* @__PURE__ */ X(t, {
204
204
  variant: "outline",
205
205
  size: "sm",
206
- onClick: oe,
206
+ onClick: ae,
207
207
  children: [/* @__PURE__ */ Y(Ce, { size: 14 }), "Message"]
208
208
  })]
209
209
  })]
@@ -229,7 +229,7 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
229
229
  }),
230
230
  /* @__PURE__ */ Y("button", {
231
231
  type: "button",
232
- onClick: () => re(a.id, t.interviewer.id),
232
+ onClick: () => ne(a.id, t.interviewer.id),
233
233
  className: "p-0.5 rounded-full hover:bg-status-error-bg-subtle hover:text-status-error-text transition-colors",
234
234
  title: "Remove interviewer",
235
235
  children: /* @__PURE__ */ Y(Ae, { size: 12 })
@@ -247,21 +247,21 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
247
247
  }),
248
248
  /* @__PURE__ */ Y("textarea", {
249
249
  "aria-label": "Round internal notes",
250
- value: j,
251
- onChange: (e) => N(e.target.value),
250
+ value: N,
251
+ onChange: (e) => F(e.target.value),
252
252
  placeholder: "Remarks for later evaluation — not visible to the candidate.",
253
253
  rows: 2,
254
254
  disabled: U,
255
255
  className: "w-full px-3 py-2 bg-bg-surface border border-border-default rounded-lg text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-primary/30 disabled:opacity-50 resize-none"
256
256
  }),
257
- j.trim() !== (a.notes ?? "") && /* @__PURE__ */ Y(t, {
257
+ N.trim() !== (a.notes ?? "") && /* @__PURE__ */ Y(t, {
258
258
  variant: "outline",
259
259
  size: "sm",
260
260
  onClick: Pe,
261
261
  disabled: U,
262
262
  children: "Save notes"
263
263
  }),
264
- P && /* @__PURE__ */ Y("p", {
264
+ be && /* @__PURE__ */ Y("p", {
265
265
  className: "text-xs text-status-success-text",
266
266
  children: "Saved."
267
267
  })
@@ -294,14 +294,14 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
294
294
  })
295
295
  }), /* @__PURE__ */ X(r, {
296
296
  className: "space-y-3",
297
- children: [k && /* @__PURE__ */ X("div", {
297
+ children: [j && /* @__PURE__ */ X("div", {
298
298
  className: "p-2.5 rounded-lg bg-status-error-bg-subtle border border-border-subtle text-sm text-status-error-text flex items-center gap-2",
299
- children: [/* @__PURE__ */ Y(be, { size: 14 }), k]
299
+ children: [/* @__PURE__ */ Y(A, { size: 14 }), j]
300
300
  }), !G && !K ? /* @__PURE__ */ X(t, {
301
301
  size: "sm",
302
302
  onClick: je,
303
- disabled: R,
304
- children: [R ? /* @__PURE__ */ Y(W, {
303
+ disabled: xe,
304
+ children: [xe ? /* @__PURE__ */ Y(W, {
305
305
  size: 14,
306
306
  className: "animate-spin mr-1"
307
307
  }) : /* @__PURE__ */ Y(Ee, { size: 14 }), "Randomize & Send Assignment"]
@@ -326,31 +326,31 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
326
326
  }), we && /* @__PURE__ */ X("div", {
327
327
  className: "space-y-3",
328
328
  children: [
329
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
329
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
330
330
  htmlFor: `assignment-repo-${a.id}`,
331
331
  children: "GitHub Repo URL"
332
- }), /* @__PURE__ */ Y(ie, {
332
+ }), /* @__PURE__ */ Y(re, {
333
333
  id: `assignment-repo-${a.id}`,
334
334
  value: C,
335
335
  onChange: (e) => ve(e.target.value),
336
336
  placeholder: "https://github.com/…"
337
337
  })] }),
338
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
338
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
339
339
  htmlFor: `assignment-video-${a.id}`,
340
340
  children: "Jam Video URL"
341
- }), /* @__PURE__ */ Y(ie, {
341
+ }), /* @__PURE__ */ Y(re, {
342
342
  id: `assignment-video-${a.id}`,
343
- value: w,
344
- onChange: (e) => ye(e.target.value),
343
+ value: E,
344
+ onChange: (e) => D(e.target.value),
345
345
  placeholder: "https://jam.dev/…"
346
346
  })] }),
347
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
347
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
348
348
  htmlFor: `assignment-notes-${a.id}`,
349
349
  children: "Notes"
350
- }), /* @__PURE__ */ Y(ae, {
350
+ }), /* @__PURE__ */ Y(ie, {
351
351
  id: `assignment-notes-${a.id}`,
352
- value: D,
353
- onChange: (e) => xe(e.target.value),
352
+ value: O,
353
+ onChange: (e) => ye(e.target.value),
354
354
  placeholder: "Add submission notes…",
355
355
  rows: 3
356
356
  })] }),
@@ -359,7 +359,7 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
359
359
  children: /* @__PURE__ */ X(t, {
360
360
  size: "sm",
361
361
  onClick: Me,
362
- disabled: V || !C.trim() && !w.trim() && !D.trim(),
362
+ disabled: V || !C.trim() && !E.trim() && !O.trim(),
363
363
  children: [V ? /* @__PURE__ */ Y(W, {
364
364
  size: 14,
365
365
  className: "animate-spin mr-1"
@@ -411,7 +411,7 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
411
411
  variant: "ghost",
412
412
  size: "sm",
413
413
  onClick: () => Ie(n),
414
- children: /* @__PURE__ */ Y(L, { size: 14 })
414
+ children: /* @__PURE__ */ Y(R, { size: 14 })
415
415
  })]
416
416
  }), n.internalNotes && /* @__PURE__ */ Y("p", {
417
417
  className: "mt-2 text-sm text-text-secondary whitespace-pre-wrap",
@@ -422,64 +422,64 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
422
422
  ce && /* @__PURE__ */ X("div", {
423
423
  className: "p-3 rounded-lg border border-border-default bg-bg-surface space-y-3",
424
424
  children: [
425
- !g && /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
425
+ !g && /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
426
426
  htmlFor: `feedback-interviewer-${a.id}`,
427
427
  children: "Interviewer"
428
- }), /* @__PURE__ */ X(l, {
428
+ }), /* @__PURE__ */ X(u, {
429
429
  value: _,
430
430
  onValueChange: y,
431
- children: [/* @__PURE__ */ Y(f, {
431
+ children: [/* @__PURE__ */ Y(p, {
432
432
  id: `feedback-interviewer-${a.id}`,
433
- children: /* @__PURE__ */ Y(p, { placeholder: "Select interviewer" })
434
- }), /* @__PURE__ */ Y(u, { children: s ? /* @__PURE__ */ Y(d, {
433
+ children: /* @__PURE__ */ Y(m, { placeholder: "Select interviewer" })
434
+ }), /* @__PURE__ */ Y(d, { children: s ? /* @__PURE__ */ Y(f, {
435
435
  value: "loading",
436
436
  disabled: !0,
437
437
  children: "Loading…"
438
- }) : o.map((e) => /* @__PURE__ */ Y(d, {
438
+ }) : o.map((e) => /* @__PURE__ */ Y(f, {
439
439
  value: e.id,
440
440
  children: e.name
441
441
  }, e.id)) })]
442
442
  })] }),
443
443
  /* @__PURE__ */ X("div", {
444
444
  className: "grid grid-cols-2 gap-3",
445
- children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
445
+ children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
446
446
  htmlFor: `feedback-rating-${a.id}`,
447
447
  children: "Rating"
448
- }), /* @__PURE__ */ X(l, {
448
+ }), /* @__PURE__ */ X(u, {
449
449
  value: b,
450
450
  onValueChange: de,
451
- children: [/* @__PURE__ */ Y(f, {
451
+ children: [/* @__PURE__ */ Y(p, {
452
452
  id: `feedback-rating-${a.id}`,
453
- children: /* @__PURE__ */ Y(p, { placeholder: "1–5" })
454
- }), /* @__PURE__ */ Y(u, { children: [
453
+ children: /* @__PURE__ */ Y(m, { placeholder: "1–5" })
454
+ }), /* @__PURE__ */ Y(d, { children: [
455
455
  1,
456
456
  2,
457
457
  3,
458
458
  4,
459
459
  5
460
- ].map((e) => /* @__PURE__ */ Y(d, {
460
+ ].map((e) => /* @__PURE__ */ Y(f, {
461
461
  value: String(e),
462
462
  children: e
463
463
  }, e)) })]
464
- })] }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
464
+ })] }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
465
465
  htmlFor: `feedback-verdict-${a.id}`,
466
466
  children: "Verdict"
467
- }), /* @__PURE__ */ X(l, {
467
+ }), /* @__PURE__ */ X(u, {
468
468
  value: fe,
469
469
  onValueChange: (e) => pe(e),
470
- children: [/* @__PURE__ */ Y(f, {
470
+ children: [/* @__PURE__ */ Y(p, {
471
471
  id: `feedback-verdict-${a.id}`,
472
- children: /* @__PURE__ */ Y(p, { placeholder: "Verdict" })
473
- }), /* @__PURE__ */ Y(u, { children: Object.values(ge).map((e) => /* @__PURE__ */ Y(d, {
472
+ children: /* @__PURE__ */ Y(m, { placeholder: "Verdict" })
473
+ }), /* @__PURE__ */ Y(d, { children: Object.values(ge).map((e) => /* @__PURE__ */ Y(f, {
474
474
  value: e,
475
475
  children: $(e)
476
476
  }, e)) })]
477
477
  })] })]
478
478
  }),
479
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
479
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
480
480
  htmlFor: `feedback-notes-${a.id}`,
481
481
  children: "Internal Notes"
482
- }), /* @__PURE__ */ Y(ae, {
482
+ }), /* @__PURE__ */ Y(ie, {
483
483
  id: `feedback-notes-${a.id}`,
484
484
  value: he,
485
485
  onChange: (e) => x(e.target.value),
@@ -499,14 +499,14 @@ function Ge({ round: a, applicationId: te, interviewers: o, interviewersLoading:
499
499
  size: "sm",
500
500
  onClick: async () => {
501
501
  let e = b ? parseInt(b, 10) : void 0, t = fe || void 0, n = he.trim() || void 0;
502
- if (g) await m(g.id, {
502
+ if (g) await se(g.id, {
503
503
  rating: e,
504
504
  verdict: t,
505
505
  internalNotes: n
506
506
  });
507
507
  else {
508
508
  if (!_) return;
509
- await se(a.id, {
509
+ await oe(a.id, {
510
510
  interviewerId: _,
511
511
  rating: e,
512
512
  verdict: t,
@@ -530,67 +530,67 @@ function Ke({ applicationId: e, jobPostingId: n }) {
530
530
  let { data: r, loading: i, error: ee } = ce({ variables: { applicationId: e } }), { data: h, loading: g } = _({
531
531
  variables: { id: n ?? "" },
532
532
  skip: !n
533
- }), { data: le, loading: v } = m({ variables: { limit: 200 } }), [ue, { loading: b }] = se({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [me, { loading: he }] = oe({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [ge] = y({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [_e, { loading: ve }] = de({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [w] = fe({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [T] = pe({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), E = r?.jobApplicationInterviewRounds ?? [], ye = le?.interviewers.items ?? [], D = h?.jobPosting?.rounds ?? [], [xe, k] = O(!1), [A, j] = O(Z), [M, N] = O({
533
+ }), { data: le, loading: v } = se({ variables: { limit: 200 } }), [ue, { loading: b }] = oe({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [me, { loading: he }] = ae({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [ge] = y({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [w, { loading: T }] = de({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [_e] = fe({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [ve] = pe({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), E = r?.jobApplicationInterviewRounds ?? [], D = le?.interviewers.items ?? [], O = h?.jobPosting?.rounds ?? [], [ye, j] = k(!1), [M, N] = k(Z), [P, F] = k({
534
534
  name: "",
535
535
  roundType: S.PhoneScreen,
536
536
  status: x.Scheduled,
537
537
  scheduledAt: ""
538
- }), [P, F] = O(null), [I, L] = O([]), [R, z] = O(C.Panel), [B, V] = O(null), [H, U] = O(""), [Se, G] = O(null), Ce = D.filter((e) => !E.some((t) => t.roundConfigId === e.id)), K = () => {
539
- j(Z), N({
538
+ }), [be, I] = k(null), [L, R] = k([]), [xe, z] = k(C.Panel), [B, V] = k(null), [H, U] = k(""), [Se, G] = k(null), Ce = O.filter((e) => !E.some((t) => t.roundConfigId === e.id)), K = () => {
539
+ N(Z), F({
540
540
  name: "",
541
541
  roundType: S.PhoneScreen,
542
542
  status: x.Scheduled,
543
543
  scheduledAt: ""
544
544
  });
545
545
  }, we = (e) => {
546
- if (j(e), e === Z) {
547
- N((e) => ({
546
+ if (N(e), e === Z) {
547
+ F((e) => ({
548
548
  ...e,
549
549
  name: ""
550
550
  }));
551
551
  return;
552
552
  }
553
- let t = D.find((t) => t.id === e);
554
- t && N((e) => ({
553
+ let t = O.find((t) => t.id === e);
554
+ t && F((e) => ({
555
555
  ...e,
556
556
  name: t.name,
557
557
  roundType: t.roundType
558
558
  }));
559
559
  }, Ee = () => {
560
560
  let e = Ce[0];
561
- e ? (j(e.id), N({
561
+ e ? (N(e.id), F({
562
562
  name: e.name,
563
563
  roundType: e.roundType,
564
564
  status: x.Scheduled,
565
565
  scheduledAt: ""
566
- })) : K(), k(!0);
566
+ })) : K(), j(!0);
567
567
  }, De = async () => {
568
- if (M.name.trim()) {
568
+ if (P.name.trim()) {
569
569
  G(null);
570
570
  try {
571
571
  await ue({ variables: { input: {
572
572
  applicationId: e,
573
- roundConfigId: A === Z ? void 0 : A,
574
- name: M.name.trim(),
575
- roundType: M.roundType,
576
- status: M.status,
577
- scheduledAt: M.scheduledAt || void 0
578
- } } }), K(), k(!1);
573
+ roundConfigId: M === Z ? void 0 : M,
574
+ name: P.name.trim(),
575
+ roundType: P.roundType,
576
+ status: P.status,
577
+ scheduledAt: P.scheduledAt || void 0
578
+ } } }), K(), j(!1);
579
579
  } catch (e) {
580
580
  console.error("Failed to create interview round:", e), G("Failed to create interview round.");
581
581
  }
582
582
  }
583
583
  }, Oe = async () => {
584
- if (!(!P || I.length === 0)) {
584
+ if (!(!be || L.length === 0)) {
585
585
  G(null);
586
586
  try {
587
587
  await me({ variables: { input: {
588
- roundId: P,
589
- assignments: I.map((e) => ({
588
+ roundId: be,
589
+ assignments: L.map((e) => ({
590
590
  interviewerId: e,
591
- role: R
591
+ role: xe
592
592
  }))
593
- } } }), L([]), z(C.Panel), F(null);
593
+ } } }), R([]), z(C.Panel), I(null);
594
594
  } catch (e) {
595
595
  console.error("Failed to assign interviewers:", e), G("Failed to assign interviewers.");
596
596
  }
@@ -609,7 +609,7 @@ function Ke({ applicationId: e, jobPostingId: n }) {
609
609
  if (!(!B || !H.trim())) {
610
610
  G(null);
611
611
  try {
612
- await _e({ variables: { input: {
612
+ await w({ variables: { input: {
613
613
  roundId: B,
614
614
  message: H.trim()
615
615
  } } }), U(""), V(null);
@@ -620,7 +620,7 @@ function Ke({ applicationId: e, jobPostingId: n }) {
620
620
  }, J = async (e, t) => {
621
621
  G(null);
622
622
  try {
623
- await w({ variables: { input: {
623
+ await _e({ variables: { input: {
624
624
  roundId: e,
625
625
  ...t
626
626
  } } });
@@ -630,7 +630,7 @@ function Ke({ applicationId: e, jobPostingId: n }) {
630
630
  }, je = async (e, t) => {
631
631
  G(null);
632
632
  try {
633
- await T({ variables: {
633
+ await ve({ variables: {
634
634
  id: e,
635
635
  input: t
636
636
  } });
@@ -656,7 +656,7 @@ function Ke({ applicationId: e, jobPostingId: n }) {
656
656
  className: "p-5",
657
657
  children: [Se && /* @__PURE__ */ X("div", {
658
658
  className: "mb-4 p-3 rounded-lg bg-status-error-bg-subtle border border-border-subtle text-sm text-status-error-text flex items-center gap-2",
659
- children: [/* @__PURE__ */ Y(be, { size: 16 }), Se]
659
+ children: [/* @__PURE__ */ Y(A, { size: 16 }), Se]
660
660
  }), i ? /* @__PURE__ */ X("div", {
661
661
  className: "flex items-center gap-2 text-sm text-text-secondary py-4",
662
662
  children: [/* @__PURE__ */ Y(W, {
@@ -665,7 +665,7 @@ function Ke({ applicationId: e, jobPostingId: n }) {
665
665
  }), "Loading interview rounds…"]
666
666
  }) : ee ? /* @__PURE__ */ X("div", {
667
667
  className: "p-3 rounded-lg bg-status-error-bg-subtle text-status-error-text text-sm flex items-center gap-2",
668
- children: [/* @__PURE__ */ Y(be, { size: 16 }), "Could not load interview rounds."]
668
+ children: [/* @__PURE__ */ Y(A, { size: 16 }), "Could not load interview rounds."]
669
669
  }) : E.length === 0 ? /* @__PURE__ */ Y("p", {
670
670
  className: "text-sm text-text-secondary",
671
671
  children: "No interview rounds yet."
@@ -674,10 +674,10 @@ function Ke({ applicationId: e, jobPostingId: n }) {
674
674
  children: E.map((t) => /* @__PURE__ */ Y(Ge, {
675
675
  round: t,
676
676
  applicationId: e,
677
- interviewers: ye,
677
+ interviewers: D,
678
678
  interviewersLoading: v,
679
679
  onAssign: () => {
680
- F(t.id), L([]), z(C.Panel);
680
+ I(t.id), R([]), z(C.Panel);
681
681
  },
682
682
  onRemoveInterviewer: ke,
683
683
  onSendMessage: () => {
@@ -689,30 +689,30 @@ function Ke({ applicationId: e, jobPostingId: n }) {
689
689
  })]
690
690
  }),
691
691
  /* @__PURE__ */ Y(a, {
692
- open: xe,
692
+ open: ye,
693
693
  onOpenChange: (e) => {
694
- k(e), e || K();
694
+ j(e), e || K();
695
695
  },
696
696
  children: /* @__PURE__ */ X(te, {
697
697
  className: "sm:max-w-md",
698
698
  children: [
699
- /* @__PURE__ */ X(ne, { children: [/* @__PURE__ */ Y(re, { children: "Add Interview Round" }), /* @__PURE__ */ Y(o, { children: "Schedule a new round for this candidate." })] }),
699
+ /* @__PURE__ */ X(c, { children: [/* @__PURE__ */ Y(ne, { children: "Add Interview Round" }), /* @__PURE__ */ Y(o, { children: "Schedule a new round for this candidate." })] }),
700
700
  /* @__PURE__ */ X("div", {
701
701
  className: "space-y-4 py-2",
702
702
  children: [
703
703
  n && /* @__PURE__ */ X("div", { children: [
704
- /* @__PURE__ */ Y(c, {
704
+ /* @__PURE__ */ Y(l, {
705
705
  htmlFor: "round-config",
706
706
  children: "Posting round"
707
707
  }),
708
- /* @__PURE__ */ X(l, {
709
- value: A,
708
+ /* @__PURE__ */ X(u, {
709
+ value: M,
710
710
  onValueChange: we,
711
711
  disabled: g,
712
- children: [/* @__PURE__ */ Y(f, {
712
+ children: [/* @__PURE__ */ Y(p, {
713
713
  id: "round-config",
714
- children: /* @__PURE__ */ Y(p, { placeholder: "Select a configured round" })
715
- }), /* @__PURE__ */ X(u, { children: [Ce.map((e) => /* @__PURE__ */ X(d, {
714
+ children: /* @__PURE__ */ Y(m, { placeholder: "Select a configured round" })
715
+ }), /* @__PURE__ */ X(d, { children: [Ce.map((e) => /* @__PURE__ */ X(f, {
716
716
  value: e.id,
717
717
  children: [
718
718
  "Round ",
@@ -720,7 +720,7 @@ function Ke({ applicationId: e, jobPostingId: n }) {
720
720
  " — ",
721
721
  e.name
722
722
  ]
723
- }, e.id)), /* @__PURE__ */ Y(d, {
723
+ }, e.id)), /* @__PURE__ */ Y(f, {
724
724
  value: Z,
725
725
  children: "Custom round"
726
726
  })] })]
@@ -730,62 +730,62 @@ function Ke({ applicationId: e, jobPostingId: n }) {
730
730
  children: "Configured rounds stay linked to posting-level bulk actions."
731
731
  })
732
732
  ] }),
733
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
733
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
734
734
  htmlFor: "round-name",
735
735
  children: "Name"
736
- }), /* @__PURE__ */ Y(ie, {
736
+ }), /* @__PURE__ */ Y(re, {
737
737
  id: "round-name",
738
- value: M.name,
739
- onChange: (e) => N((t) => ({
738
+ value: P.name,
739
+ onChange: (e) => F((t) => ({
740
740
  ...t,
741
741
  name: e.target.value
742
742
  })),
743
743
  placeholder: "e.g. Technical Interview",
744
- disabled: A !== Z
744
+ disabled: M !== Z
745
745
  })] }),
746
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
746
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
747
747
  htmlFor: "round-type",
748
748
  children: "Round Type"
749
- }), /* @__PURE__ */ X(l, {
750
- value: M.roundType,
751
- onValueChange: (e) => N((t) => ({
749
+ }), /* @__PURE__ */ X(u, {
750
+ value: P.roundType,
751
+ onValueChange: (e) => F((t) => ({
752
752
  ...t,
753
753
  roundType: e
754
754
  })),
755
- disabled: A !== Z,
756
- children: [/* @__PURE__ */ Y(f, {
755
+ disabled: M !== Z,
756
+ children: [/* @__PURE__ */ Y(p, {
757
757
  id: "round-type",
758
- children: /* @__PURE__ */ Y(p, {})
759
- }), /* @__PURE__ */ Y(u, { children: Object.values(S).map((e) => /* @__PURE__ */ Y(d, {
758
+ children: /* @__PURE__ */ Y(m, {})
759
+ }), /* @__PURE__ */ Y(d, { children: Object.values(S).map((e) => /* @__PURE__ */ Y(f, {
760
760
  value: e,
761
761
  children: $(e)
762
762
  }, e)) })]
763
763
  })] }),
764
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
764
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
765
765
  htmlFor: "round-status",
766
766
  children: "Status"
767
- }), /* @__PURE__ */ X(l, {
768
- value: M.status,
769
- onValueChange: (e) => N((t) => ({
767
+ }), /* @__PURE__ */ X(u, {
768
+ value: P.status,
769
+ onValueChange: (e) => F((t) => ({
770
770
  ...t,
771
771
  status: e
772
772
  })),
773
- children: [/* @__PURE__ */ Y(f, {
773
+ children: [/* @__PURE__ */ Y(p, {
774
774
  id: "round-status",
775
- children: /* @__PURE__ */ Y(p, {})
776
- }), /* @__PURE__ */ Y(u, { children: Object.values(x).map((e) => /* @__PURE__ */ Y(d, {
775
+ children: /* @__PURE__ */ Y(m, {})
776
+ }), /* @__PURE__ */ Y(d, { children: Object.values(x).map((e) => /* @__PURE__ */ Y(f, {
777
777
  value: e,
778
778
  children: $(e)
779
779
  }, e)) })]
780
780
  })] }),
781
- /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
781
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
782
782
  htmlFor: "round-scheduled",
783
783
  children: "Scheduled At"
784
- }), /* @__PURE__ */ Y(ie, {
784
+ }), /* @__PURE__ */ Y(re, {
785
785
  id: "round-scheduled",
786
786
  type: "datetime-local",
787
- value: M.scheduledAt,
788
- onChange: (e) => N((t) => ({
787
+ value: P.scheduledAt,
788
+ onChange: (e) => F((t) => ({
789
789
  ...t,
790
790
  scheduledAt: e.target.value
791
791
  }))
@@ -795,12 +795,12 @@ function Ke({ applicationId: e, jobPostingId: n }) {
795
795
  /* @__PURE__ */ X(s, { children: [/* @__PURE__ */ Y(t, {
796
796
  variant: "outline",
797
797
  onClick: () => {
798
- k(!1), K();
798
+ j(!1), K();
799
799
  },
800
800
  children: "Cancel"
801
801
  }), /* @__PURE__ */ X(t, {
802
802
  onClick: De,
803
- disabled: b || !M.name.trim(),
803
+ disabled: b || !P.name.trim(),
804
804
  children: [b ? /* @__PURE__ */ Y(W, {
805
805
  size: 14,
806
806
  className: "animate-spin mr-1"
@@ -810,28 +810,28 @@ function Ke({ applicationId: e, jobPostingId: n }) {
810
810
  })
811
811
  }),
812
812
  /* @__PURE__ */ Y(a, {
813
- open: !!P,
814
- onOpenChange: (e) => !e && F(null),
813
+ open: !!be,
814
+ onOpenChange: (e) => !e && I(null),
815
815
  children: /* @__PURE__ */ X(te, {
816
816
  className: "sm:max-w-md",
817
817
  children: [
818
- /* @__PURE__ */ X(ne, { children: [/* @__PURE__ */ Y(re, { children: "Assign Interviewers" }), /* @__PURE__ */ Y(o, { children: "Choose interviewers and a role for this round." })] }),
818
+ /* @__PURE__ */ X(c, { children: [/* @__PURE__ */ Y(ne, { children: "Assign Interviewers" }), /* @__PURE__ */ Y(o, { children: "Choose interviewers and a role for this round." })] }),
819
819
  /* @__PURE__ */ X("div", {
820
820
  className: "space-y-4 py-2",
821
- children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, {
821
+ children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, {
822
822
  htmlFor: "assign-role",
823
823
  children: "Role"
824
- }), /* @__PURE__ */ X(l, {
825
- value: R,
824
+ }), /* @__PURE__ */ X(u, {
825
+ value: xe,
826
826
  onValueChange: (e) => z(e),
827
- children: [/* @__PURE__ */ Y(f, {
827
+ children: [/* @__PURE__ */ Y(p, {
828
828
  id: "assign-role",
829
- children: /* @__PURE__ */ Y(p, {})
830
- }), /* @__PURE__ */ Y(u, { children: Object.values(C).map((e) => /* @__PURE__ */ Y(d, {
829
+ children: /* @__PURE__ */ Y(m, {})
830
+ }), /* @__PURE__ */ Y(d, { children: Object.values(C).map((e) => /* @__PURE__ */ Y(f, {
831
831
  value: e,
832
832
  children: $(e)
833
833
  }, e)) })]
834
- })] }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(c, { children: "Interviewers" }), /* @__PURE__ */ Y("div", {
834
+ })] }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(l, { children: "Interviewers" }), /* @__PURE__ */ Y("div", {
835
835
  className: "mt-1.5 max-h-60 overflow-y-auto border border-border-default rounded-lg p-2 space-y-1",
836
836
  children: v ? /* @__PURE__ */ X("div", {
837
837
  className: "flex items-center gap-2 text-sm text-text-secondary py-2",
@@ -839,17 +839,17 @@ function Ke({ applicationId: e, jobPostingId: n }) {
839
839
  size: 14,
840
840
  className: "animate-spin"
841
841
  }), "Loading…"]
842
- }) : ye.length === 0 ? /* @__PURE__ */ Y("p", {
842
+ }) : D.length === 0 ? /* @__PURE__ */ Y("p", {
843
843
  className: "text-sm text-text-secondary py-2",
844
844
  children: "No interviewers found."
845
- }) : ye.map((e) => /* @__PURE__ */ X("label", {
845
+ }) : D.map((e) => /* @__PURE__ */ X("label", {
846
846
  className: "flex items-start gap-2 p-2 rounded-md hover:bg-bg-muted cursor-pointer",
847
847
  children: [/* @__PURE__ */ Y("input", {
848
848
  type: "checkbox",
849
849
  className: "mt-1",
850
- checked: I.includes(e.id),
850
+ checked: L.includes(e.id),
851
851
  onChange: (t) => {
852
- L((n) => t.target.checked ? [...n, e.id] : n.filter((t) => t !== e.id));
852
+ R((n) => t.target.checked ? [...n, e.id] : n.filter((t) => t !== e.id));
853
853
  }
854
854
  }), /* @__PURE__ */ X("div", {
855
855
  className: "text-sm",
@@ -866,11 +866,11 @@ function Ke({ applicationId: e, jobPostingId: n }) {
866
866
  }),
867
867
  /* @__PURE__ */ X(s, { children: [/* @__PURE__ */ Y(t, {
868
868
  variant: "outline",
869
- onClick: () => F(null),
869
+ onClick: () => I(null),
870
870
  children: "Cancel"
871
871
  }), /* @__PURE__ */ X(t, {
872
872
  onClick: Oe,
873
- disabled: he || I.length === 0,
873
+ disabled: he || L.length === 0,
874
874
  children: [he ? /* @__PURE__ */ Y(W, {
875
875
  size: 14,
876
876
  className: "animate-spin mr-1"
@@ -885,10 +885,10 @@ function Ke({ applicationId: e, jobPostingId: n }) {
885
885
  children: /* @__PURE__ */ X(te, {
886
886
  className: "sm:max-w-md",
887
887
  children: [
888
- /* @__PURE__ */ X(ne, { children: [/* @__PURE__ */ Y(re, { children: "Send Candidate Message" }), /* @__PURE__ */ Y(o, { children: "This message will be emailed to the candidate for this round." })] }),
888
+ /* @__PURE__ */ X(c, { children: [/* @__PURE__ */ Y(ne, { children: "Send Candidate Message" }), /* @__PURE__ */ Y(o, { children: "This message will be emailed to the candidate for this round." })] }),
889
889
  /* @__PURE__ */ Y("div", {
890
890
  className: "py-2",
891
- children: /* @__PURE__ */ Y(ae, {
891
+ children: /* @__PURE__ */ Y(ie, {
892
892
  value: H,
893
893
  onChange: (e) => U(e.target.value),
894
894
  placeholder: "Type the message to send…",
@@ -901,8 +901,8 @@ function Ke({ applicationId: e, jobPostingId: n }) {
901
901
  children: "Cancel"
902
902
  }), /* @__PURE__ */ X(t, {
903
903
  onClick: Ae,
904
- disabled: ve || !H.trim(),
905
- children: [ve ? /* @__PURE__ */ Y(W, {
904
+ disabled: T || !H.trim(),
905
+ children: [T ? /* @__PURE__ */ Y(W, {
906
906
  size: 14,
907
907
  className: "animate-spin mr-1"
908
908
  }) : null, "Send Message"]
@@ -914,13 +914,13 @@ function Ke({ applicationId: e, jobPostingId: n }) {
914
914
  });
915
915
  }
916
916
  function qe() {
917
- let { id: e } = Ne(), t = Me(), n = je().search, [r, i] = O(!1), [ee, s] = O(!1), [ie, c] = O(!1), [l, u] = O(!1), [d, f] = O(""), [p, ae] = O(!1), [oe, se] = O(null), { data: m, loading: ce, error: _ } = h({
917
+ let { id: e } = Ne(), t = Me(), n = je().search, [r, i] = k(!1), [ee, s] = k(!1), [re, l] = k(!1), [u, d] = k(!1), [f, p] = k(""), [m, ie] = k(!1), [ae, oe] = k(null), { data: se, loading: ce, error: _ } = h({
918
918
  variables: { id: e },
919
919
  skip: !e
920
- }), v = m?.jobApplication?.productId ?? null;
921
- D(() => {
920
+ }), v = se?.jobApplication?.productId ?? null;
921
+ O(() => {
922
922
  if (!v) {
923
- se(null);
923
+ oe(null);
924
924
  return;
925
925
  }
926
926
  let e = !1;
@@ -931,17 +931,17 @@ function qe() {
931
931
  }).then((t) => {
932
932
  if (e) return;
933
933
  let n = t.data?.platformProduct?.name;
934
- n && se(n);
934
+ n && oe(n);
935
935
  }).catch(() => {}), () => {
936
936
  e = !0;
937
937
  };
938
938
  }, [v]);
939
- let [ue, { loading: y }] = he({ refetchQueries: ["GetJobApplication", "GetJobApplications"] }), [de, { loading: fe }] = le({ fetchPolicy: "no-cache" }), [pe, me] = O(!1), [x, S] = O(null), [ge, C] = O(!1), [_e, { loading: T }] = g({ fetchPolicy: "no-cache" }), [E, { loading: L }] = b(), H = m?.jobApplication, Ce = async () => {
940
- if (!(!d.trim() || !e)) try {
941
- (await E({ variables: {
939
+ let [ue, { loading: y }] = he({ refetchQueries: ["GetJobApplication", "GetJobApplications"] }), [de, { loading: fe }] = le({ fetchPolicy: "no-cache" }), [pe, me] = k(!1), [x, S] = k(null), [ge, C] = k(!1), [w, { loading: T }] = g({ fetchPolicy: "no-cache" }), [_e, { loading: R }] = b(), H = se?.jobApplication, Ce = async () => {
940
+ if (!(!f.trim() || !e)) try {
941
+ (await _e({ variables: {
942
942
  id: e,
943
- message: d.trim()
944
- } })).data?.replyToJobApplication.success && (ae(!0), f(""), setTimeout(() => ae(!1), 3e3));
943
+ message: f.trim()
944
+ } })).data?.replyToJobApplication.success && (ie(!0), p(""), setTimeout(() => ie(!1), 3e3));
945
945
  } catch (e) {
946
946
  console.error("Failed to send reply:", e);
947
947
  }
@@ -959,26 +959,26 @@ function qe() {
959
959
  }
960
960
  }, De = async () => {
961
961
  if (e) {
962
- u(!1);
962
+ d(!1);
963
963
  try {
964
964
  let t = (await de({ variables: { id: e } })).data?.jobApplicationResumeUrl;
965
- t ? window.open(t, "_blank", "noopener,noreferrer") : u(!0);
965
+ t ? window.open(t, "_blank", "noopener,noreferrer") : d(!0);
966
966
  } catch (e) {
967
- console.error("Failed to get resume URL:", e), u(!0);
967
+ console.error("Failed to get resume URL:", e), d(!0);
968
968
  }
969
969
  }
970
970
  }, ke = async () => {
971
971
  if (e) {
972
972
  C(!1), S(null), me(!0);
973
973
  try {
974
- let t = (await _e({ variables: { id: e } })).data?.jobApplicationResumePreviewUrl;
974
+ let t = (await w({ variables: { id: e } })).data?.jobApplicationResumePreviewUrl;
975
975
  t ? S(t) : C(!0);
976
976
  } catch (e) {
977
977
  console.error("Failed to get resume preview URL:", e), C(!0);
978
978
  }
979
979
  }
980
980
  }, Ae = async () => {
981
- H?.email && (w("light"), await ve(H.email), c(!0), setTimeout(() => c(!1), 2e3));
981
+ H?.email && (E("light"), await ve(H.email), l(!0), setTimeout(() => l(!1), 2e3));
982
982
  };
983
983
  if (ce) return /* @__PURE__ */ Y("div", {
984
984
  className: "min-h-full flex items-center justify-center py-20",
@@ -1003,7 +1003,7 @@ function qe() {
1003
1003
  type: "button",
1004
1004
  onClick: () => t(`/support/applications${n}`),
1005
1005
  className: "inline-flex items-center gap-2 px-5 py-2.5 bg-[var(--color-bg-accent)] text-on-accent rounded-lg text-sm font-medium hover:opacity-90 transition-all",
1006
- children: [/* @__PURE__ */ Y(k, { size: 16 }), "Back to Applications"]
1006
+ children: [/* @__PURE__ */ Y(j, { size: 16 }), "Back to Applications"]
1007
1007
  })
1008
1008
  })
1009
1009
  });
@@ -1017,22 +1017,22 @@ function qe() {
1017
1017
  type: "button",
1018
1018
  onClick: () => t(`/support/applications${n}`),
1019
1019
  className: "inline-flex items-center gap-2 text-[var(--color-text-secondary)] hover:text-[var(--color-text-primary)] transition-colors",
1020
- children: [/* @__PURE__ */ Y(k, { size: 18 }), /* @__PURE__ */ Y("span", {
1020
+ children: [/* @__PURE__ */ Y(j, { size: 18 }), /* @__PURE__ */ Y("span", {
1021
1021
  className: "text-sm font-medium",
1022
1022
  children: "Back to Applications"
1023
1023
  })]
1024
1024
  }), /* @__PURE__ */ X("div", {
1025
1025
  className: "flex items-center gap-2 text-xs text-[var(--color-text-secondary)]",
1026
- children: [/* @__PURE__ */ Y(P, { size: 12 }), Ve(H.createdAt)]
1026
+ children: [/* @__PURE__ */ Y(be, { size: 12 }), Ve(H.createdAt)]
1027
1027
  })]
1028
1028
  }),
1029
1029
  r && /* @__PURE__ */ X("div", {
1030
1030
  className: "mb-5 p-3.5 bg-status-success-bg-subtle border border-border-subtle rounded-xl flex items-center gap-2.5 text-status-success-text text-sm font-medium animate-in slide-in-from-top-2 duration-200",
1031
- children: [/* @__PURE__ */ Y(N, { size: 18 }), "Status updated successfully"]
1031
+ children: [/* @__PURE__ */ Y(F, { size: 18 }), "Status updated successfully"]
1032
1032
  }),
1033
1033
  ee && /* @__PURE__ */ X("div", {
1034
1034
  className: "mb-5 p-3.5 bg-status-error-bg-subtle border border-border-subtle rounded-xl flex items-center gap-2.5 text-status-error-text text-sm font-medium animate-in slide-in-from-top-2 duration-200",
1035
- children: [/* @__PURE__ */ Y(be, { size: 18 }), "Couldn't update the status. Please try again."]
1035
+ children: [/* @__PURE__ */ Y(A, { size: 18 }), "Couldn't update the status. Please try again."]
1036
1036
  }),
1037
1037
  /* @__PURE__ */ Y(ze, {
1038
1038
  className: "mb-6",
@@ -1165,10 +1165,10 @@ function qe() {
1165
1165
  onClick: Ae,
1166
1166
  className: "flex-shrink-0 p-0.5 rounded hover:bg-[var(--color-bg-muted)] transition-colors",
1167
1167
  title: "Copy email",
1168
- children: ie ? /* @__PURE__ */ Y(N, {
1168
+ children: re ? /* @__PURE__ */ Y(F, {
1169
1169
  size: 12,
1170
1170
  className: "text-status-success-text"
1171
- }) : /* @__PURE__ */ Y(F, {
1171
+ }) : /* @__PURE__ */ Y(I, {
1172
1172
  size: 12,
1173
1173
  className: "text-[var(--color-text-secondary)]"
1174
1174
  })
@@ -1197,7 +1197,7 @@ function qe() {
1197
1197
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1198
1198
  children: [/* @__PURE__ */ Y("div", {
1199
1199
  className: "size-9 rounded-lg bg-accent-blue-subtle flex items-center justify-center",
1200
- children: /* @__PURE__ */ Y(A, {
1200
+ children: /* @__PURE__ */ Y(M, {
1201
1201
  size: 16,
1202
1202
  className: "text-accent-blue"
1203
1203
  })
@@ -1213,7 +1213,7 @@ function qe() {
1213
1213
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1214
1214
  children: [/* @__PURE__ */ Y("div", {
1215
1215
  className: "size-9 rounded-lg bg-accent-purple-subtle flex items-center justify-center",
1216
- children: /* @__PURE__ */ Y(j, {
1216
+ children: /* @__PURE__ */ Y(N, {
1217
1217
  size: 16,
1218
1218
  className: "text-accent-purple"
1219
1219
  })
@@ -1275,7 +1275,7 @@ function qe() {
1275
1275
  })]
1276
1276
  })]
1277
1277
  }),
1278
- H.productId && oe && /* @__PURE__ */ X("div", {
1278
+ H.productId && ae && /* @__PURE__ */ X("div", {
1279
1279
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1280
1280
  children: [/* @__PURE__ */ Y("div", {
1281
1281
  className: "size-9 rounded-lg bg-accent-purple-subtle flex items-center justify-center",
@@ -1288,7 +1288,7 @@ function qe() {
1288
1288
  children: "Product"
1289
1289
  }), /* @__PURE__ */ Y("p", {
1290
1290
  className: "text-sm font-semibold text-[var(--color-text-primary)]",
1291
- children: oe
1291
+ children: ae
1292
1292
  })] })]
1293
1293
  }),
1294
1294
  /* @__PURE__ */ X("div", {
@@ -1313,7 +1313,7 @@ function qe() {
1313
1313
  }),
1314
1314
  e && /* @__PURE__ */ Y(Ke, {
1315
1315
  applicationId: e,
1316
- jobPostingId: m.jobApplication.jobPostingId
1316
+ jobPostingId: se.jobApplication.jobPostingId
1317
1317
  }),
1318
1318
  H.coverLetter && /* @__PURE__ */ X("div", {
1319
1319
  className: "bg-[var(--color-bg-surface)] border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
@@ -1337,7 +1337,7 @@ function qe() {
1337
1337
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1338
1338
  children: /* @__PURE__ */ X("h2", {
1339
1339
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-2",
1340
- children: [/* @__PURE__ */ Y(R, { size: 14 }), "Additional Data"]
1340
+ children: [/* @__PURE__ */ Y(xe, { size: 14 }), "Additional Data"]
1341
1341
  })
1342
1342
  }), /* @__PURE__ */ Y("div", {
1343
1343
  className: "p-5",
@@ -1398,7 +1398,7 @@ function qe() {
1398
1398
  children: [fe ? /* @__PURE__ */ Y(W, {
1399
1399
  size: 15,
1400
1400
  className: "animate-spin"
1401
- }) : /* @__PURE__ */ Y(I, { size: 15 }), "Download Resume"]
1401
+ }) : /* @__PURE__ */ Y(L, { size: 15 }), "Download Resume"]
1402
1402
  }),
1403
1403
  /* @__PURE__ */ X("button", {
1404
1404
  type: "button",
@@ -1410,7 +1410,7 @@ function qe() {
1410
1410
  className: "animate-spin"
1411
1411
  }) : /* @__PURE__ */ Y(z, { size: 15 }), "Preview Resume"]
1412
1412
  }),
1413
- l && /* @__PURE__ */ Y("p", {
1413
+ u && /* @__PURE__ */ Y("p", {
1414
1414
  className: "mt-2 text-xs text-status-error-text",
1415
1415
  children: "Could not generate a download link. Please try again."
1416
1416
  })
@@ -1426,7 +1426,7 @@ function qe() {
1426
1426
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1427
1427
  children: /* @__PURE__ */ X("h2", {
1428
1428
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-2",
1429
- children: [/* @__PURE__ */ Y(M, { size: 14 }), "Timeline"]
1429
+ children: [/* @__PURE__ */ Y(P, { size: 14 }), "Timeline"]
1430
1430
  })
1431
1431
  }), /* @__PURE__ */ X("div", {
1432
1432
  className: "p-5 space-y-4",
@@ -1463,22 +1463,22 @@ function qe() {
1463
1463
  }), /* @__PURE__ */ X("div", {
1464
1464
  className: "p-5",
1465
1465
  children: [
1466
- p && /* @__PURE__ */ X("div", {
1466
+ m && /* @__PURE__ */ X("div", {
1467
1467
  className: "mb-3 p-2.5 rounded-lg bg-status-success-bg-subtle border border-border-subtle text-sm text-status-success-text flex items-center gap-2",
1468
- children: [/* @__PURE__ */ Y(N, { size: 14 }), "Reply sent to the applicant!"]
1468
+ children: [/* @__PURE__ */ Y(F, { size: 14 }), "Reply sent to the applicant!"]
1469
1469
  }),
1470
- /* @__PURE__ */ Y(ye, {
1470
+ /* @__PURE__ */ Y(D, {
1471
1471
  id: "reply-message",
1472
- value: d,
1473
- onChange: f,
1472
+ value: f,
1473
+ onChange: p,
1474
1474
  placeholder: "Type your reply… This will be sent as a branded email to the applicant."
1475
1475
  }),
1476
1476
  /* @__PURE__ */ X("button", {
1477
1477
  type: "button",
1478
1478
  onClick: Ce,
1479
- disabled: L || !d.trim(),
1479
+ disabled: R || !f.trim(),
1480
1480
  className: "mt-2 w-full inline-flex items-center justify-center gap-2 px-4 py-2.5 bg-[var(--color-bg-accent)] text-on-accent rounded-lg text-sm font-medium hover:opacity-90 transition-all disabled:opacity-50",
1481
- children: [L ? /* @__PURE__ */ Y(W, {
1481
+ children: [R ? /* @__PURE__ */ Y(W, {
1482
1482
  size: 15,
1483
1483
  className: "animate-spin"
1484
1484
  }) : /* @__PURE__ */ Y(Ee, { size: 15 }), "Send Reply"]
@@ -1548,7 +1548,7 @@ function qe() {
1548
1548
  onClick: () => Te("ARCHIVED"),
1549
1549
  disabled: y,
1550
1550
  className: "w-full inline-flex items-center justify-center gap-2 px-4 py-2.5 bg-[var(--color-bg-surface)] border border-[var(--color-border-default)] text-[var(--color-text-secondary)] rounded-lg text-sm font-medium hover:bg-[var(--color-bg-muted)] transition-all disabled:opacity-50",
1551
- children: [/* @__PURE__ */ Y(xe, { size: 15 }), "Archive"]
1551
+ children: [/* @__PURE__ */ Y(ye, { size: 15 }), "Archive"]
1552
1552
  })]
1553
1553
  })]
1554
1554
  })]
@@ -1561,7 +1561,7 @@ function qe() {
1561
1561
  onOpenChange: me,
1562
1562
  children: /* @__PURE__ */ X(te, {
1563
1563
  className: "sm:max-w-4xl",
1564
- children: [/* @__PURE__ */ X(ne, { children: [/* @__PURE__ */ Y(re, { children: "Resume Preview" }), /* @__PURE__ */ Y(o, { children: H.resumeFileName ?? "Candidate resume" })] }), /* @__PURE__ */ Y("div", {
1564
+ children: [/* @__PURE__ */ X(c, { children: [/* @__PURE__ */ Y(ne, { children: "Resume Preview" }), /* @__PURE__ */ Y(o, { children: H.resumeFileName ?? "Candidate resume" })] }), /* @__PURE__ */ Y("div", {
1565
1565
  className: "h-[70vh] w-full rounded-lg border border-border-seam bg-bg-sunken/30 overflow-hidden",
1566
1566
  children: T ? /* @__PURE__ */ X("div", {
1567
1567
  className: "h-full flex flex-col items-center justify-center gap-3",
@@ -1574,7 +1574,7 @@ function qe() {
1574
1574
  })]
1575
1575
  }) : ge || !x ? /* @__PURE__ */ X("div", {
1576
1576
  className: "h-full flex flex-col items-center justify-center gap-3",
1577
- children: [/* @__PURE__ */ Y(be, {
1577
+ children: [/* @__PURE__ */ Y(A, {
1578
1578
  size: 28,
1579
1579
  className: "text-status-error-text"
1580
1580
  }), /* @__PURE__ */ Y("p", {