@burdenoff/microfe-support 2026.817.2 → 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,92 +1,60 @@
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 o, DialogDescription as s, DialogFooter as c, DialogHeader as l, DialogTitle as u, Input as d, Label as f, Select as p, SelectContent as m, SelectItem as h, SelectTrigger as g, SelectValue as _, Textarea as v } from "../components/ui.js";
2
- import { useAssignInterviewersToRoundMutation as y, useCreateInterviewRoundMutation as te, useGetInterviewersQuery as ne, useGetJobApplicationInterviewRoundsQuery as re, useGetJobApplicationQuery as b, useGetJobApplicationResumeUrlLazyQuery as x, useRandomizeAndSendAssignmentMutation as S, useRecordAssignmentSubmissionMutation as ie, useRemoveInterviewerFromRoundMutation as C, useReplyToJobApplicationMutation as w, useSendRoundMessageToCandidateMutation as T, useSubmitInterviewFeedbackMutation as ae, useUpdateInterviewFeedbackMutation as E, useUpdateJobApplicationStatusMutation as oe } from "../../generated/global-operations.js";
3
- import { InterviewRoundStatus as D, InterviewRoundType as O, InterviewVerdict as k, InterviewerRole as A } from "../../generated/global-types.js";
4
- import { nativeCopyText as j, nativeImpact as M } from "../../utils/nativeBridge.js";
5
- import { useEffect as se, useState as N } from "react";
6
- import { AlertCircle as ce, Archive as P, ArrowLeft as F, Briefcase as I, Building2 as L, Calendar as R, CheckCircle as z, Clock as B, Copy as V, Download as H, Edit3 as U, ExternalLink as le, Eye as W, FileText as G, Globe as K, Inbox as q, Link2 as J, Linkedin as ue, Loader2 as Y, Mail as X, MessageSquare as de, Package as fe, Phone as pe, Plus as me, Send as he, Star as ge, User as _e, UserPlus as ve, UserX as ye, Users as be, XCircle as xe } from "lucide-react";
7
- import { useLocation as Se, useNavigate as Ce, useParams as we } from "react-router";
8
- import { graphqlFetch as Te } from "@burdenoff/fe-libs/shared/graphql/fetch";
9
- import { Fragment as Ee, jsx as Z, jsxs as Q } from "react/jsx-runtime";
10
- import { EmphasisPanel as De, IllustratedEmptyState as Oe, NextSteps as ke, PagePurpose as Ae } from "@burdenoff/fe-libs/ui";
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 o, DialogDescription as s, DialogFooter as c, DialogHeader as l, DialogTitle as te, Input as ne, Label as u, Select as d, SelectContent as f, SelectItem as p, SelectTrigger as m, SelectValue as h, Textarea as re } from "../components/ui.js";
2
+ import { useAssignInterviewersToRoundMutation as ie, useCreateInterviewRoundMutation as ae, useGetInterviewersQuery as oe, useGetJobApplicationInterviewRoundsQuery as se, useGetJobApplicationQuery as g, useGetJobApplicationResumePreviewUrlLazyQuery as _, useGetJobApplicationResumeUrlLazyQuery as ce, useGetJobPostingQuery as v, useRandomizeAndSendAssignmentMutation as y, useRecordAssignmentSubmissionMutation as le, useRemoveInterviewerFromRoundMutation as b, useReplyToJobApplicationMutation as x, useSendRoundMessageToCandidateMutation as ue, useSubmitInterviewFeedbackMutation as de, useUpdateInterviewFeedbackMutation as fe, useUpdateJobApplicationStatusMutation as pe } from "../../generated/global-operations.js";
3
+ import { InterviewRoundStatus as S, InterviewRoundType as C, InterviewVerdict as w, InterviewerRole as T } from "../../generated/global-types.js";
4
+ import { nativeCopyText as me, nativeImpact as E } from "../../utils/nativeBridge.js";
5
+ import { roundStatusConfig as D } from "../constants/pipeline.js";
6
+ import { useEffect as he, useState as O } from "react";
7
+ import { AlertCircle as ge, Archive as k, ArrowLeft as A, Briefcase as j, Building2 as M, Calendar as _e, CheckCircle as N, Clock as P, Copy as ve, Download as F, Edit3 as I, ExternalLink as ye, Eye as L, FileText as R, Globe as z, Inbox as B, Link2 as V, Linkedin as H, Loader2 as U, Mail as W, MessageSquare as G, Package as be, Phone as xe, Plus as Se, Send as K, Star as q, User as J, UserPlus as Ce, UserX as we, Users as Te, XCircle as Ee } from "lucide-react";
8
+ import { useLocation as De, useNavigate as Oe, useParams as ke } from "react-router";
9
+ import { graphqlFetch as Ae } from "@burdenoff/fe-libs/shared/graphql/fetch";
10
+ import { Fragment as je, jsx as Y, jsxs as X } from "react/jsx-runtime";
11
+ import { EmphasisPanel as Me, IllustratedEmptyState as Ne, NextSteps as Pe, PagePurpose as Fe } from "@burdenoff/fe-libs/ui";
11
12
  //#region src/support/pages/JobApplicationDetailPage.tsx
12
- var je = {
13
+ var Z = "__custom__", Ie = {
13
14
  NEW: {
14
15
  label: "New",
15
16
  color: "text-accent-blue",
16
- icon: q,
17
+ icon: B,
17
18
  bg: "bg-status-info-bg-subtle border-border-subtle"
18
19
  },
19
20
  SCREENING: {
20
21
  label: "Screening",
21
22
  color: "text-status-warning-text",
22
- icon: W,
23
+ icon: L,
23
24
  bg: "bg-status-warning-bg-subtle border-border-subtle"
24
25
  },
25
26
  SHORTLISTED: {
26
27
  label: "Shortlisted",
27
28
  color: "text-accent-purple",
28
- icon: ge,
29
+ icon: q,
29
30
  bg: "bg-accent-purple-subtle border-border-subtle"
30
31
  },
31
32
  INTERVIEW: {
32
33
  label: "Interview",
33
34
  color: "text-accent-blue",
34
- icon: be,
35
+ icon: Te,
35
36
  bg: "bg-accent-blue-subtle border-border-subtle"
36
37
  },
37
38
  HIRED: {
38
39
  label: "Hired",
39
40
  color: "text-status-success-text",
40
- icon: z,
41
+ icon: N,
41
42
  bg: "bg-status-success-bg-subtle border-border-subtle"
42
43
  },
43
44
  REJECTED: {
44
45
  label: "Rejected",
45
46
  color: "text-status-error-text",
46
- icon: xe,
47
+ icon: Ee,
47
48
  bg: "bg-status-error-bg-subtle border-border-subtle"
48
49
  },
49
50
  ARCHIVED: {
50
51
  label: "Archived",
51
52
  color: "text-text-secondary",
52
- icon: P,
53
+ icon: k,
53
54
  bg: "bg-bg-canvas border-border-subtle"
54
55
  }
55
- }, Me = {
56
- SCHEDULED: {
57
- label: "Scheduled",
58
- className: "bg-status-info-bg-subtle text-status-info-text"
59
- },
60
- AWAITING_SUBMISSION: {
61
- label: "Awaiting Submission",
62
- className: "bg-status-warning-bg-subtle text-status-warning-text"
63
- },
64
- SUBMITTED: {
65
- label: "Submitted",
66
- className: "bg-accent-blue-subtle text-accent-blue"
67
- },
68
- COMPLETED: {
69
- label: "Completed",
70
- className: "bg-status-success-bg-subtle text-status-success-text"
71
- },
72
- PASSED: {
73
- label: "Passed",
74
- className: "bg-status-success-bg-subtle text-status-success-text"
75
- },
76
- FAILED: {
77
- label: "Failed",
78
- className: "bg-status-error-bg-subtle text-status-error-text"
79
- },
80
- NO_SHOW: {
81
- label: "No Show",
82
- className: "bg-status-error-bg-subtle text-status-error-text"
83
- },
84
- CANCELLED: {
85
- label: "Cancelled",
86
- className: "bg-bg-sunken text-text-secondary"
87
- }
88
56
  };
89
- function Ne(e) {
57
+ function Q(e) {
90
58
  return new Date(e).toLocaleDateString("en-US", {
91
59
  weekday: "short",
92
60
  month: "short",
@@ -96,21 +64,21 @@ function Ne(e) {
96
64
  minute: "2-digit"
97
65
  });
98
66
  }
99
- function Pe(e) {
67
+ function Le(e) {
100
68
  let t = Date.now() - new Date(e).getTime(), n = Math.floor(t / 6e4);
101
69
  if (n < 60) return `${n}m ago`;
102
70
  let r = Math.floor(n / 60);
103
71
  if (r < 24) return `${r}h ago`;
104
72
  let i = Math.floor(r / 24);
105
- return i < 30 ? `${i}d ago` : Ne(e);
73
+ return i < 30 ? `${i}d ago` : Q(e);
106
74
  }
107
- function Fe(e) {
75
+ function Re(e) {
108
76
  return !e || e <= 0 ? null : e < 1024 ? `${e} B` : e < 1024 * 1024 ? `${(e / 1024).toFixed(0)} KB` : `${(e / (1024 * 1024)).toFixed(1)} MB`;
109
77
  }
110
78
  function $(e) {
111
79
  return e.replace(/_/g, " ").toLowerCase().replace(/\b\w/g, (e) => e.toUpperCase());
112
80
  }
113
- function Ie(e) {
81
+ function ze(e) {
114
82
  switch (e) {
115
83
  case "STRONG_YES":
116
84
  case "YES": return "bg-status-success-bg-subtle text-status-success-text";
@@ -120,7 +88,7 @@ function Ie(e) {
120
88
  default: return "bg-bg-sunken text-text-secondary";
121
89
  }
122
90
  }
123
- function Le(e) {
91
+ function Be(e) {
124
92
  if (!e) return null;
125
93
  try {
126
94
  let t = new URL(e);
@@ -129,206 +97,213 @@ function Le(e) {
129
97
  return null;
130
98
  }
131
99
  }
132
- function Re({ round: a, applicationId: o, interviewers: s, interviewersLoading: c, onAssign: l, onRemoveInterviewer: u, onSendMessage: y, onSubmitFeedback: te, onUpdateFeedback: ne }) {
133
- let [re, b] = N(!1), [x, C] = N(null), [w, T] = N(""), [ae, E] = N(""), [oe, D] = N(""), [A, j] = N(""), [M, se] = N(a.submittedRepoUrl ?? ""), [P, F] = N(a.submittedVideoUrl ?? ""), [I, L] = N(a.submittedNotes ?? ""), [z, B] = N(null), [V, { loading: H }] = S({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [le, { loading: W }] = ie({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), K = a.roundType === O.TakeHome || !!a.roundConfig?.isAssignmentRound, q = !!a.assignment, J = !!(a.submittedRepoUrl || a.submittedVideoUrl || a.submittedAt), ue = q || J, X = Me[a.status] ?? Me.SCHEDULED, fe = () => {
134
- C(null), T(""), E(""), D(""), j("");
135
- }, pe = async () => {
136
- B(null);
100
+ function Ve({ round: a, applicationId: o, interviewers: s, interviewersLoading: c, onAssign: l, onRemoveInterviewer: te, onSendMessage: ie, onSubmitFeedback: ae, onUpdateFeedback: oe }) {
101
+ let [se, g] = O(!1), [_, ce] = O(null), [v, b] = O(""), [x, ue] = O(""), [de, fe] = O(""), [pe, S] = O(""), [T, me] = O(a.submittedRepoUrl ?? ""), [E, he] = O(a.submittedVideoUrl ?? ""), [k, A] = O(a.submittedNotes ?? ""), [j, M] = O(null), [N, { loading: P }] = y({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [ve, { loading: F }] = le({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), ye = a.roundType === C.TakeHome || !!a.roundConfig?.isAssignmentRound, L = !!a.assignment, z = !!(a.submittedRepoUrl || a.submittedVideoUrl || a.submittedAt), B = L || z, V = a.emailLogs.find((e) => e.emailType === "ASSIGNMENT")?.sentAt, H = D[a.status] ?? D.SCHEDULED, W = () => {
102
+ ce(null), b(""), ue(""), fe(""), S("");
103
+ }, be = async () => {
104
+ M(null);
137
105
  try {
138
- await V({ variables: { input: {
106
+ await N({ variables: { input: {
139
107
  applicationId: o,
140
108
  roundId: a.id
141
109
  } } });
142
110
  } catch (e) {
143
- console.error("Failed to randomize and send assignment:", e), B("Failed to randomize and send assignment.");
111
+ console.error("Failed to randomize and send assignment:", e), M("Failed to randomize and send assignment.");
144
112
  }
145
- }, _e = async () => {
146
- B(null);
147
- let e = M.trim() || void 0, t = P.trim() || void 0, n = I.trim() || void 0;
148
- if (e && !Le(e)) {
149
- B("GitHub repo URL must start with http:// or https://.");
113
+ }, xe = async () => {
114
+ M(null);
115
+ let e = T.trim() || void 0, t = E.trim() || void 0, n = k.trim() || void 0;
116
+ if (e && !Be(e)) {
117
+ M("GitHub repo URL must start with http:// or https://.");
150
118
  return;
151
119
  }
152
- if (t && !Le(t)) {
153
- B("Jam video URL must start with http:// or https://.");
120
+ if (t && !Be(t)) {
121
+ M("Jam video URL must start with http:// or https://.");
154
122
  return;
155
123
  }
156
124
  if (!e && !t && !n) {
157
- B("Please provide at least a repo URL, video URL, or notes.");
125
+ M("Please provide at least a repo URL, video URL, or notes.");
158
126
  return;
159
127
  }
160
128
  try {
161
- await le({ variables: { input: {
129
+ await ve({ variables: { input: {
162
130
  roundId: a.id,
163
131
  repoUrl: e,
164
132
  videoUrl: t,
165
133
  notes: n
166
134
  } } });
167
135
  } catch (e) {
168
- console.error("Failed to record assignment submission:", e), B("Failed to record submission.");
136
+ console.error("Failed to record assignment submission:", e), M("Failed to record submission.");
169
137
  }
170
- }, be = () => {
171
- fe(), b(!0);
172
- }, xe = (e) => {
173
- C(e), T(e.interviewerId), E(e.rating?.toString() ?? ""), D(e.verdict ?? ""), j(e.internalNotes ?? ""), b(!0);
138
+ }, J = () => {
139
+ W(), g(!0);
140
+ }, Te = (e) => {
141
+ ce(e), b(e.interviewerId), ue(e.rating?.toString() ?? ""), fe(e.verdict ?? ""), S(e.internalNotes ?? ""), g(!0);
174
142
  };
175
- return /* @__PURE__ */ Q("div", {
143
+ return /* @__PURE__ */ X("div", {
176
144
  className: "border border-border-default rounded-lg p-4 space-y-4",
177
145
  children: [
178
- /* @__PURE__ */ Q("div", {
146
+ /* @__PURE__ */ X("div", {
179
147
  className: "flex flex-col sm:flex-row sm:items-start sm:justify-between gap-3",
180
- children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Q("div", {
148
+ children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ X("div", {
181
149
  className: "flex items-center gap-2 flex-wrap mb-1",
182
150
  children: [
183
- /* @__PURE__ */ Z("h3", {
151
+ /* @__PURE__ */ Y("h3", {
184
152
  className: "text-sm font-semibold text-text-primary",
185
153
  children: a.name
186
154
  }),
187
- /* @__PURE__ */ Z(e, {
155
+ /* @__PURE__ */ Y(e, {
188
156
  variant: "outline",
189
157
  className: "bg-accent-indigo-subtle text-accent-indigo text-xs",
190
158
  children: $(a.roundType)
191
159
  }),
192
- /* @__PURE__ */ Z(e, {
193
- className: `${X.className} text-xs`,
194
- children: X.label
160
+ /* @__PURE__ */ Y(e, {
161
+ className: `${H.className} text-xs`,
162
+ children: H.label
195
163
  })
196
164
  ]
197
- }), a.scheduledAt && /* @__PURE__ */ Q("p", {
165
+ }), a.scheduledAt && /* @__PURE__ */ X("p", {
198
166
  className: "text-xs text-text-secondary flex items-center gap-1",
199
- children: [/* @__PURE__ */ Z(R, { size: 12 }), Ne(a.scheduledAt)]
200
- })] }), /* @__PURE__ */ Q("div", {
167
+ children: [/* @__PURE__ */ Y(_e, { size: 12 }), Q(a.scheduledAt)]
168
+ })] }), /* @__PURE__ */ X("div", {
201
169
  className: "flex items-center gap-2",
202
- children: [/* @__PURE__ */ Q(t, {
170
+ children: [/* @__PURE__ */ X(t, {
203
171
  variant: "outline",
204
172
  size: "sm",
205
173
  onClick: l,
206
- children: [/* @__PURE__ */ Z(ve, { size: 14 }), "Assign"]
207
- }), /* @__PURE__ */ Q(t, {
174
+ children: [/* @__PURE__ */ Y(Ce, { size: 14 }), "Assign"]
175
+ }), /* @__PURE__ */ X(t, {
208
176
  variant: "outline",
209
177
  size: "sm",
210
- onClick: y,
211
- children: [/* @__PURE__ */ Z(de, { size: 14 }), "Message"]
178
+ onClick: ie,
179
+ children: [/* @__PURE__ */ Y(G, { size: 14 }), "Message"]
212
180
  })]
213
181
  })]
214
182
  }),
215
- a.interviewers.length > 0 && /* @__PURE__ */ Q("div", {
183
+ a.interviewers.length > 0 && /* @__PURE__ */ X("div", {
216
184
  className: "space-y-2",
217
- children: [/* @__PURE__ */ Z("p", {
185
+ children: [/* @__PURE__ */ Y("p", {
218
186
  className: "text-xs font-medium text-text-secondary uppercase tracking-wider",
219
187
  children: "Interviewers"
220
- }), /* @__PURE__ */ Z("div", {
188
+ }), /* @__PURE__ */ Y("div", {
221
189
  className: "flex flex-wrap gap-2",
222
- children: a.interviewers.map((t) => /* @__PURE__ */ Q("div", {
190
+ children: a.interviewers.map((t) => /* @__PURE__ */ X("div", {
223
191
  className: "inline-flex items-center gap-2 pl-2 pr-1 py-1 rounded-full bg-bg-muted text-text-primary text-xs",
224
192
  children: [
225
- /* @__PURE__ */ Z("span", {
193
+ /* @__PURE__ */ Y("span", {
226
194
  className: "font-medium",
227
195
  children: t.interviewer.name
228
196
  }),
229
- /* @__PURE__ */ Z(e, {
197
+ /* @__PURE__ */ Y(e, {
230
198
  variant: "outline",
231
199
  className: "text-[10px] px-1.5 py-0",
232
200
  children: $(t.role)
233
201
  }),
234
- /* @__PURE__ */ Z("button", {
202
+ /* @__PURE__ */ Y("button", {
235
203
  type: "button",
236
- onClick: () => u(a.id, t.interviewer.id),
204
+ onClick: () => te(a.id, t.interviewer.id),
237
205
  className: "p-0.5 rounded-full hover:bg-status-error-bg-subtle hover:text-status-error-text transition-colors",
238
206
  title: "Remove interviewer",
239
- children: /* @__PURE__ */ Z(ye, { size: 12 })
207
+ children: /* @__PURE__ */ Y(we, { size: 12 })
240
208
  })
241
209
  ]
242
210
  }, t.id))
243
211
  })]
244
212
  }),
245
- a.candidateMessage && /* @__PURE__ */ Q("div", {
213
+ a.candidateMessage && /* @__PURE__ */ X("div", {
246
214
  className: "p-3 rounded-lg bg-status-info-bg-subtle border border-border-subtle",
247
215
  children: [
248
- /* @__PURE__ */ Z("p", {
216
+ /* @__PURE__ */ Y("p", {
249
217
  className: "text-xs font-medium text-status-info-text mb-1",
250
218
  children: "Candidate message"
251
219
  }),
252
- /* @__PURE__ */ Z("p", {
220
+ /* @__PURE__ */ Y("p", {
253
221
  className: "text-sm text-text-primary whitespace-pre-wrap",
254
222
  children: a.candidateMessage
255
223
  }),
256
- a.candidateMessageSentAt && /* @__PURE__ */ Q("p", {
224
+ a.candidateMessageSentAt && /* @__PURE__ */ X("p", {
257
225
  className: "text-[11px] text-text-secondary mt-1",
258
- children: ["Sent ", Ne(a.candidateMessageSentAt)]
226
+ children: ["Sent ", Q(a.candidateMessageSentAt)]
259
227
  })
260
228
  ]
261
229
  }),
262
- K && /* @__PURE__ */ Q(n, {
230
+ ye && /* @__PURE__ */ X(n, {
263
231
  className: "border border-border-default bg-bg-surface",
264
- children: [/* @__PURE__ */ Z(i, {
232
+ children: [/* @__PURE__ */ Y(i, {
265
233
  className: "pb-2",
266
- children: /* @__PURE__ */ Q(ee, {
234
+ children: /* @__PURE__ */ X(ee, {
267
235
  className: "text-xs font-semibold text-text-secondary uppercase tracking-wider flex items-center gap-2",
268
- children: [/* @__PURE__ */ Z(G, { size: 14 }), "Assignment"]
236
+ children: [/* @__PURE__ */ Y(R, { size: 14 }), "Assignment"]
269
237
  })
270
- }), /* @__PURE__ */ Q(r, {
238
+ }), /* @__PURE__ */ X(r, {
271
239
  className: "space-y-3",
272
- children: [z && /* @__PURE__ */ Q("div", {
240
+ children: [j && /* @__PURE__ */ X("div", {
273
241
  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",
274
- children: [/* @__PURE__ */ Z(ce, { size: 14 }), z]
275
- }), !q && !J ? /* @__PURE__ */ Q(t, {
242
+ children: [/* @__PURE__ */ Y(ge, { size: 14 }), j]
243
+ }), !L && !z ? /* @__PURE__ */ X(t, {
276
244
  size: "sm",
277
- onClick: pe,
278
- disabled: H,
279
- children: [H ? /* @__PURE__ */ Z(Y, {
245
+ onClick: be,
246
+ disabled: P,
247
+ children: [P ? /* @__PURE__ */ Y(U, {
280
248
  size: 14,
281
249
  className: "animate-spin mr-1"
282
- }) : /* @__PURE__ */ Z(he, { size: 14 }), "Randomize & Send Assignment"]
283
- }) : /* @__PURE__ */ Q("div", {
250
+ }) : /* @__PURE__ */ Y(K, { size: 14 }), "Randomize & Send Assignment"]
251
+ }) : /* @__PURE__ */ X("div", {
284
252
  className: "space-y-4",
285
- children: [a.assignment && /* @__PURE__ */ Q("div", {
253
+ children: [a.assignment && /* @__PURE__ */ X("div", {
286
254
  className: "space-y-1",
287
- children: [/* @__PURE__ */ Z("p", {
288
- className: "text-sm font-semibold text-text-primary",
289
- children: a.assignment.title
290
- }), /* @__PURE__ */ Z("p", {
291
- className: "text-sm text-text-secondary whitespace-pre-wrap",
292
- children: a.assignment.description
293
- })]
294
- }), ue && /* @__PURE__ */ Q("div", {
255
+ children: [
256
+ /* @__PURE__ */ Y("p", {
257
+ className: "text-sm font-semibold text-text-primary",
258
+ children: a.assignment.title
259
+ }),
260
+ /* @__PURE__ */ Y("p", {
261
+ className: "text-sm text-text-secondary whitespace-pre-wrap",
262
+ children: a.assignment.description
263
+ }),
264
+ V && /* @__PURE__ */ X("p", {
265
+ className: "text-[11px] text-text-secondary",
266
+ children: ["Sent ", Q(V)]
267
+ })
268
+ ]
269
+ }), B && /* @__PURE__ */ X("div", {
295
270
  className: "space-y-3",
296
271
  children: [
297
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
272
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
298
273
  htmlFor: `assignment-repo-${a.id}`,
299
274
  children: "GitHub Repo URL"
300
- }), /* @__PURE__ */ Z(d, {
275
+ }), /* @__PURE__ */ Y(ne, {
301
276
  id: `assignment-repo-${a.id}`,
302
- value: M,
303
- onChange: (e) => se(e.target.value),
277
+ value: T,
278
+ onChange: (e) => me(e.target.value),
304
279
  placeholder: "https://github.com/…"
305
280
  })] }),
306
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
281
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
307
282
  htmlFor: `assignment-video-${a.id}`,
308
283
  children: "Jam Video URL"
309
- }), /* @__PURE__ */ Z(d, {
284
+ }), /* @__PURE__ */ Y(ne, {
310
285
  id: `assignment-video-${a.id}`,
311
- value: P,
312
- onChange: (e) => F(e.target.value),
286
+ value: E,
287
+ onChange: (e) => he(e.target.value),
313
288
  placeholder: "https://jam.dev/…"
314
289
  })] }),
315
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
290
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
316
291
  htmlFor: `assignment-notes-${a.id}`,
317
292
  children: "Notes"
318
- }), /* @__PURE__ */ Z(v, {
293
+ }), /* @__PURE__ */ Y(re, {
319
294
  id: `assignment-notes-${a.id}`,
320
- value: I,
321
- onChange: (e) => L(e.target.value),
295
+ value: k,
296
+ onChange: (e) => A(e.target.value),
322
297
  placeholder: "Add submission notes…",
323
298
  rows: 3
324
299
  })] }),
325
- /* @__PURE__ */ Z("div", {
300
+ /* @__PURE__ */ Y("div", {
326
301
  className: "flex items-center justify-end",
327
- children: /* @__PURE__ */ Q(t, {
302
+ children: /* @__PURE__ */ X(t, {
328
303
  size: "sm",
329
- onClick: _e,
330
- disabled: W || !M.trim() && !P.trim() && !I.trim(),
331
- children: [W ? /* @__PURE__ */ Z(Y, {
304
+ onClick: xe,
305
+ disabled: F || !T.trim() && !E.trim() && !k.trim(),
306
+ children: [F ? /* @__PURE__ */ Y(U, {
332
307
  size: 14,
333
308
  className: "animate-spin mr-1"
334
309
  }) : null, "Record Submission"]
@@ -339,152 +314,152 @@ function Re({ round: a, applicationId: o, interviewers: s, interviewersLoading:
339
314
  })]
340
315
  })]
341
316
  }),
342
- /* @__PURE__ */ Q("div", {
317
+ /* @__PURE__ */ X("div", {
343
318
  className: "space-y-3",
344
319
  children: [
345
- /* @__PURE__ */ Q("div", {
320
+ /* @__PURE__ */ X("div", {
346
321
  className: "flex items-center justify-between",
347
- children: [/* @__PURE__ */ Z("p", {
322
+ children: [/* @__PURE__ */ Y("p", {
348
323
  className: "text-xs font-medium text-text-secondary uppercase tracking-wider",
349
324
  children: "Feedback"
350
- }), !re && /* @__PURE__ */ Q(t, {
325
+ }), !se && /* @__PURE__ */ X(t, {
351
326
  variant: "ghost",
352
327
  size: "sm",
353
- onClick: be,
354
- children: [/* @__PURE__ */ Z(me, { size: 14 }), "Add Feedback"]
328
+ onClick: J,
329
+ children: [/* @__PURE__ */ Y(Se, { size: 14 }), "Add Feedback"]
355
330
  })]
356
331
  }),
357
- a.feedback.length > 0 && /* @__PURE__ */ Z("div", {
332
+ a.feedback.length > 0 && /* @__PURE__ */ Y("div", {
358
333
  className: "space-y-2",
359
- children: a.feedback.map((n) => /* @__PURE__ */ Q("div", {
334
+ children: a.feedback.map((n) => /* @__PURE__ */ X("div", {
360
335
  className: "p-3 rounded-lg bg-bg-muted/30 border border-border-default",
361
- children: [/* @__PURE__ */ Q("div", {
336
+ children: [/* @__PURE__ */ X("div", {
362
337
  className: "flex items-start justify-between gap-3",
363
- children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
338
+ children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
364
339
  className: "text-sm font-medium text-text-primary",
365
340
  children: n.interviewer.name
366
- }), /* @__PURE__ */ Q("div", {
341
+ }), /* @__PURE__ */ X("div", {
367
342
  className: "flex items-center gap-2 mt-1",
368
- children: [n.rating && /* @__PURE__ */ Z("span", {
343
+ children: [n.rating && /* @__PURE__ */ Y("span", {
369
344
  className: "inline-flex items-center gap-0.5 text-xs text-status-warning-text",
370
- children: Array.from({ length: n.rating }).map((e, t) => /* @__PURE__ */ Z(ge, {
345
+ children: Array.from({ length: n.rating }).map((e, t) => /* @__PURE__ */ Y(q, {
371
346
  size: 12,
372
347
  fill: "currentColor"
373
348
  }, t))
374
- }), n.verdict && /* @__PURE__ */ Z(e, {
375
- className: `${Ie(n.verdict)} text-xs`,
349
+ }), n.verdict && /* @__PURE__ */ Y(e, {
350
+ className: `${ze(n.verdict)} text-xs`,
376
351
  children: $(n.verdict)
377
352
  })]
378
- })] }), /* @__PURE__ */ Z(t, {
353
+ })] }), /* @__PURE__ */ Y(t, {
379
354
  variant: "ghost",
380
355
  size: "sm",
381
- onClick: () => xe(n),
382
- children: /* @__PURE__ */ Z(U, { size: 14 })
356
+ onClick: () => Te(n),
357
+ children: /* @__PURE__ */ Y(I, { size: 14 })
383
358
  })]
384
- }), n.internalNotes && /* @__PURE__ */ Z("p", {
359
+ }), n.internalNotes && /* @__PURE__ */ Y("p", {
385
360
  className: "mt-2 text-sm text-text-secondary whitespace-pre-wrap",
386
361
  children: n.internalNotes
387
362
  })]
388
363
  }, n.id))
389
364
  }),
390
- re && /* @__PURE__ */ Q("div", {
365
+ se && /* @__PURE__ */ X("div", {
391
366
  className: "p-3 rounded-lg border border-border-default bg-bg-surface space-y-3",
392
367
  children: [
393
- !x && /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
368
+ !_ && /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
394
369
  htmlFor: `feedback-interviewer-${a.id}`,
395
370
  children: "Interviewer"
396
- }), /* @__PURE__ */ Q(p, {
397
- value: w,
398
- onValueChange: T,
399
- children: [/* @__PURE__ */ Z(g, {
371
+ }), /* @__PURE__ */ X(d, {
372
+ value: v,
373
+ onValueChange: b,
374
+ children: [/* @__PURE__ */ Y(m, {
400
375
  id: `feedback-interviewer-${a.id}`,
401
- children: /* @__PURE__ */ Z(_, { placeholder: "Select interviewer" })
402
- }), /* @__PURE__ */ Z(m, { children: c ? /* @__PURE__ */ Z(h, {
376
+ children: /* @__PURE__ */ Y(h, { placeholder: "Select interviewer" })
377
+ }), /* @__PURE__ */ Y(f, { children: c ? /* @__PURE__ */ Y(p, {
403
378
  value: "loading",
404
379
  disabled: !0,
405
380
  children: "Loading…"
406
- }) : s.map((e) => /* @__PURE__ */ Z(h, {
381
+ }) : s.map((e) => /* @__PURE__ */ Y(p, {
407
382
  value: e.id,
408
383
  children: e.name
409
384
  }, e.id)) })]
410
385
  })] }),
411
- /* @__PURE__ */ Q("div", {
386
+ /* @__PURE__ */ X("div", {
412
387
  className: "grid grid-cols-2 gap-3",
413
- children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
388
+ children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
414
389
  htmlFor: `feedback-rating-${a.id}`,
415
390
  children: "Rating"
416
- }), /* @__PURE__ */ Q(p, {
417
- value: ae,
418
- onValueChange: E,
419
- children: [/* @__PURE__ */ Z(g, {
391
+ }), /* @__PURE__ */ X(d, {
392
+ value: x,
393
+ onValueChange: ue,
394
+ children: [/* @__PURE__ */ Y(m, {
420
395
  id: `feedback-rating-${a.id}`,
421
- children: /* @__PURE__ */ Z(_, { placeholder: "1–5" })
422
- }), /* @__PURE__ */ Z(m, { children: [
396
+ children: /* @__PURE__ */ Y(h, { placeholder: "1–5" })
397
+ }), /* @__PURE__ */ Y(f, { children: [
423
398
  1,
424
399
  2,
425
400
  3,
426
401
  4,
427
402
  5
428
- ].map((e) => /* @__PURE__ */ Z(h, {
403
+ ].map((e) => /* @__PURE__ */ Y(p, {
429
404
  value: String(e),
430
405
  children: e
431
406
  }, e)) })]
432
- })] }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
407
+ })] }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
433
408
  htmlFor: `feedback-verdict-${a.id}`,
434
409
  children: "Verdict"
435
- }), /* @__PURE__ */ Q(p, {
436
- value: oe,
437
- onValueChange: (e) => D(e),
438
- children: [/* @__PURE__ */ Z(g, {
410
+ }), /* @__PURE__ */ X(d, {
411
+ value: de,
412
+ onValueChange: (e) => fe(e),
413
+ children: [/* @__PURE__ */ Y(m, {
439
414
  id: `feedback-verdict-${a.id}`,
440
- children: /* @__PURE__ */ Z(_, { placeholder: "Verdict" })
441
- }), /* @__PURE__ */ Z(m, { children: Object.values(k).map((e) => /* @__PURE__ */ Z(h, {
415
+ children: /* @__PURE__ */ Y(h, { placeholder: "Verdict" })
416
+ }), /* @__PURE__ */ Y(f, { children: Object.values(w).map((e) => /* @__PURE__ */ Y(p, {
442
417
  value: e,
443
418
  children: $(e)
444
419
  }, e)) })]
445
420
  })] })]
446
421
  }),
447
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
422
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
448
423
  htmlFor: `feedback-notes-${a.id}`,
449
424
  children: "Internal Notes"
450
- }), /* @__PURE__ */ Z(v, {
425
+ }), /* @__PURE__ */ Y(re, {
451
426
  id: `feedback-notes-${a.id}`,
452
- value: A,
453
- onChange: (e) => j(e.target.value),
427
+ value: pe,
428
+ onChange: (e) => S(e.target.value),
454
429
  placeholder: "Add private notes about this round…",
455
430
  rows: 3
456
431
  })] }),
457
- /* @__PURE__ */ Q("div", {
432
+ /* @__PURE__ */ X("div", {
458
433
  className: "flex items-center justify-end gap-2",
459
- children: [/* @__PURE__ */ Z(t, {
434
+ children: [/* @__PURE__ */ Y(t, {
460
435
  variant: "outline",
461
436
  size: "sm",
462
437
  onClick: () => {
463
- fe(), b(!1);
438
+ W(), g(!1);
464
439
  },
465
440
  children: "Cancel"
466
- }), /* @__PURE__ */ Z(t, {
441
+ }), /* @__PURE__ */ Y(t, {
467
442
  size: "sm",
468
443
  onClick: async () => {
469
- let e = ae ? parseInt(ae, 10) : void 0, t = oe || void 0, n = A.trim() || void 0;
470
- if (x) await ne(x.id, {
444
+ let e = x ? parseInt(x, 10) : void 0, t = de || void 0, n = pe.trim() || void 0;
445
+ if (_) await oe(_.id, {
471
446
  rating: e,
472
447
  verdict: t,
473
448
  internalNotes: n
474
449
  });
475
450
  else {
476
- if (!w) return;
477
- await te(a.id, {
478
- interviewerId: w,
451
+ if (!v) return;
452
+ await ae(a.id, {
453
+ interviewerId: v,
479
454
  rating: e,
480
455
  verdict: t,
481
456
  internalNotes: n
482
457
  });
483
458
  }
484
- fe(), b(!1);
459
+ W(), g(!1);
485
460
  },
486
- disabled: !x && !w,
487
- children: x ? "Update Feedback" : "Submit Feedback"
461
+ disabled: !_ && !v,
462
+ children: _ ? "Update Feedback" : "Submit Feedback"
488
463
  })]
489
464
  })
490
465
  ]
@@ -494,220 +469,282 @@ function Re({ round: a, applicationId: o, interviewers: s, interviewersLoading:
494
469
  ]
495
470
  });
496
471
  }
497
- function ze({ applicationId: e }) {
498
- let { data: n, loading: r, error: i } = re({ variables: { applicationId: e } }), { data: ee, loading: b } = ne({ variables: { limit: 200 } }), [x, { loading: S }] = te({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [ie, { loading: w }] = y({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [oe] = C({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [k, { loading: j }] = T({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [M] = ae({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [se] = E({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), P = n?.jobApplicationInterviewRounds ?? [], F = ee?.interviewers.items ?? [], [I, L] = N(!1), [R, z] = N({
472
+ function He({ applicationId: e, jobPostingId: n }) {
473
+ let { data: r, loading: i, error: ee } = se({ variables: { applicationId: e } }), { data: g, loading: _ } = v({
474
+ variables: { id: n ?? "" },
475
+ skip: !n
476
+ }), { data: ce, loading: y } = oe({ variables: { limit: 200 } }), [le, { loading: x }] = ae({ refetchQueries: ["GetJobApplicationInterviewRounds", "GetJobApplication"] }), [pe, { loading: w }] = ie({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [me] = b({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [E, { loading: D }] = ue({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [he] = de({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), [k] = fe({ refetchQueries: ["GetJobApplicationInterviewRounds"] }), A = r?.jobApplicationInterviewRounds ?? [], j = ce?.interviewers.items ?? [], M = g?.jobPosting?.rounds ?? [], [_e, N] = O(!1), [P, ve] = O(Z), [F, I] = O({
499
477
  name: "",
500
- roundType: O.PhoneScreen,
501
- status: D.Scheduled,
478
+ roundType: C.PhoneScreen,
479
+ status: S.Scheduled,
502
480
  scheduledAt: ""
503
- }), [B, V] = N(null), [H, U] = N([]), [le, W] = N(A.Panel), [G, K] = N(null), [q, J] = N(""), [ue, X] = N(null), de = () => {
504
- z({
481
+ }), [ye, L] = O(null), [R, z] = O([]), [B, V] = O(T.Panel), [H, W] = O(null), [G, be] = O(""), [xe, K] = O(null), q = M.filter((e) => !A.some((t) => t.roundConfigId === e.id)), J = () => {
482
+ ve(Z), I({
505
483
  name: "",
506
- roundType: O.PhoneScreen,
507
- status: D.Scheduled,
484
+ roundType: C.PhoneScreen,
485
+ status: S.Scheduled,
508
486
  scheduledAt: ""
509
487
  });
510
- }, fe = async () => {
511
- if (R.name.trim()) {
512
- X(null);
488
+ }, Ce = (e) => {
489
+ if (ve(e), e === Z) {
490
+ I((e) => ({
491
+ ...e,
492
+ name: ""
493
+ }));
494
+ return;
495
+ }
496
+ let t = M.find((t) => t.id === e);
497
+ t && I((e) => ({
498
+ ...e,
499
+ name: t.name,
500
+ roundType: t.roundType
501
+ }));
502
+ }, we = () => {
503
+ let e = q[0];
504
+ e ? (ve(e.id), I({
505
+ name: e.name,
506
+ roundType: e.roundType,
507
+ status: S.Scheduled,
508
+ scheduledAt: ""
509
+ })) : J(), N(!0);
510
+ }, Ee = async () => {
511
+ if (F.name.trim()) {
512
+ K(null);
513
513
  try {
514
- await x({ variables: { input: {
514
+ await le({ variables: { input: {
515
515
  applicationId: e,
516
- name: R.name.trim(),
517
- roundType: R.roundType,
518
- status: R.status,
519
- scheduledAt: R.scheduledAt || void 0
520
- } } }), de(), L(!1);
516
+ roundConfigId: P === Z ? void 0 : P,
517
+ name: F.name.trim(),
518
+ roundType: F.roundType,
519
+ status: F.status,
520
+ scheduledAt: F.scheduledAt || void 0
521
+ } } }), J(), N(!1);
521
522
  } catch (e) {
522
- console.error("Failed to create interview round:", e), X("Failed to create interview round.");
523
+ console.error("Failed to create interview round:", e), K("Failed to create interview round.");
523
524
  }
524
525
  }
525
- }, pe = async () => {
526
- if (!(!B || H.length === 0)) {
527
- X(null);
526
+ }, De = async () => {
527
+ if (!(!ye || R.length === 0)) {
528
+ K(null);
528
529
  try {
529
- await ie({ variables: { input: {
530
- roundId: B,
531
- assignments: H.map((e) => ({
530
+ await pe({ variables: { input: {
531
+ roundId: ye,
532
+ assignments: R.map((e) => ({
532
533
  interviewerId: e,
533
- role: le
534
+ role: B
534
535
  }))
535
- } } }), U([]), W(A.Panel), V(null);
536
+ } } }), z([]), V(T.Panel), L(null);
536
537
  } catch (e) {
537
- console.error("Failed to assign interviewers:", e), X("Failed to assign interviewers.");
538
+ console.error("Failed to assign interviewers:", e), K("Failed to assign interviewers.");
538
539
  }
539
540
  }
540
- }, he = async (e, t) => {
541
- X(null);
541
+ }, Oe = async (e, t) => {
542
+ K(null);
542
543
  try {
543
- await oe({ variables: {
544
+ await me({ variables: {
544
545
  roundId: e,
545
546
  interviewerId: t
546
547
  } });
547
548
  } catch (e) {
548
- console.error("Failed to remove interviewer:", e), X("Failed to remove interviewer.");
549
+ console.error("Failed to remove interviewer:", e), K("Failed to remove interviewer.");
549
550
  }
550
- }, ge = async () => {
551
- if (!(!G || !q.trim())) {
552
- X(null);
551
+ }, ke = async () => {
552
+ if (!(!H || !G.trim())) {
553
+ K(null);
553
554
  try {
554
- await k({ variables: { input: {
555
- roundId: G,
556
- message: q.trim()
557
- } } }), J(""), K(null);
555
+ await E({ variables: { input: {
556
+ roundId: H,
557
+ message: G.trim()
558
+ } } }), be(""), W(null);
558
559
  } catch (e) {
559
- console.error("Failed to send candidate message:", e), X("Failed to send candidate message.");
560
+ console.error("Failed to send candidate message:", e), K("Failed to send candidate message.");
560
561
  }
561
562
  }
562
- }, _e = async (e, t) => {
563
- X(null);
563
+ }, Ae = async (e, t) => {
564
+ K(null);
564
565
  try {
565
- await M({ variables: { input: {
566
+ await he({ variables: { input: {
566
567
  roundId: e,
567
568
  ...t
568
569
  } } });
569
570
  } catch (e) {
570
- throw console.error("Failed to submit feedback:", e), X("Failed to submit feedback."), e;
571
+ throw console.error("Failed to submit feedback:", e), K("Failed to submit feedback."), e;
571
572
  }
572
- }, ve = async (e, t) => {
573
- X(null);
573
+ }, je = async (e, t) => {
574
+ K(null);
574
575
  try {
575
- await se({ variables: {
576
+ await k({ variables: {
576
577
  id: e,
577
578
  input: t
578
579
  } });
579
580
  } catch (e) {
580
- throw console.error("Failed to update feedback:", e), X("Failed to update feedback."), e;
581
+ throw console.error("Failed to update feedback:", e), K("Failed to update feedback."), e;
581
582
  }
582
583
  };
583
- return /* @__PURE__ */ Q("div", {
584
+ return /* @__PURE__ */ X("div", {
584
585
  className: "bg-bg-surface border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
585
586
  children: [
586
- /* @__PURE__ */ Q("div", {
587
+ /* @__PURE__ */ X("div", {
587
588
  className: "px-5 py-3.5 border-b border-border-default bg-bg-muted/50 flex items-center justify-between",
588
- children: [/* @__PURE__ */ Q("h2", {
589
+ children: [/* @__PURE__ */ X("h2", {
589
590
  className: "text-xs font-semibold text-text-secondary uppercase tracking-wider flex items-center gap-2",
590
- children: [/* @__PURE__ */ Z(be, { size: 14 }), "Interview Rounds"]
591
- }), /* @__PURE__ */ Q(t, {
591
+ children: [/* @__PURE__ */ Y(Te, { size: 14 }), "Interview Rounds"]
592
+ }), /* @__PURE__ */ X(t, {
592
593
  size: "sm",
593
- onClick: () => L(!0),
594
- children: [/* @__PURE__ */ Z(me, { size: 14 }), "Add Round"]
594
+ onClick: we,
595
+ children: [/* @__PURE__ */ Y(Se, { size: 14 }), "Add Round"]
595
596
  })]
596
597
  }),
597
- /* @__PURE__ */ Q("div", {
598
+ /* @__PURE__ */ X("div", {
598
599
  className: "p-5",
599
- children: [ue && /* @__PURE__ */ Q("div", {
600
+ children: [xe && /* @__PURE__ */ X("div", {
600
601
  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",
601
- children: [/* @__PURE__ */ Z(ce, { size: 16 }), ue]
602
- }), r ? /* @__PURE__ */ Q("div", {
602
+ children: [/* @__PURE__ */ Y(ge, { size: 16 }), xe]
603
+ }), i ? /* @__PURE__ */ X("div", {
603
604
  className: "flex items-center gap-2 text-sm text-text-secondary py-4",
604
- children: [/* @__PURE__ */ Z(Y, {
605
+ children: [/* @__PURE__ */ Y(U, {
605
606
  size: 16,
606
607
  className: "animate-spin"
607
608
  }), "Loading interview rounds…"]
608
- }) : i ? /* @__PURE__ */ Q("div", {
609
+ }) : ee ? /* @__PURE__ */ X("div", {
609
610
  className: "p-3 rounded-lg bg-status-error-bg-subtle text-status-error-text text-sm flex items-center gap-2",
610
- children: [/* @__PURE__ */ Z(ce, { size: 16 }), "Could not load interview rounds."]
611
- }) : P.length === 0 ? /* @__PURE__ */ Z("p", {
611
+ children: [/* @__PURE__ */ Y(ge, { size: 16 }), "Could not load interview rounds."]
612
+ }) : A.length === 0 ? /* @__PURE__ */ Y("p", {
612
613
  className: "text-sm text-text-secondary",
613
614
  children: "No interview rounds yet."
614
- }) : /* @__PURE__ */ Z("div", {
615
+ }) : /* @__PURE__ */ Y("div", {
615
616
  className: "space-y-5",
616
- children: P.map((t) => /* @__PURE__ */ Z(Re, {
617
+ children: A.map((t) => /* @__PURE__ */ Y(Ve, {
617
618
  round: t,
618
619
  applicationId: e,
619
- interviewers: F,
620
- interviewersLoading: b,
620
+ interviewers: j,
621
+ interviewersLoading: y,
621
622
  onAssign: () => {
622
- V(t.id), U([]), W(A.Panel);
623
+ L(t.id), z([]), V(T.Panel);
623
624
  },
624
- onRemoveInterviewer: he,
625
+ onRemoveInterviewer: Oe,
625
626
  onSendMessage: () => {
626
- K(t.id), J("");
627
+ W(t.id), be("");
627
628
  },
628
- onSubmitFeedback: _e,
629
- onUpdateFeedback: ve
629
+ onSubmitFeedback: Ae,
630
+ onUpdateFeedback: je
630
631
  }, t.id))
631
632
  })]
632
633
  }),
633
- /* @__PURE__ */ Z(a, {
634
- open: I,
635
- onOpenChange: L,
636
- children: /* @__PURE__ */ Q(o, {
634
+ /* @__PURE__ */ Y(a, {
635
+ open: _e,
636
+ onOpenChange: (e) => {
637
+ N(e), e || J();
638
+ },
639
+ children: /* @__PURE__ */ X(o, {
637
640
  className: "sm:max-w-md",
638
641
  children: [
639
- /* @__PURE__ */ Q(l, { children: [/* @__PURE__ */ Z(u, { children: "Add Interview Round" }), /* @__PURE__ */ Z(s, { children: "Schedule a new round for this candidate." })] }),
640
- /* @__PURE__ */ Q("div", {
642
+ /* @__PURE__ */ X(l, { children: [/* @__PURE__ */ Y(te, { children: "Add Interview Round" }), /* @__PURE__ */ Y(s, { children: "Schedule a new round for this candidate." })] }),
643
+ /* @__PURE__ */ X("div", {
641
644
  className: "space-y-4 py-2",
642
645
  children: [
643
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
646
+ n && /* @__PURE__ */ X("div", { children: [
647
+ /* @__PURE__ */ Y(u, {
648
+ htmlFor: "round-config",
649
+ children: "Posting round"
650
+ }),
651
+ /* @__PURE__ */ X(d, {
652
+ value: P,
653
+ onValueChange: Ce,
654
+ disabled: _,
655
+ children: [/* @__PURE__ */ Y(m, {
656
+ id: "round-config",
657
+ children: /* @__PURE__ */ Y(h, { placeholder: "Select a configured round" })
658
+ }), /* @__PURE__ */ X(f, { children: [q.map((e) => /* @__PURE__ */ X(p, {
659
+ value: e.id,
660
+ children: [
661
+ "Round ",
662
+ e.roundNumber,
663
+ " — ",
664
+ e.name
665
+ ]
666
+ }, e.id)), /* @__PURE__ */ Y(p, {
667
+ value: Z,
668
+ children: "Custom round"
669
+ })] })]
670
+ }),
671
+ /* @__PURE__ */ Y("p", {
672
+ className: "mt-1 text-xs text-text-secondary",
673
+ children: "Configured rounds stay linked to posting-level bulk actions."
674
+ })
675
+ ] }),
676
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
644
677
  htmlFor: "round-name",
645
678
  children: "Name"
646
- }), /* @__PURE__ */ Z(d, {
679
+ }), /* @__PURE__ */ Y(ne, {
647
680
  id: "round-name",
648
- value: R.name,
649
- onChange: (e) => z((t) => ({
681
+ value: F.name,
682
+ onChange: (e) => I((t) => ({
650
683
  ...t,
651
684
  name: e.target.value
652
685
  })),
653
- placeholder: "e.g. Technical Interview"
686
+ placeholder: "e.g. Technical Interview",
687
+ disabled: P !== Z
654
688
  })] }),
655
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
689
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
656
690
  htmlFor: "round-type",
657
691
  children: "Round Type"
658
- }), /* @__PURE__ */ Q(p, {
659
- value: R.roundType,
660
- onValueChange: (e) => z((t) => ({
692
+ }), /* @__PURE__ */ X(d, {
693
+ value: F.roundType,
694
+ onValueChange: (e) => I((t) => ({
661
695
  ...t,
662
696
  roundType: e
663
697
  })),
664
- children: [/* @__PURE__ */ Z(g, {
698
+ disabled: P !== Z,
699
+ children: [/* @__PURE__ */ Y(m, {
665
700
  id: "round-type",
666
- children: /* @__PURE__ */ Z(_, {})
667
- }), /* @__PURE__ */ Z(m, { children: Object.values(O).map((e) => /* @__PURE__ */ Z(h, {
701
+ children: /* @__PURE__ */ Y(h, {})
702
+ }), /* @__PURE__ */ Y(f, { children: Object.values(C).map((e) => /* @__PURE__ */ Y(p, {
668
703
  value: e,
669
704
  children: $(e)
670
705
  }, e)) })]
671
706
  })] }),
672
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
707
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
673
708
  htmlFor: "round-status",
674
709
  children: "Status"
675
- }), /* @__PURE__ */ Q(p, {
676
- value: R.status,
677
- onValueChange: (e) => z((t) => ({
710
+ }), /* @__PURE__ */ X(d, {
711
+ value: F.status,
712
+ onValueChange: (e) => I((t) => ({
678
713
  ...t,
679
714
  status: e
680
715
  })),
681
- children: [/* @__PURE__ */ Z(g, {
716
+ children: [/* @__PURE__ */ Y(m, {
682
717
  id: "round-status",
683
- children: /* @__PURE__ */ Z(_, {})
684
- }), /* @__PURE__ */ Z(m, { children: Object.values(D).map((e) => /* @__PURE__ */ Z(h, {
718
+ children: /* @__PURE__ */ Y(h, {})
719
+ }), /* @__PURE__ */ Y(f, { children: Object.values(S).map((e) => /* @__PURE__ */ Y(p, {
685
720
  value: e,
686
721
  children: $(e)
687
722
  }, e)) })]
688
723
  })] }),
689
- /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
724
+ /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
690
725
  htmlFor: "round-scheduled",
691
726
  children: "Scheduled At"
692
- }), /* @__PURE__ */ Z(d, {
727
+ }), /* @__PURE__ */ Y(ne, {
693
728
  id: "round-scheduled",
694
729
  type: "datetime-local",
695
- value: R.scheduledAt,
696
- onChange: (e) => z((t) => ({
730
+ value: F.scheduledAt,
731
+ onChange: (e) => I((t) => ({
697
732
  ...t,
698
733
  scheduledAt: e.target.value
699
734
  }))
700
735
  })] })
701
736
  ]
702
737
  }),
703
- /* @__PURE__ */ Q(c, { children: [/* @__PURE__ */ Z(t, {
738
+ /* @__PURE__ */ X(c, { children: [/* @__PURE__ */ Y(t, {
704
739
  variant: "outline",
705
- onClick: () => L(!1),
740
+ onClick: () => {
741
+ N(!1), J();
742
+ },
706
743
  children: "Cancel"
707
- }), /* @__PURE__ */ Q(t, {
708
- onClick: fe,
709
- disabled: S || !R.name.trim(),
710
- children: [S ? /* @__PURE__ */ Z(Y, {
744
+ }), /* @__PURE__ */ X(t, {
745
+ onClick: Ee,
746
+ disabled: x || !F.name.trim(),
747
+ children: [x ? /* @__PURE__ */ Y(U, {
711
748
  size: 14,
712
749
  className: "animate-spin mr-1"
713
750
  }) : null, "Create Round"]
@@ -715,54 +752,54 @@ function ze({ applicationId: e }) {
715
752
  ]
716
753
  })
717
754
  }),
718
- /* @__PURE__ */ Z(a, {
719
- open: !!B,
720
- onOpenChange: (e) => !e && V(null),
721
- children: /* @__PURE__ */ Q(o, {
755
+ /* @__PURE__ */ Y(a, {
756
+ open: !!ye,
757
+ onOpenChange: (e) => !e && L(null),
758
+ children: /* @__PURE__ */ X(o, {
722
759
  className: "sm:max-w-md",
723
760
  children: [
724
- /* @__PURE__ */ Q(l, { children: [/* @__PURE__ */ Z(u, { children: "Assign Interviewers" }), /* @__PURE__ */ Z(s, { children: "Choose interviewers and a role for this round." })] }),
725
- /* @__PURE__ */ Q("div", {
761
+ /* @__PURE__ */ X(l, { children: [/* @__PURE__ */ Y(te, { children: "Assign Interviewers" }), /* @__PURE__ */ Y(s, { children: "Choose interviewers and a role for this round." })] }),
762
+ /* @__PURE__ */ X("div", {
726
763
  className: "space-y-4 py-2",
727
- children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, {
764
+ children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, {
728
765
  htmlFor: "assign-role",
729
766
  children: "Role"
730
- }), /* @__PURE__ */ Q(p, {
731
- value: le,
732
- onValueChange: (e) => W(e),
733
- children: [/* @__PURE__ */ Z(g, {
767
+ }), /* @__PURE__ */ X(d, {
768
+ value: B,
769
+ onValueChange: (e) => V(e),
770
+ children: [/* @__PURE__ */ Y(m, {
734
771
  id: "assign-role",
735
- children: /* @__PURE__ */ Z(_, {})
736
- }), /* @__PURE__ */ Z(m, { children: Object.values(A).map((e) => /* @__PURE__ */ Z(h, {
772
+ children: /* @__PURE__ */ Y(h, {})
773
+ }), /* @__PURE__ */ Y(f, { children: Object.values(T).map((e) => /* @__PURE__ */ Y(p, {
737
774
  value: e,
738
775
  children: $(e)
739
776
  }, e)) })]
740
- })] }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z(f, { children: "Interviewers" }), /* @__PURE__ */ Z("div", {
777
+ })] }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y(u, { children: "Interviewers" }), /* @__PURE__ */ Y("div", {
741
778
  className: "mt-1.5 max-h-60 overflow-y-auto border border-border-default rounded-lg p-2 space-y-1",
742
- children: b ? /* @__PURE__ */ Q("div", {
779
+ children: y ? /* @__PURE__ */ X("div", {
743
780
  className: "flex items-center gap-2 text-sm text-text-secondary py-2",
744
- children: [/* @__PURE__ */ Z(Y, {
781
+ children: [/* @__PURE__ */ Y(U, {
745
782
  size: 14,
746
783
  className: "animate-spin"
747
784
  }), "Loading…"]
748
- }) : F.length === 0 ? /* @__PURE__ */ Z("p", {
785
+ }) : j.length === 0 ? /* @__PURE__ */ Y("p", {
749
786
  className: "text-sm text-text-secondary py-2",
750
787
  children: "No interviewers found."
751
- }) : F.map((e) => /* @__PURE__ */ Q("label", {
788
+ }) : j.map((e) => /* @__PURE__ */ X("label", {
752
789
  className: "flex items-start gap-2 p-2 rounded-md hover:bg-bg-muted cursor-pointer",
753
- children: [/* @__PURE__ */ Z("input", {
790
+ children: [/* @__PURE__ */ Y("input", {
754
791
  type: "checkbox",
755
792
  className: "mt-1",
756
- checked: H.includes(e.id),
793
+ checked: R.includes(e.id),
757
794
  onChange: (t) => {
758
- U((n) => t.target.checked ? [...n, e.id] : n.filter((t) => t !== e.id));
795
+ z((n) => t.target.checked ? [...n, e.id] : n.filter((t) => t !== e.id));
759
796
  }
760
- }), /* @__PURE__ */ Q("div", {
797
+ }), /* @__PURE__ */ X("div", {
761
798
  className: "text-sm",
762
- children: [/* @__PURE__ */ Z("p", {
799
+ children: [/* @__PURE__ */ Y("p", {
763
800
  className: "font-medium text-text-primary",
764
801
  children: e.name
765
- }), /* @__PURE__ */ Z("p", {
802
+ }), /* @__PURE__ */ Y("p", {
766
803
  className: "text-xs text-text-secondary",
767
804
  children: e.email
768
805
  })]
@@ -770,14 +807,14 @@ function ze({ applicationId: e }) {
770
807
  }, e.id))
771
808
  })] })]
772
809
  }),
773
- /* @__PURE__ */ Q(c, { children: [/* @__PURE__ */ Z(t, {
810
+ /* @__PURE__ */ X(c, { children: [/* @__PURE__ */ Y(t, {
774
811
  variant: "outline",
775
- onClick: () => V(null),
812
+ onClick: () => L(null),
776
813
  children: "Cancel"
777
- }), /* @__PURE__ */ Q(t, {
778
- onClick: pe,
779
- disabled: w || H.length === 0,
780
- children: [w ? /* @__PURE__ */ Z(Y, {
814
+ }), /* @__PURE__ */ X(t, {
815
+ onClick: De,
816
+ disabled: w || R.length === 0,
817
+ children: [w ? /* @__PURE__ */ Y(U, {
781
818
  size: 14,
782
819
  className: "animate-spin mr-1"
783
820
  }) : null, "Assign"]
@@ -785,30 +822,30 @@ function ze({ applicationId: e }) {
785
822
  ]
786
823
  })
787
824
  }),
788
- /* @__PURE__ */ Z(a, {
789
- open: !!G,
790
- onOpenChange: (e) => !e && K(null),
791
- children: /* @__PURE__ */ Q(o, {
825
+ /* @__PURE__ */ Y(a, {
826
+ open: !!H,
827
+ onOpenChange: (e) => !e && W(null),
828
+ children: /* @__PURE__ */ X(o, {
792
829
  className: "sm:max-w-md",
793
830
  children: [
794
- /* @__PURE__ */ Q(l, { children: [/* @__PURE__ */ Z(u, { children: "Send Candidate Message" }), /* @__PURE__ */ Z(s, { children: "This message will be emailed to the candidate for this round." })] }),
795
- /* @__PURE__ */ Z("div", {
831
+ /* @__PURE__ */ X(l, { children: [/* @__PURE__ */ Y(te, { children: "Send Candidate Message" }), /* @__PURE__ */ Y(s, { children: "This message will be emailed to the candidate for this round." })] }),
832
+ /* @__PURE__ */ Y("div", {
796
833
  className: "py-2",
797
- children: /* @__PURE__ */ Z(v, {
798
- value: q,
799
- onChange: (e) => J(e.target.value),
834
+ children: /* @__PURE__ */ Y(re, {
835
+ value: G,
836
+ onChange: (e) => be(e.target.value),
800
837
  placeholder: "Type the message to send…",
801
838
  rows: 5
802
839
  })
803
840
  }),
804
- /* @__PURE__ */ Q(c, { children: [/* @__PURE__ */ Z(t, {
841
+ /* @__PURE__ */ X(c, { children: [/* @__PURE__ */ Y(t, {
805
842
  variant: "outline",
806
- onClick: () => K(null),
843
+ onClick: () => W(null),
807
844
  children: "Cancel"
808
- }), /* @__PURE__ */ Q(t, {
809
- onClick: ge,
810
- disabled: j || !q.trim(),
811
- children: [j ? /* @__PURE__ */ Z(Y, {
845
+ }), /* @__PURE__ */ X(t, {
846
+ onClick: ke,
847
+ disabled: D || !G.trim(),
848
+ children: [D ? /* @__PURE__ */ Y(U, {
812
849
  size: 14,
813
850
  className: "animate-spin mr-1"
814
851
  }) : null, "Send Message"]
@@ -819,131 +856,141 @@ function ze({ applicationId: e }) {
819
856
  ]
820
857
  });
821
858
  }
822
- function Be() {
823
- let { id: e } = we(), t = Ce(), n = Se().search, [r, i] = N(!1), [ee, a] = N(!1), [o, s] = N(!1), [c, l] = N(!1), [u, d] = N(""), [f, p] = N(!1), [m, h] = N(null), { data: g, loading: _, error: v } = b({
859
+ function Ue() {
860
+ let { id: e } = ke(), t = Oe(), n = De().search, [r, i] = O(!1), [ee, c] = O(!1), [ne, u] = O(!1), [d, f] = O(!1), [p, m] = O(""), [h, re] = O(!1), [ie, ae] = O(null), { data: oe, loading: se, error: v } = g({
824
861
  variables: { id: e },
825
862
  skip: !e
826
- }), y = g?.jobApplication?.productId ?? null;
827
- se(() => {
863
+ }), y = oe?.jobApplication?.productId ?? null;
864
+ he(() => {
828
865
  if (!y) {
829
- h(null);
866
+ ae(null);
830
867
  return;
831
868
  }
832
869
  let e = !1;
833
- return Te({
870
+ return Ae({
834
871
  gateway: "global",
835
872
  query: "query($id: ID!) { platformProduct(id: $id) { name } }",
836
873
  variables: { id: y }
837
874
  }).then((t) => {
838
875
  if (e) return;
839
876
  let n = t.data?.platformProduct?.name;
840
- n && h(n);
877
+ n && ae(n);
841
878
  }).catch(() => {}), () => {
842
879
  e = !0;
843
880
  };
844
881
  }, [y]);
845
- let [te, { loading: ne }] = oe({ refetchQueries: ["GetJobApplication", "GetJobApplications"] }), [re, { loading: S }] = x({ fetchPolicy: "no-cache" }), [ie, { loading: C }] = w(), T = g?.jobApplication, ae = async () => {
846
- if (!(!u.trim() || !e)) try {
847
- (await ie({ variables: {
882
+ let [le, { loading: b }] = pe({ refetchQueries: ["GetJobApplication", "GetJobApplications"] }), [ue, { loading: de }] = ce({ fetchPolicy: "no-cache" }), [fe, S] = O(!1), [C, w] = O(null), [T, D] = O(!1), [I, { loading: B }] = _({ fetchPolicy: "no-cache" }), [G, { loading: Se }] = x(), q = oe?.jobApplication, Ce = async () => {
883
+ if (!(!p.trim() || !e)) try {
884
+ (await G({ variables: {
848
885
  id: e,
849
- message: u.trim()
850
- } })).data?.replyToJobApplication.success && (p(!0), d(""), setTimeout(() => p(!1), 3e3));
886
+ message: p.trim()
887
+ } })).data?.replyToJobApplication.success && (re(!0), m(""), setTimeout(() => re(!1), 3e3));
851
888
  } catch (e) {
852
889
  console.error("Failed to send reply:", e);
853
890
  }
854
- }, E = async (t) => {
891
+ }, we = async (t) => {
855
892
  if (e) {
856
- a(!1);
893
+ c(!1);
857
894
  try {
858
- await te({ variables: {
895
+ await le({ variables: {
859
896
  id: e,
860
897
  input: { status: t }
861
898
  } }), i(!0), setTimeout(() => i(!1), 3e3);
862
899
  } catch (e) {
863
- console.error("Failed to update status:", e), a(!0), setTimeout(() => a(!1), 4e3);
900
+ console.error("Failed to update status:", e), c(!0), setTimeout(() => c(!1), 4e3);
901
+ }
902
+ }
903
+ }, Te = async () => {
904
+ if (e) {
905
+ f(!1);
906
+ try {
907
+ let t = (await ue({ variables: { id: e } })).data?.jobApplicationResumeUrl;
908
+ t ? window.open(t, "_blank", "noopener,noreferrer") : f(!0);
909
+ } catch (e) {
910
+ console.error("Failed to get resume URL:", e), f(!0);
864
911
  }
865
912
  }
866
- }, D = async () => {
913
+ }, Ee = async () => {
867
914
  if (e) {
868
- l(!1);
915
+ D(!1), w(null), S(!0);
869
916
  try {
870
- let t = (await re({ variables: { id: e } })).data?.jobApplicationResumeUrl;
871
- t ? window.open(t, "_blank", "noopener,noreferrer") : l(!0);
917
+ let t = (await I({ variables: { id: e } })).data?.jobApplicationResumePreviewUrl;
918
+ t ? w(t) : D(!0);
872
919
  } catch (e) {
873
- console.error("Failed to get resume URL:", e), l(!0);
920
+ console.error("Failed to get resume preview URL:", e), D(!0);
874
921
  }
875
922
  }
876
- }, O = async () => {
877
- T?.email && (M("light"), await j(T.email), s(!0), setTimeout(() => s(!1), 2e3));
923
+ }, Z = async () => {
924
+ q?.email && (E("light"), await me(q.email), u(!0), setTimeout(() => u(!1), 2e3));
878
925
  };
879
- if (_) return /* @__PURE__ */ Z("div", {
926
+ if (se) return /* @__PURE__ */ Y("div", {
880
927
  className: "min-h-full flex items-center justify-center py-20",
881
- children: /* @__PURE__ */ Q("div", {
928
+ children: /* @__PURE__ */ X("div", {
882
929
  className: "text-center",
883
- children: [/* @__PURE__ */ Z(Y, {
930
+ children: [/* @__PURE__ */ Y(U, {
884
931
  size: 36,
885
932
  className: "animate-spin text-[var(--color-text-secondary)] mx-auto mb-3"
886
- }), /* @__PURE__ */ Z("p", {
933
+ }), /* @__PURE__ */ Y("p", {
887
934
  className: "text-sm text-[var(--color-text-secondary)]",
888
935
  children: "Loading application details…"
889
936
  })]
890
937
  })
891
938
  });
892
- if (v || !T) return /* @__PURE__ */ Z("div", {
939
+ if (v || !q) return /* @__PURE__ */ Y("div", {
893
940
  className: "p-6",
894
- children: /* @__PURE__ */ Z(Oe, {
941
+ children: /* @__PURE__ */ Y(Ne, {
895
942
  illustration: "empty-search",
896
943
  title: "Application not found",
897
944
  description: v?.message || "This application may have been deleted or you don't have access.",
898
- action: /* @__PURE__ */ Q("button", {
945
+ action: /* @__PURE__ */ X("button", {
899
946
  type: "button",
900
947
  onClick: () => t(`/support/applications${n}`),
901
948
  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",
902
- children: [/* @__PURE__ */ Z(F, { size: 16 }), "Back to Applications"]
949
+ children: [/* @__PURE__ */ Y(A, { size: 16 }), "Back to Applications"]
903
950
  })
904
951
  })
905
952
  });
906
- let k = je[T.status] || je.NEW, A = k.icon, U = `${T.firstName} ${T.lastName}`.trim(), W = Fe(T.resumeFileSize), q = Le(T.linkedinUrl), de = Le(T.portfolioUrl);
907
- return /* @__PURE__ */ Q("div", {
953
+ let $ = Ie[q.status] || Ie.NEW, ze = $.icon, Ve = `${q.firstName} ${q.lastName}`.trim(), Ue = Re(q.resumeFileSize), We = Be(q.linkedinUrl), Ge = Be(q.portfolioUrl);
954
+ return /* @__PURE__ */ X("div", {
908
955
  className: "p-6 animate-in fade-in duration-200",
909
956
  children: [
910
- /* @__PURE__ */ Q("div", {
957
+ /* @__PURE__ */ X("div", {
911
958
  className: "flex items-center justify-between mb-6",
912
- children: [/* @__PURE__ */ Q("button", {
959
+ children: [/* @__PURE__ */ X("button", {
913
960
  type: "button",
914
961
  onClick: () => t(`/support/applications${n}`),
915
962
  className: "inline-flex items-center gap-2 text-[var(--color-text-secondary)] hover:text-[var(--color-text-primary)] transition-colors",
916
- children: [/* @__PURE__ */ Z(F, { size: 18 }), /* @__PURE__ */ Z("span", {
963
+ children: [/* @__PURE__ */ Y(A, { size: 18 }), /* @__PURE__ */ Y("span", {
917
964
  className: "text-sm font-medium",
918
965
  children: "Back to Applications"
919
966
  })]
920
- }), /* @__PURE__ */ Q("div", {
967
+ }), /* @__PURE__ */ X("div", {
921
968
  className: "flex items-center gap-2 text-xs text-[var(--color-text-secondary)]",
922
- children: [/* @__PURE__ */ Z(B, { size: 12 }), Pe(T.createdAt)]
969
+ children: [/* @__PURE__ */ Y(P, { size: 12 }), Le(q.createdAt)]
923
970
  })]
924
971
  }),
925
- r && /* @__PURE__ */ Q("div", {
972
+ r && /* @__PURE__ */ X("div", {
926
973
  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",
927
- children: [/* @__PURE__ */ Z(z, { size: 18 }), "Status updated successfully"]
974
+ children: [/* @__PURE__ */ Y(N, { size: 18 }), "Status updated successfully"]
928
975
  }),
929
- ee && /* @__PURE__ */ Q("div", {
976
+ ee && /* @__PURE__ */ X("div", {
930
977
  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",
931
- children: [/* @__PURE__ */ Z(ce, { size: 18 }), "Couldn't update the status. Please try again."]
978
+ children: [/* @__PURE__ */ Y(ge, { size: 18 }), "Couldn't update the status. Please try again."]
932
979
  }),
933
- /* @__PURE__ */ Z(Ae, {
980
+ /* @__PURE__ */ Y(Fe, {
934
981
  className: "mb-6",
935
982
  children: "A single candidate's full application — contact details, resume, cover letter and links. Review their background, download the resume, and move them through your hiring pipeline from new to screening, interview, hire or rejection. Reply by branded email to keep the candidate informed at every stage."
936
983
  }),
937
- /* @__PURE__ */ Z(ke, {
984
+ /* @__PURE__ */ Y(Pe, {
938
985
  storageKey: "support-application-detail",
939
986
  title: "Move this candidate forward",
940
987
  className: "mb-6",
941
988
  steps: [
942
- ...T.resumeFileName ? [{
989
+ ...q.resumeFileName ? [{
943
990
  id: "resume",
944
991
  label: "Review the resume",
945
992
  description: "Download and read the candidate's resume.",
946
- onClick: () => void D()
993
+ onClick: () => void Te()
947
994
  }] : [],
948
995
  {
949
996
  id: "advance",
@@ -965,37 +1012,37 @@ function Be() {
965
1012
  }
966
1013
  ]
967
1014
  }),
968
- /* @__PURE__ */ Z("div", {
969
- className: `rounded-xl border p-6 mb-6 ${k.bg}`,
970
- children: /* @__PURE__ */ Z("div", {
1015
+ /* @__PURE__ */ Y("div", {
1016
+ className: `rounded-xl border p-6 mb-6 ${$.bg}`,
1017
+ children: /* @__PURE__ */ Y("div", {
971
1018
  className: "flex items-start justify-between",
972
- children: /* @__PURE__ */ Q("div", {
1019
+ children: /* @__PURE__ */ X("div", {
973
1020
  className: "flex items-start gap-4",
974
- children: [/* @__PURE__ */ Z("div", {
1021
+ children: [/* @__PURE__ */ Y("div", {
975
1022
  className: "size-12 rounded-xl bg-bg-surface/80 dark:bg-bg-surface/10 flex items-center justify-center shadow-sm",
976
- children: /* @__PURE__ */ Z(A, {
1023
+ children: /* @__PURE__ */ Y(ze, {
977
1024
  size: 24,
978
- className: k.color
1025
+ className: $.color
979
1026
  })
980
- }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("div", {
1027
+ }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("div", {
981
1028
  className: "flex items-center gap-3 mb-1.5",
982
- children: /* @__PURE__ */ Z("h1", {
1029
+ children: /* @__PURE__ */ Y("h1", {
983
1030
  className: "text-xl font-bold text-[var(--color-text-primary)]",
984
- children: U
1031
+ children: Ve
985
1032
  })
986
- }), /* @__PURE__ */ Q("div", {
1033
+ }), /* @__PURE__ */ X("div", {
987
1034
  className: "flex items-center gap-3 text-sm flex-wrap",
988
- children: [/* @__PURE__ */ Q("span", {
989
- className: `inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full text-xs font-semibold ${k.color} bg-bg-surface/60 dark:bg-bg-surface/10`,
990
- children: [/* @__PURE__ */ Z(A, { size: 12 }), k.label]
991
- }), /* @__PURE__ */ Q("span", {
1035
+ children: [/* @__PURE__ */ X("span", {
1036
+ className: `inline-flex items-center gap-1.5 px-2.5 py-1 rounded-full text-xs font-semibold ${$.color} bg-bg-surface/60 dark:bg-bg-surface/10`,
1037
+ children: [/* @__PURE__ */ Y(ze, { size: 12 }), $.label]
1038
+ }), /* @__PURE__ */ X("span", {
992
1039
  className: "text-[var(--color-text-secondary)]",
993
1040
  children: [
994
1041
  "applying for",
995
1042
  " ",
996
- /* @__PURE__ */ Z("strong", {
1043
+ /* @__PURE__ */ Y("strong", {
997
1044
  className: "text-[var(--color-text-primary)]",
998
- children: T.position
1045
+ children: q.position
999
1046
  })
1000
1047
  ]
1001
1048
  })]
@@ -1003,68 +1050,68 @@ function Be() {
1003
1050
  })
1004
1051
  })
1005
1052
  }),
1006
- /* @__PURE__ */ Q("div", {
1053
+ /* @__PURE__ */ X("div", {
1007
1054
  className: "grid grid-cols-1 lg:grid-cols-3 gap-6",
1008
- children: [/* @__PURE__ */ Q("div", {
1055
+ children: [/* @__PURE__ */ X("div", {
1009
1056
  className: "lg:col-span-2 space-y-5",
1010
1057
  children: [
1011
- /* @__PURE__ */ Q("div", {
1058
+ /* @__PURE__ */ X("div", {
1012
1059
  className: "bg-[var(--color-bg-surface)] border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
1013
- children: [/* @__PURE__ */ Z("div", {
1060
+ children: [/* @__PURE__ */ Y("div", {
1014
1061
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1015
- children: /* @__PURE__ */ Q("h2", {
1062
+ children: /* @__PURE__ */ X("h2", {
1016
1063
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-2",
1017
- children: [/* @__PURE__ */ Z(_e, { size: 14 }), "Applicant Information"]
1064
+ children: [/* @__PURE__ */ Y(J, { size: 14 }), "Applicant Information"]
1018
1065
  })
1019
- }), /* @__PURE__ */ Z("div", {
1066
+ }), /* @__PURE__ */ Y("div", {
1020
1067
  className: "p-5",
1021
- children: /* @__PURE__ */ Q("div", {
1068
+ children: /* @__PURE__ */ X("div", {
1022
1069
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
1023
1070
  children: [
1024
- /* @__PURE__ */ Q("div", {
1071
+ /* @__PURE__ */ X("div", {
1025
1072
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1026
- children: [/* @__PURE__ */ Z("div", {
1073
+ children: [/* @__PURE__ */ Y("div", {
1027
1074
  className: "size-9 rounded-lg bg-status-info-bg-subtle flex items-center justify-center",
1028
- children: /* @__PURE__ */ Z(_e, {
1075
+ children: /* @__PURE__ */ Y(J, {
1029
1076
  size: 16,
1030
1077
  className: "text-accent-blue"
1031
1078
  })
1032
- }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1079
+ }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1033
1080
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1034
1081
  children: "Name"
1035
- }), /* @__PURE__ */ Z("p", {
1082
+ }), /* @__PURE__ */ Y("p", {
1036
1083
  className: "text-sm font-semibold text-[var(--color-text-primary)]",
1037
- children: U
1084
+ children: Ve
1038
1085
  })] })]
1039
1086
  }),
1040
- /* @__PURE__ */ Q("div", {
1087
+ /* @__PURE__ */ X("div", {
1041
1088
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1042
- children: [/* @__PURE__ */ Z("div", {
1089
+ children: [/* @__PURE__ */ Y("div", {
1043
1090
  className: "size-9 rounded-lg bg-accent-indigo-subtle flex items-center justify-center",
1044
- children: /* @__PURE__ */ Z(X, {
1091
+ children: /* @__PURE__ */ Y(W, {
1045
1092
  size: 16,
1046
1093
  className: "text-accent-indigo"
1047
1094
  })
1048
- }), /* @__PURE__ */ Q("div", {
1095
+ }), /* @__PURE__ */ X("div", {
1049
1096
  className: "flex-1 min-w-0",
1050
- children: [/* @__PURE__ */ Z("p", {
1097
+ children: [/* @__PURE__ */ Y("p", {
1051
1098
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1052
1099
  children: "Email"
1053
- }), /* @__PURE__ */ Q("div", {
1100
+ }), /* @__PURE__ */ X("div", {
1054
1101
  className: "flex items-center gap-1.5",
1055
- children: [/* @__PURE__ */ Z("a", {
1056
- href: `mailto:${T.email}`,
1102
+ children: [/* @__PURE__ */ Y("a", {
1103
+ href: `mailto:${q.email}`,
1057
1104
  className: "text-sm font-semibold text-[var(--color-text-link)] hover:underline truncate",
1058
- children: T.email
1059
- }), /* @__PURE__ */ Z("button", {
1105
+ children: q.email
1106
+ }), /* @__PURE__ */ Y("button", {
1060
1107
  type: "button",
1061
- onClick: O,
1108
+ onClick: Z,
1062
1109
  className: "flex-shrink-0 p-0.5 rounded hover:bg-[var(--color-bg-muted)] transition-colors",
1063
1110
  title: "Copy email",
1064
- children: o ? /* @__PURE__ */ Z(z, {
1111
+ children: ne ? /* @__PURE__ */ Y(N, {
1065
1112
  size: 12,
1066
1113
  className: "text-status-success-text"
1067
- }) : /* @__PURE__ */ Z(V, {
1114
+ }) : /* @__PURE__ */ Y(ve, {
1068
1115
  size: 12,
1069
1116
  className: "text-[var(--color-text-secondary)]"
1070
1117
  })
@@ -1072,176 +1119,179 @@ function Be() {
1072
1119
  })]
1073
1120
  })]
1074
1121
  }),
1075
- T.phone && /* @__PURE__ */ Q("div", {
1122
+ q.phone && /* @__PURE__ */ X("div", {
1076
1123
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1077
- children: [/* @__PURE__ */ Z("div", {
1124
+ children: [/* @__PURE__ */ Y("div", {
1078
1125
  className: "size-9 rounded-lg bg-status-success-bg-subtle flex items-center justify-center",
1079
- children: /* @__PURE__ */ Z(pe, {
1126
+ children: /* @__PURE__ */ Y(xe, {
1080
1127
  size: 16,
1081
1128
  className: "text-status-success-text"
1082
1129
  })
1083
- }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1130
+ }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1084
1131
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1085
1132
  children: "Phone"
1086
- }), /* @__PURE__ */ Z("a", {
1087
- href: `tel:${T.phone}`,
1133
+ }), /* @__PURE__ */ Y("a", {
1134
+ href: `tel:${q.phone}`,
1088
1135
  className: "text-sm font-semibold text-[var(--color-text-primary)] hover:underline",
1089
- children: T.phone
1136
+ children: q.phone
1090
1137
  })] })]
1091
1138
  }),
1092
- /* @__PURE__ */ Q("div", {
1139
+ /* @__PURE__ */ X("div", {
1093
1140
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1094
- children: [/* @__PURE__ */ Z("div", {
1141
+ children: [/* @__PURE__ */ Y("div", {
1095
1142
  className: "size-9 rounded-lg bg-accent-blue-subtle flex items-center justify-center",
1096
- children: /* @__PURE__ */ Z(I, {
1143
+ children: /* @__PURE__ */ Y(j, {
1097
1144
  size: 16,
1098
1145
  className: "text-accent-blue"
1099
1146
  })
1100
- }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1147
+ }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1101
1148
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1102
1149
  children: "Position"
1103
- }), /* @__PURE__ */ Z("p", {
1150
+ }), /* @__PURE__ */ Y("p", {
1104
1151
  className: "text-sm font-semibold text-[var(--color-text-primary)]",
1105
- children: T.position
1152
+ children: q.position
1106
1153
  })] })]
1107
1154
  }),
1108
- T.department && /* @__PURE__ */ Q("div", {
1155
+ q.department && /* @__PURE__ */ X("div", {
1109
1156
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1110
- children: [/* @__PURE__ */ Z("div", {
1157
+ children: [/* @__PURE__ */ Y("div", {
1111
1158
  className: "size-9 rounded-lg bg-accent-purple-subtle flex items-center justify-center",
1112
- children: /* @__PURE__ */ Z(L, {
1159
+ children: /* @__PURE__ */ Y(M, {
1113
1160
  size: 16,
1114
1161
  className: "text-accent-purple"
1115
1162
  })
1116
- }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1163
+ }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1117
1164
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1118
1165
  children: "Department"
1119
- }), /* @__PURE__ */ Z("p", {
1166
+ }), /* @__PURE__ */ Y("p", {
1120
1167
  className: "text-sm font-semibold text-[var(--color-text-primary)]",
1121
- children: T.department
1168
+ children: q.department
1122
1169
  })] })]
1123
1170
  }),
1124
- T.linkedinUrl && /* @__PURE__ */ Q("div", {
1171
+ q.linkedinUrl && /* @__PURE__ */ X("div", {
1125
1172
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1126
- children: [/* @__PURE__ */ Z("div", {
1173
+ children: [/* @__PURE__ */ Y("div", {
1127
1174
  className: "size-9 rounded-lg bg-status-info-bg-subtle flex items-center justify-center",
1128
- children: /* @__PURE__ */ Z(ue, {
1175
+ children: /* @__PURE__ */ Y(H, {
1129
1176
  size: 16,
1130
1177
  className: "text-accent-blue"
1131
1178
  })
1132
- }), /* @__PURE__ */ Q("div", {
1179
+ }), /* @__PURE__ */ X("div", {
1133
1180
  className: "flex-1 min-w-0",
1134
- children: [/* @__PURE__ */ Z("p", {
1181
+ children: [/* @__PURE__ */ Y("p", {
1135
1182
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1136
1183
  children: "LinkedIn"
1137
- }), q ? /* @__PURE__ */ Z("a", {
1138
- href: q,
1184
+ }), We ? /* @__PURE__ */ Y("a", {
1185
+ href: We,
1139
1186
  target: "_blank",
1140
1187
  rel: "noopener noreferrer",
1141
1188
  className: "text-sm font-semibold text-[var(--color-text-link)] hover:underline truncate block",
1142
- children: T.linkedinUrl
1143
- }) : /* @__PURE__ */ Z("span", {
1189
+ children: q.linkedinUrl
1190
+ }) : /* @__PURE__ */ Y("span", {
1144
1191
  className: "text-sm font-semibold text-[var(--color-text-primary)] truncate block",
1145
- children: T.linkedinUrl
1192
+ children: q.linkedinUrl
1146
1193
  })]
1147
1194
  })]
1148
1195
  }),
1149
- T.portfolioUrl && /* @__PURE__ */ Q("div", {
1196
+ q.portfolioUrl && /* @__PURE__ */ X("div", {
1150
1197
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1151
- children: [/* @__PURE__ */ Z("div", {
1198
+ children: [/* @__PURE__ */ Y("div", {
1152
1199
  className: "size-9 rounded-lg bg-accent-indigo-subtle flex items-center justify-center",
1153
- children: /* @__PURE__ */ Z(J, {
1200
+ children: /* @__PURE__ */ Y(V, {
1154
1201
  size: 16,
1155
1202
  className: "text-accent-indigo"
1156
1203
  })
1157
- }), /* @__PURE__ */ Q("div", {
1204
+ }), /* @__PURE__ */ X("div", {
1158
1205
  className: "flex-1 min-w-0",
1159
- children: [/* @__PURE__ */ Z("p", {
1206
+ children: [/* @__PURE__ */ Y("p", {
1160
1207
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1161
1208
  children: "Portfolio"
1162
- }), de ? /* @__PURE__ */ Z("a", {
1163
- href: de,
1209
+ }), Ge ? /* @__PURE__ */ Y("a", {
1210
+ href: Ge,
1164
1211
  target: "_blank",
1165
1212
  rel: "noopener noreferrer",
1166
1213
  className: "text-sm font-semibold text-[var(--color-text-link)] hover:underline truncate block",
1167
- children: T.portfolioUrl
1168
- }) : /* @__PURE__ */ Z("span", {
1214
+ children: q.portfolioUrl
1215
+ }) : /* @__PURE__ */ Y("span", {
1169
1216
  className: "text-sm font-semibold text-[var(--color-text-primary)] truncate block",
1170
- children: T.portfolioUrl
1217
+ children: q.portfolioUrl
1171
1218
  })]
1172
1219
  })]
1173
1220
  }),
1174
- T.productId && m && /* @__PURE__ */ Q("div", {
1221
+ q.productId && ie && /* @__PURE__ */ X("div", {
1175
1222
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1176
- children: [/* @__PURE__ */ Z("div", {
1223
+ children: [/* @__PURE__ */ Y("div", {
1177
1224
  className: "size-9 rounded-lg bg-accent-purple-subtle flex items-center justify-center",
1178
- children: /* @__PURE__ */ Z(fe, {
1225
+ children: /* @__PURE__ */ Y(be, {
1179
1226
  size: 16,
1180
1227
  className: "text-accent-purple"
1181
1228
  })
1182
- }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1229
+ }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1183
1230
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1184
1231
  children: "Product"
1185
- }), /* @__PURE__ */ Z("p", {
1232
+ }), /* @__PURE__ */ Y("p", {
1186
1233
  className: "text-sm font-semibold text-[var(--color-text-primary)]",
1187
- children: m
1234
+ children: ie
1188
1235
  })] })]
1189
1236
  }),
1190
- /* @__PURE__ */ Q("div", {
1237
+ /* @__PURE__ */ X("div", {
1191
1238
  className: "flex items-center gap-3 p-3 rounded-lg bg-[var(--color-bg-muted)]/30",
1192
- children: [/* @__PURE__ */ Z("div", {
1239
+ children: [/* @__PURE__ */ Y("div", {
1193
1240
  className: "size-9 rounded-lg bg-status-success-bg-subtle flex items-center justify-center",
1194
- children: /* @__PURE__ */ Z(K, {
1241
+ children: /* @__PURE__ */ Y(z, {
1195
1242
  size: 16,
1196
1243
  className: "text-status-success-text"
1197
1244
  })
1198
- }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1245
+ }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1199
1246
  className: "text-[10px] font-medium text-[var(--color-text-secondary)] uppercase tracking-wider",
1200
1247
  children: "Source"
1201
- }), /* @__PURE__ */ Z("p", {
1248
+ }), /* @__PURE__ */ Y("p", {
1202
1249
  className: "text-sm font-semibold text-[var(--color-text-primary)] capitalize",
1203
- children: T.source.toLowerCase()
1250
+ children: q.source.toLowerCase()
1204
1251
  })] })]
1205
1252
  })
1206
1253
  ]
1207
1254
  })
1208
1255
  })]
1209
1256
  }),
1210
- e && /* @__PURE__ */ Z(ze, { applicationId: e }),
1211
- T.coverLetter && /* @__PURE__ */ Q("div", {
1257
+ e && /* @__PURE__ */ Y(He, {
1258
+ applicationId: e,
1259
+ jobPostingId: oe.jobApplication.jobPostingId
1260
+ }),
1261
+ q.coverLetter && /* @__PURE__ */ X("div", {
1212
1262
  className: "bg-[var(--color-bg-surface)] border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
1213
- children: [/* @__PURE__ */ Z("div", {
1263
+ children: [/* @__PURE__ */ Y("div", {
1214
1264
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1215
- children: /* @__PURE__ */ Q("h2", {
1265
+ children: /* @__PURE__ */ X("h2", {
1216
1266
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-2",
1217
- children: [/* @__PURE__ */ Z(G, { size: 14 }), "Cover Letter"]
1267
+ children: [/* @__PURE__ */ Y(R, { size: 14 }), "Cover Letter"]
1218
1268
  })
1219
- }), /* @__PURE__ */ Z("div", {
1269
+ }), /* @__PURE__ */ Y("div", {
1220
1270
  className: "p-5",
1221
- children: /* @__PURE__ */ Z("p", {
1271
+ children: /* @__PURE__ */ Y("p", {
1222
1272
  className: "text-sm text-[var(--color-text-primary)] leading-relaxed whitespace-pre-wrap",
1223
- children: T.coverLetter
1273
+ children: q.coverLetter
1224
1274
  })
1225
1275
  })]
1226
1276
  }),
1227
- T.metadata && Object.keys(T.metadata).length > 0 && /* @__PURE__ */ Q("div", {
1277
+ q.metadata && Object.keys(q.metadata).length > 0 && /* @__PURE__ */ X("div", {
1228
1278
  className: "bg-[var(--color-bg-surface)] border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
1229
- children: [/* @__PURE__ */ Z("div", {
1279
+ children: [/* @__PURE__ */ Y("div", {
1230
1280
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1231
- children: /* @__PURE__ */ Q("h2", {
1281
+ children: /* @__PURE__ */ X("h2", {
1232
1282
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-2",
1233
- children: [/* @__PURE__ */ Z(le, { size: 14 }), "Additional Data"]
1283
+ children: [/* @__PURE__ */ Y(ye, { size: 14 }), "Additional Data"]
1234
1284
  })
1235
- }), /* @__PURE__ */ Z("div", {
1285
+ }), /* @__PURE__ */ Y("div", {
1236
1286
  className: "p-5",
1237
- children: /* @__PURE__ */ Z("div", {
1287
+ children: /* @__PURE__ */ Y("div", {
1238
1288
  className: "space-y-2.5",
1239
- children: Object.entries(T.metadata).map(([e, t]) => /* @__PURE__ */ Q("div", {
1289
+ children: Object.entries(q.metadata).map(([e, t]) => /* @__PURE__ */ X("div", {
1240
1290
  className: "flex items-start gap-3 py-1.5 border-b border-[var(--color-border-default)] last:border-0",
1241
- children: [/* @__PURE__ */ Z("span", {
1291
+ children: [/* @__PURE__ */ Y("span", {
1242
1292
  className: "text-xs font-medium text-[var(--color-text-secondary)] min-w-[120px] uppercase tracking-wider",
1243
1293
  children: e
1244
- }), /* @__PURE__ */ Z("span", {
1294
+ }), /* @__PURE__ */ Y("span", {
1245
1295
  className: "text-xs text-[var(--color-text-primary)] font-mono break-all",
1246
1296
  children: typeof t == "object" && t ? JSON.stringify(t) : String(t)
1247
1297
  })]
@@ -1250,202 +1300,245 @@ function Be() {
1250
1300
  })]
1251
1301
  })
1252
1302
  ]
1253
- }), /* @__PURE__ */ Q("div", {
1303
+ }), /* @__PURE__ */ X("div", {
1254
1304
  className: "space-y-5",
1255
1305
  children: [
1256
- /* @__PURE__ */ Q("div", {
1306
+ /* @__PURE__ */ X("div", {
1257
1307
  className: "bg-[var(--color-bg-surface)] border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
1258
- children: [/* @__PURE__ */ Z("div", {
1308
+ children: [/* @__PURE__ */ Y("div", {
1259
1309
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1260
- children: /* @__PURE__ */ Q("h2", {
1310
+ children: /* @__PURE__ */ X("h2", {
1261
1311
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-2",
1262
- children: [/* @__PURE__ */ Z(G, { size: 14 }), "Resume"]
1312
+ children: [/* @__PURE__ */ Y(R, { size: 14 }), "Resume"]
1263
1313
  })
1264
- }), /* @__PURE__ */ Z("div", {
1314
+ }), /* @__PURE__ */ Y("div", {
1265
1315
  className: "p-5",
1266
- children: T.resumeFileName ? /* @__PURE__ */ Q(Ee, { children: [
1267
- /* @__PURE__ */ Q("div", {
1316
+ children: q.resumeFileName ? /* @__PURE__ */ X(je, { children: [
1317
+ /* @__PURE__ */ X("div", {
1268
1318
  className: "flex items-center gap-3 mb-3",
1269
- children: [/* @__PURE__ */ Z("div", {
1319
+ children: [/* @__PURE__ */ Y("div", {
1270
1320
  className: "size-9 rounded-lg bg-accent-blue-subtle flex items-center justify-center flex-shrink-0",
1271
- children: /* @__PURE__ */ Z(G, {
1321
+ children: /* @__PURE__ */ Y(R, {
1272
1322
  size: 16,
1273
1323
  className: "text-accent-blue"
1274
1324
  })
1275
- }), /* @__PURE__ */ Q("div", {
1325
+ }), /* @__PURE__ */ X("div", {
1276
1326
  className: "min-w-0",
1277
- children: [/* @__PURE__ */ Z("p", {
1327
+ children: [/* @__PURE__ */ Y("p", {
1278
1328
  className: "text-sm font-medium text-[var(--color-text-primary)] truncate",
1279
- children: T.resumeFileName
1280
- }), W ? /* @__PURE__ */ Z("p", {
1329
+ children: q.resumeFileName
1330
+ }), Ue ? /* @__PURE__ */ Y("p", {
1281
1331
  className: "text-[11px] text-[var(--color-text-secondary)]",
1282
- children: W
1332
+ children: Ue
1283
1333
  }) : null]
1284
1334
  })]
1285
1335
  }),
1286
- /* @__PURE__ */ Q("button", {
1336
+ /* @__PURE__ */ X("button", {
1287
1337
  type: "button",
1288
- onClick: D,
1289
- disabled: S,
1338
+ onClick: Te,
1339
+ disabled: de,
1290
1340
  className: "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",
1291
- children: [S ? /* @__PURE__ */ Z(Y, {
1341
+ children: [de ? /* @__PURE__ */ Y(U, {
1292
1342
  size: 15,
1293
1343
  className: "animate-spin"
1294
- }) : /* @__PURE__ */ Z(H, { size: 15 }), "Download Resume"]
1344
+ }) : /* @__PURE__ */ Y(F, { size: 15 }), "Download Resume"]
1295
1345
  }),
1296
- c && /* @__PURE__ */ Z("p", {
1346
+ /* @__PURE__ */ X("button", {
1347
+ type: "button",
1348
+ onClick: Ee,
1349
+ disabled: B,
1350
+ className: "mt-2 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-primary)] rounded-lg text-sm font-medium hover:bg-[var(--color-bg-muted)] transition-all disabled:opacity-50",
1351
+ children: [B ? /* @__PURE__ */ Y(U, {
1352
+ size: 15,
1353
+ className: "animate-spin"
1354
+ }) : /* @__PURE__ */ Y(L, { size: 15 }), "Preview Resume"]
1355
+ }),
1356
+ d && /* @__PURE__ */ Y("p", {
1297
1357
  className: "mt-2 text-xs text-status-error-text",
1298
1358
  children: "Could not generate a download link. Please try again."
1299
1359
  })
1300
- ] }) : /* @__PURE__ */ Z("p", {
1360
+ ] }) : /* @__PURE__ */ Y("p", {
1301
1361
  className: "text-sm text-[var(--color-text-secondary)]",
1302
1362
  children: "No resume on file."
1303
1363
  })
1304
1364
  })]
1305
1365
  }),
1306
- /* @__PURE__ */ Q("div", {
1366
+ /* @__PURE__ */ X("div", {
1307
1367
  className: "bg-[var(--color-bg-surface)] border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
1308
- children: [/* @__PURE__ */ Z("div", {
1368
+ children: [/* @__PURE__ */ Y("div", {
1309
1369
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1310
- children: /* @__PURE__ */ Q("h2", {
1370
+ children: /* @__PURE__ */ X("h2", {
1311
1371
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-2",
1312
- children: [/* @__PURE__ */ Z(R, { size: 14 }), "Timeline"]
1372
+ children: [/* @__PURE__ */ Y(_e, { size: 14 }), "Timeline"]
1313
1373
  })
1314
- }), /* @__PURE__ */ Q("div", {
1374
+ }), /* @__PURE__ */ X("div", {
1315
1375
  className: "p-5 space-y-4",
1316
- children: [/* @__PURE__ */ Q("div", {
1376
+ children: [/* @__PURE__ */ X("div", {
1317
1377
  className: "flex items-start gap-3",
1318
- children: [/* @__PURE__ */ Z("div", { className: "size-2 rounded-full bg-accent-blue mt-1.5 flex-shrink-0" }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1378
+ children: [/* @__PURE__ */ Y("div", { className: "size-2 rounded-full bg-accent-blue mt-1.5 flex-shrink-0" }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1319
1379
  className: "text-xs font-medium text-[var(--color-text-primary)]",
1320
1380
  children: "Applied"
1321
- }), /* @__PURE__ */ Z("p", {
1381
+ }), /* @__PURE__ */ Y("p", {
1322
1382
  className: "text-[11px] text-[var(--color-text-secondary)]",
1323
- children: Ne(T.createdAt)
1383
+ children: Q(q.createdAt)
1324
1384
  })] })]
1325
- }), T.updatedAt !== T.createdAt && /* @__PURE__ */ Q("div", {
1385
+ }), q.updatedAt !== q.createdAt && /* @__PURE__ */ X("div", {
1326
1386
  className: "flex items-start gap-3",
1327
- children: [/* @__PURE__ */ Z("div", { className: "size-2 rounded-full bg-status-warning-bg mt-1.5 flex-shrink-0" }), /* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("p", {
1387
+ children: [/* @__PURE__ */ Y("div", { className: "size-2 rounded-full bg-status-warning-bg mt-1.5 flex-shrink-0" }), /* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("p", {
1328
1388
  className: "text-xs font-medium text-[var(--color-text-primary)]",
1329
1389
  children: "Last Updated"
1330
- }), /* @__PURE__ */ Z("p", {
1390
+ }), /* @__PURE__ */ Y("p", {
1331
1391
  className: "text-[11px] text-[var(--color-text-secondary)]",
1332
- children: Ne(T.updatedAt)
1392
+ children: Q(q.updatedAt)
1333
1393
  })] })]
1334
1394
  })]
1335
1395
  })]
1336
1396
  }),
1337
- /* @__PURE__ */ Q(De, {
1397
+ /* @__PURE__ */ X(Me, {
1338
1398
  "data-tour": "support-application-reply",
1339
1399
  className: "overflow-hidden p-0",
1340
- children: [/* @__PURE__ */ Z("div", {
1400
+ children: [/* @__PURE__ */ Y("div", {
1341
1401
  className: "px-5 py-3.5 border-b border-border-seam",
1342
- children: /* @__PURE__ */ Q("h2", {
1402
+ children: /* @__PURE__ */ X("h2", {
1343
1403
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider flex items-center gap-1.5",
1344
- children: [/* @__PURE__ */ Z(he, { size: 12 }), "Reply"]
1404
+ children: [/* @__PURE__ */ Y(K, { size: 12 }), "Reply"]
1345
1405
  })
1346
- }), /* @__PURE__ */ Q("div", {
1406
+ }), /* @__PURE__ */ X("div", {
1347
1407
  className: "p-5",
1348
1408
  children: [
1349
- f && /* @__PURE__ */ Q("div", {
1409
+ h && /* @__PURE__ */ X("div", {
1350
1410
  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",
1351
- children: [/* @__PURE__ */ Z(z, { size: 14 }), "Reply sent to the applicant!"]
1411
+ children: [/* @__PURE__ */ Y(N, { size: 14 }), "Reply sent to the applicant!"]
1352
1412
  }),
1353
- /* @__PURE__ */ Z("textarea", {
1413
+ /* @__PURE__ */ Y("textarea", {
1354
1414
  "aria-label": "Reply message",
1355
- value: u,
1356
- onChange: (e) => d(e.target.value),
1415
+ value: p,
1416
+ onChange: (e) => m(e.target.value),
1357
1417
  placeholder: "Type your reply… This will be sent as a branded email to the applicant.",
1358
1418
  rows: 4,
1359
- disabled: C,
1419
+ disabled: Se,
1360
1420
  className: "w-full px-3 py-2.5 bg-[var(--color-bg-surface)] border border-[var(--color-border-default)] rounded-lg text-sm text-[var(--color-text-primary)] placeholder:text-[var(--color-text-secondary)] focus:outline-none focus:ring-2 focus:ring-[var(--color-border-accent)]/50 disabled:opacity-50 resize-none transition-all"
1361
1421
  }),
1362
- /* @__PURE__ */ Q("button", {
1422
+ /* @__PURE__ */ X("button", {
1363
1423
  type: "button",
1364
- onClick: ae,
1365
- disabled: C || !u.trim(),
1424
+ onClick: Ce,
1425
+ disabled: Se || !p.trim(),
1366
1426
  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",
1367
- children: [C ? /* @__PURE__ */ Z(Y, {
1427
+ children: [Se ? /* @__PURE__ */ Y(U, {
1368
1428
  size: 15,
1369
1429
  className: "animate-spin"
1370
- }) : /* @__PURE__ */ Z(he, { size: 15 }), "Send Reply"]
1430
+ }) : /* @__PURE__ */ Y(K, { size: 15 }), "Send Reply"]
1371
1431
  })
1372
1432
  ]
1373
1433
  })]
1374
1434
  }),
1375
- /* @__PURE__ */ Q("div", {
1435
+ /* @__PURE__ */ X("div", {
1376
1436
  "data-tour": "support-application-actions",
1377
1437
  className: "bg-[var(--color-bg-surface)] border border-border-seam rounded-xl overflow-hidden shadow-[var(--shadow-pop)]",
1378
- children: [/* @__PURE__ */ Z("div", {
1438
+ children: [/* @__PURE__ */ Y("div", {
1379
1439
  className: "px-5 py-3.5 border-b border-[var(--color-border-default)] bg-[var(--color-bg-muted)]/50",
1380
- children: /* @__PURE__ */ Z("h2", {
1440
+ children: /* @__PURE__ */ Y("h2", {
1381
1441
  className: "text-xs font-semibold text-[var(--color-text-secondary)] uppercase tracking-wider",
1382
1442
  children: "Actions"
1383
1443
  })
1384
- }), /* @__PURE__ */ Q("div", {
1444
+ }), /* @__PURE__ */ X("div", {
1385
1445
  className: "p-5 space-y-4",
1386
- children: [/* @__PURE__ */ Q("div", { children: [/* @__PURE__ */ Z("label", {
1446
+ children: [/* @__PURE__ */ X("div", { children: [/* @__PURE__ */ Y("label", {
1387
1447
  className: "block text-xs font-medium text-[var(--color-text-secondary)] mb-1.5",
1388
1448
  htmlFor: "jobapplicationdetailpage-status-0",
1389
1449
  children: "Status"
1390
- }), /* @__PURE__ */ Q("select", {
1450
+ }), /* @__PURE__ */ X("select", {
1391
1451
  id: "jobapplicationdetailpage-status-0",
1392
- value: T.status,
1393
- onChange: (e) => E(e.target.value),
1394
- disabled: ne,
1452
+ value: q.status,
1453
+ onChange: (e) => we(e.target.value),
1454
+ disabled: b,
1395
1455
  className: "w-full px-3 py-2.5 bg-[var(--color-bg-surface)] border border-[var(--color-border-default)] rounded-lg text-sm text-[var(--color-text-primary)] focus:outline-none focus:ring-2 focus:ring-[var(--color-border-accent)]/50 disabled:opacity-50 transition-all",
1396
1456
  children: [
1397
- /* @__PURE__ */ Z("option", {
1457
+ /* @__PURE__ */ Y("option", {
1398
1458
  value: "NEW",
1399
1459
  children: "New"
1400
1460
  }),
1401
- /* @__PURE__ */ Z("option", {
1461
+ /* @__PURE__ */ Y("option", {
1402
1462
  value: "SCREENING",
1403
1463
  children: "Screening"
1404
1464
  }),
1405
- /* @__PURE__ */ Z("option", {
1465
+ /* @__PURE__ */ Y("option", {
1406
1466
  value: "SHORTLISTED",
1407
1467
  children: "Shortlisted"
1408
1468
  }),
1409
- /* @__PURE__ */ Z("option", {
1469
+ /* @__PURE__ */ Y("option", {
1410
1470
  value: "INTERVIEW",
1411
1471
  children: "Interview"
1412
1472
  }),
1413
- /* @__PURE__ */ Z("option", {
1473
+ /* @__PURE__ */ Y("option", {
1414
1474
  value: "HIRED",
1415
1475
  children: "Hired"
1416
1476
  }),
1417
- /* @__PURE__ */ Z("option", {
1477
+ /* @__PURE__ */ Y("option", {
1418
1478
  value: "REJECTED",
1419
1479
  children: "Rejected"
1420
1480
  }),
1421
- /* @__PURE__ */ Z("option", {
1481
+ /* @__PURE__ */ Y("option", {
1422
1482
  value: "ARCHIVED",
1423
1483
  children: "Archived"
1424
1484
  })
1425
1485
  ]
1426
- })] }), /* @__PURE__ */ Q("div", {
1486
+ })] }), /* @__PURE__ */ X("div", {
1427
1487
  className: "space-y-2",
1428
- children: [/* @__PURE__ */ Q("a", {
1429
- href: `mailto:${T.email}?subject=${encodeURIComponent(`Your application for ${T.position}`)}`,
1488
+ children: [/* @__PURE__ */ X("a", {
1489
+ href: `mailto:${q.email}?subject=${encodeURIComponent(`Your application for ${q.position}`)}`,
1430
1490
  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-primary)] rounded-lg text-sm font-medium hover:bg-[var(--color-bg-muted)] transition-all",
1431
- children: [/* @__PURE__ */ Z(X, { size: 15 }), "Email Applicant"]
1432
- }), T.status !== "ARCHIVED" && /* @__PURE__ */ Q("button", {
1491
+ children: [/* @__PURE__ */ Y(W, { size: 15 }), "Email Applicant"]
1492
+ }), q.status !== "ARCHIVED" && /* @__PURE__ */ X("button", {
1433
1493
  type: "button",
1434
- onClick: () => E("ARCHIVED"),
1435
- disabled: ne,
1494
+ onClick: () => we("ARCHIVED"),
1495
+ disabled: b,
1436
1496
  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",
1437
- children: [/* @__PURE__ */ Z(P, { size: 15 }), "Archive"]
1497
+ children: [/* @__PURE__ */ Y(k, { size: 15 }), "Archive"]
1438
1498
  })]
1439
1499
  })]
1440
1500
  })]
1441
1501
  })
1442
1502
  ]
1443
1503
  })]
1504
+ }),
1505
+ /* @__PURE__ */ Y(a, {
1506
+ open: fe,
1507
+ onOpenChange: S,
1508
+ children: /* @__PURE__ */ X(o, {
1509
+ className: "sm:max-w-4xl",
1510
+ children: [/* @__PURE__ */ X(l, { children: [/* @__PURE__ */ Y(te, { children: "Resume Preview" }), /* @__PURE__ */ Y(s, { children: q.resumeFileName ?? "Candidate resume" })] }), /* @__PURE__ */ Y("div", {
1511
+ className: "h-[70vh] w-full rounded-lg border border-border-seam bg-bg-sunken/30 overflow-hidden",
1512
+ children: B ? /* @__PURE__ */ X("div", {
1513
+ className: "h-full flex flex-col items-center justify-center gap-3",
1514
+ children: [/* @__PURE__ */ Y(U, {
1515
+ size: 28,
1516
+ className: "animate-spin text-text-secondary"
1517
+ }), /* @__PURE__ */ Y("p", {
1518
+ className: "text-sm text-text-secondary",
1519
+ children: "Loading preview…"
1520
+ })]
1521
+ }) : T || !C ? /* @__PURE__ */ X("div", {
1522
+ className: "h-full flex flex-col items-center justify-center gap-3",
1523
+ children: [/* @__PURE__ */ Y(ge, {
1524
+ size: 28,
1525
+ className: "text-status-error-text"
1526
+ }), /* @__PURE__ */ Y("p", {
1527
+ className: "text-sm text-status-error-text",
1528
+ children: "Could not load the resume preview. Try downloading instead."
1529
+ })]
1530
+ }) : /* @__PURE__ */ Y("iframe", {
1531
+ src: C,
1532
+ title: `Resume preview — ${Ve}`,
1533
+ className: "h-full w-full"
1534
+ })
1535
+ })]
1536
+ })
1444
1537
  })
1445
1538
  ]
1446
1539
  });
1447
1540
  }
1448
1541
  //#endregion
1449
- export { Be as JobApplicationDetailPage };
1542
+ export { Ue as JobApplicationDetailPage };
1450
1543
 
1451
1544
  //# sourceMappingURL=JobApplicationDetailPage.js.map