@burdenoff/microfe-support 2026.802.1 → 2026.817.2

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,12 +1,22 @@
1
- import { useGetJobApplicationsQuery as e } from "../../generated/global-operations.js";
2
- import { useEffect as t, useRef as n, useState as r } from "react";
3
- import { AlertCircle as i, Briefcase as a, ChevronDown as o, Filter as s, Loader2 as c, Paperclip as l, Search as u } from "lucide-react";
4
- import { useLocation as d, useNavigate as f } from "react-router";
5
- import { graphqlFetch as p } from "@burdenoff/fe-libs/shared/graphql/fetch";
6
- import { Fragment as m, jsx as h, jsxs as g } from "react/jsx-runtime";
7
- import { IllustratedEmptyState as _, PagePurpose as v } from "@burdenoff/fe-libs/ui";
1
+ import { Badge as e, Button as t, Input as n } from "../components/ui.js";
2
+ import { useGetJobApplicationsQuery as r, useGetJobPostingsQuery as i } from "../../generated/global-operations.js";
3
+ import { JobApplicationStatus as a } from "../../generated/global-types.js";
4
+ import { useEffect as o, useRef as s, useState as c } from "react";
5
+ import { AlertCircle as l, Briefcase as u, ChevronDown as d, Filter as ee, Grid as te, List as f, Loader2 as p, Paperclip as m, Search as h } from "lucide-react";
6
+ import { useLocation as g, useNavigate as _ } from "react-router";
7
+ import { graphqlFetch as v } from "@burdenoff/fe-libs/shared/graphql/fetch";
8
+ import { Fragment as y, jsx as b, jsxs as x } from "react/jsx-runtime";
9
+ import { IllustratedEmptyState as ne, PagePurpose as re } from "@burdenoff/fe-libs/ui";
8
10
  //#region src/support/pages/JobApplicationsPage.tsx
9
- var y = {
11
+ var S = [
12
+ a.New,
13
+ a.Screening,
14
+ a.Shortlisted,
15
+ a.Interview,
16
+ a.Hired,
17
+ a.Rejected,
18
+ a.Archived
19
+ ], C = {
10
20
  NEW: "bg-status-info-bg-subtle text-status-info-text",
11
21
  SCREENING: "bg-status-warning-bg-subtle text-status-warning-text",
12
22
  SHORTLISTED: "bg-accent-purple-subtle text-accent-purple",
@@ -14,7 +24,7 @@ var y = {
14
24
  HIRED: "bg-status-success-bg-subtle text-status-success-text",
15
25
  REJECTED: "bg-status-error-bg-subtle text-status-error-text",
16
26
  ARCHIVED: "bg-bg-sunken text-text-secondary"
17
- }, b = {
27
+ }, w = {
18
28
  NEW: "New",
19
29
  SCREENING: "Screening",
20
30
  SHORTLISTED: "Shortlisted",
@@ -23,7 +33,7 @@ var y = {
23
33
  REJECTED: "Rejected",
24
34
  ARCHIVED: "Archived"
25
35
  };
26
- function x(e) {
36
+ function T(e) {
27
37
  return new Date(e).toLocaleDateString("en-US", {
28
38
  month: "short",
29
39
  day: "numeric",
@@ -32,289 +42,393 @@ function x(e) {
32
42
  minute: "2-digit"
33
43
  });
34
44
  }
35
- function S() {
36
- let S = f(), C = d().search, [w, T] = r(""), [E, D] = r(""), [O, k] = r(""), [A, j] = r(""), [M, N] = r(!1), [P, F] = r({}), I = n(P);
37
- I.current = P, t(() => {
38
- let e = setTimeout(() => D(w), 300);
45
+ function E(e) {
46
+ let t = Date.now() - new Date(e).getTime(), n = Math.floor(t / 6e4);
47
+ if (n < 2) return "just now";
48
+ if (n < 60) return `${n}m ago`;
49
+ let r = Math.floor(n / 60);
50
+ if (r < 24) return `${r}h ago`;
51
+ let i = Math.floor(r / 24);
52
+ return i < 30 ? `${i}d ago` : T(e);
53
+ }
54
+ function D() {
55
+ let a = _(), T = g().search, [D, O] = c(""), [k, ie] = c(""), [A, ae] = c(""), [j, M] = c(""), [N, P] = c(""), [F, I] = c(!1), [L, R] = c("list"), [z, B] = c({}), V = s(z);
56
+ V.current = z, o(() => {
57
+ let e = setTimeout(() => ie(D), 300);
39
58
  return () => clearTimeout(e);
40
- }, [w]);
41
- let L = {};
42
- E && (L.search = E), O && (L.status = O), A && (L.productId = A);
43
- let { data: R, loading: z, error: B, fetchMore: V } = e({
59
+ }, [D]);
60
+ let { data: H, loading: U, error: W, fetchMore: G } = r({
44
61
  variables: {
45
- filter: L,
62
+ filter: {
63
+ ...k ? { search: k } : {},
64
+ ...A ? { status: A } : {},
65
+ ...j ? { productId: j } : {},
66
+ ...N ? { jobPostingId: N } : {}
67
+ },
46
68
  limit: 50,
47
69
  offset: 0
48
70
  },
49
71
  fetchPolicy: "cache-and-network"
50
- }), H = R?.jobApplications?.items ?? [], U = R?.jobApplications?.total ?? 0, W = R?.jobApplications?.hasMore ?? !1, G = Array.from(new Set(H.flatMap((e) => e.productId ? [e.productId] : []))).sort(), K = G.join(",");
51
- return t(() => {
52
- let e = K ? K.split(",").filter((e) => !I.current[e]) : [];
72
+ }), { data: K, loading: q } = i({
73
+ variables: {
74
+ limit: 200,
75
+ offset: 0
76
+ },
77
+ fetchPolicy: "cache-and-network"
78
+ }), J = H?.jobApplications?.items ?? [], Y = H?.jobApplications?.total ?? 0, X = H?.jobApplications?.hasMore ?? !1, oe = (K?.jobPostings?.items ?? []).reduce((e, t) => (e[t.id] = t, e), {}), Z = Array.from(new Set(J.flatMap((e) => e.productId ? [e.productId] : []))).sort(), Q = Z.join(",");
79
+ o(() => {
80
+ let e = Q ? Q.split(",").filter((e) => !V.current[e]) : [];
53
81
  e.length !== 0 && e.forEach((e) => {
54
- p({
82
+ v({
55
83
  gateway: "global",
56
84
  query: "query($id: ID!) { platformProduct(id: $id) { name } }",
57
85
  variables: { id: e }
58
86
  }).then((t) => {
59
87
  let n = t.data?.platformProduct?.name;
60
- n && F((t) => ({
88
+ n && B((t) => ({
61
89
  ...t,
62
90
  [e]: n
63
91
  }));
64
92
  }).catch(() => {});
65
93
  });
66
- }, [K]), z && H.length === 0 ? /* @__PURE__ */ g("div", {
94
+ }, [Q]);
95
+ let se = () => {
96
+ X && G({
97
+ variables: { offset: J.length },
98
+ updateQuery: (e, { fetchMoreResult: t }) => t ? { jobApplications: {
99
+ ...t.jobApplications,
100
+ items: [...e.jobApplications?.items ?? [], ...t.jobApplications?.items ?? []]
101
+ } } : e
102
+ });
103
+ }, ce = S.reduce((e, t) => (e[t] = J.filter((e) => e.status === t), e), {}), $ = (t, n = !1) => {
104
+ let r = t.jobPostingId ? oe[t.jobPostingId]?.title : void 0;
105
+ return /* @__PURE__ */ b("button", {
106
+ type: "button",
107
+ onClick: () => a(`/support/applications/${t.id}${T}`),
108
+ className: `w-full text-left bg-bg-surface border border-border-seam rounded-lg shadow-[var(--shadow-pop)] hover:border-border-strong hover:shadow-[var(--shadow-pop-hover)] transition-[box-shadow,border-color] duration-200 group ${n ? "p-3" : "p-4"}`,
109
+ children: /* @__PURE__ */ x("div", {
110
+ className: `flex ${n ? "flex-col" : "items-start"} justify-between gap-3`,
111
+ children: [/* @__PURE__ */ x("div", {
112
+ className: "flex-1 min-w-0",
113
+ children: [
114
+ /* @__PURE__ */ x("div", {
115
+ className: "flex items-center gap-2 mb-1 flex-wrap",
116
+ children: [
117
+ /* @__PURE__ */ x("h3", {
118
+ className: "font-semibold text-text-primary truncate group-hover:text-accent transition-colors text-sm",
119
+ children: [
120
+ t.firstName,
121
+ " ",
122
+ t.lastName
123
+ ]
124
+ }),
125
+ /* @__PURE__ */ b(e, {
126
+ variant: "secondary",
127
+ className: `${C[t.status] || C.NEW} ${t.status === "NEW" ? "motion-safe:animate-vc-glow-pulse" : ""}`,
128
+ children: w[t.status] || t.status
129
+ }),
130
+ r && /* @__PURE__ */ b(e, {
131
+ variant: "outline",
132
+ title: `Job posting: ${r}`,
133
+ children: r
134
+ }),
135
+ t.productId && z[t.productId] && /* @__PURE__ */ b(e, {
136
+ variant: "secondary",
137
+ className: "bg-accent-purple-subtle text-accent-purple",
138
+ title: `Product: ${z[t.productId]}`,
139
+ children: z[t.productId]
140
+ }),
141
+ t.resumeFileName && /* @__PURE__ */ x(e, {
142
+ variant: "secondary",
143
+ className: "bg-accent-blue-subtle text-accent-blue gap-1",
144
+ children: [/* @__PURE__ */ b(m, { size: n ? 10 : 11 }), "Resume"]
145
+ })
146
+ ]
147
+ }),
148
+ /* @__PURE__ */ x("p", {
149
+ className: `text-text-secondary mb-1 ${n ? "text-xs" : "text-sm"}`,
150
+ children: [/* @__PURE__ */ b("span", {
151
+ className: "font-medium",
152
+ children: t.position
153
+ }), t.department && /* @__PURE__ */ x(y, { children: [/* @__PURE__ */ b("span", {
154
+ className: "mx-1.5 text-text-secondary/50",
155
+ children: "·"
156
+ }), /* @__PURE__ */ b("span", { children: t.department })] })]
157
+ }),
158
+ /* @__PURE__ */ b("p", {
159
+ className: `text-text-secondary truncate ${n ? "text-[11px]" : "text-xs"}`,
160
+ children: t.email
161
+ })
162
+ ]
163
+ }), /* @__PURE__ */ b("div", {
164
+ className: `text-text-secondary whitespace-nowrap ${n ? "text-[11px]" : "text-xs"}`,
165
+ children: E(t.createdAt)
166
+ })]
167
+ })
168
+ }, t.id);
169
+ };
170
+ return U && J.length === 0 ? /* @__PURE__ */ x("div", {
67
171
  className: "p-6",
68
- children: [/* @__PURE__ */ g("div", {
172
+ children: [/* @__PURE__ */ x("div", {
69
173
  className: "flex items-center gap-3 mb-6",
70
- children: [/* @__PURE__ */ h(a, {
174
+ children: [/* @__PURE__ */ b(u, {
71
175
  size: 24,
72
176
  className: "text-text-primary"
73
- }), /* @__PURE__ */ h("h1", {
177
+ }), /* @__PURE__ */ b("h1", {
74
178
  className: "text-2xl font-bold text-text-primary",
75
179
  children: "Job Applications"
76
180
  })]
77
- }), /* @__PURE__ */ g("div", {
181
+ }), /* @__PURE__ */ x("div", {
78
182
  className: "flex flex-col items-center justify-center py-16",
79
- children: [/* @__PURE__ */ h(c, {
183
+ children: [/* @__PURE__ */ b(p, {
80
184
  size: 32,
81
185
  className: "animate-spin text-text-secondary mb-4"
82
- }), /* @__PURE__ */ h("p", {
186
+ }), /* @__PURE__ */ b("p", {
83
187
  className: "text-sm text-text-secondary",
84
188
  children: "Loading applications…"
85
189
  })]
86
190
  })]
87
- }) : B ? /* @__PURE__ */ g("div", {
191
+ }) : W ? /* @__PURE__ */ x("div", {
88
192
  className: "p-6",
89
- children: [/* @__PURE__ */ g("div", {
193
+ children: [/* @__PURE__ */ x("div", {
90
194
  className: "flex items-center gap-3 mb-6",
91
- children: [/* @__PURE__ */ h(a, {
195
+ children: [/* @__PURE__ */ b(u, {
92
196
  size: 24,
93
197
  className: "text-text-primary"
94
- }), /* @__PURE__ */ h("h1", {
198
+ }), /* @__PURE__ */ b("h1", {
95
199
  className: "text-2xl font-bold text-text-primary",
96
200
  children: "Job Applications"
97
201
  })]
98
- }), /* @__PURE__ */ g("div", {
202
+ }), /* @__PURE__ */ x("div", {
99
203
  className: "flex flex-col items-center justify-center py-16 text-center",
100
204
  children: [
101
- /* @__PURE__ */ h("div", {
205
+ /* @__PURE__ */ b("div", {
102
206
  className: "p-4 rounded-2xl bg-status-error-bg-subtle text-status-error-text mb-4",
103
- children: /* @__PURE__ */ h(i, { size: 48 })
207
+ children: /* @__PURE__ */ b(l, { size: 48 })
104
208
  }),
105
- /* @__PURE__ */ h("h3", {
209
+ /* @__PURE__ */ b("h3", {
106
210
  className: "text-lg font-semibold text-text-primary mb-2",
107
211
  children: "Failed to load applications"
108
212
  }),
109
- /* @__PURE__ */ h("p", {
213
+ /* @__PURE__ */ b("p", {
110
214
  className: "text-sm text-text-secondary",
111
- children: B.message
215
+ children: W.message
112
216
  })
113
217
  ]
114
218
  })]
115
- }) : /* @__PURE__ */ g("div", {
219
+ }) : /* @__PURE__ */ x("div", {
116
220
  className: "p-6",
117
221
  children: [
118
- /* @__PURE__ */ h("div", {
222
+ /* @__PURE__ */ b("div", {
119
223
  className: "flex items-center justify-between mb-6",
120
- children: /* @__PURE__ */ g("div", {
224
+ children: /* @__PURE__ */ x("div", {
121
225
  className: "flex items-center gap-3",
122
226
  children: [
123
- /* @__PURE__ */ h(a, {
227
+ /* @__PURE__ */ b(u, {
124
228
  size: 24,
125
229
  className: "text-text-primary"
126
230
  }),
127
- /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h1", {
231
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("h1", {
128
232
  className: "text-2xl font-bold text-text-primary",
129
233
  children: "Job Applications"
130
- }), /* @__PURE__ */ h("p", {
234
+ }), /* @__PURE__ */ b("p", {
131
235
  className: "text-sm text-text-secondary",
132
236
  children: "Careers form submissions"
133
237
  })] }),
134
- /* @__PURE__ */ h("span", {
135
- className: "ml-2 inline-flex items-center px-2.5 py-0.5 rounded-full text-xs font-medium bg-bg-sunken text-text-secondary",
136
- children: U
238
+ /* @__PURE__ */ b(e, {
239
+ variant: "secondary",
240
+ className: "ml-2",
241
+ children: Y
137
242
  })
138
243
  ]
139
244
  })
140
245
  }),
141
- /* @__PURE__ */ h(v, {
246
+ /* @__PURE__ */ b(re, {
142
247
  className: "mb-6",
143
248
  children: "Candidates who apply through your careers pages show up here. Review resumes and move applicants through your hiring pipeline — from new submission to screening, interview and hire — so promising people get a timely response. Open an application to see the full profile and resume."
144
249
  }),
145
- /* @__PURE__ */ g("div", {
146
- className: "flex flex-col sm:flex-row gap-3 mb-6",
147
- children: [/* @__PURE__ */ g("div", {
148
- className: "relative flex-1",
149
- children: [/* @__PURE__ */ h(u, {
150
- size: 16,
151
- className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"
152
- }), /* @__PURE__ */ h("input", {
153
- type: "text",
154
- "aria-label": "Search applications",
155
- placeholder: "Search by name, email, or position...",
156
- value: w,
157
- onChange: (e) => T(e.target.value),
158
- className: "w-full pl-9 pr-4 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary placeholder:text-text-secondary focus:outline-none focus:ring-2 focus:ring-accent/50"
159
- })]
160
- }), /* @__PURE__ */ g("button", {
161
- type: "button",
162
- onClick: () => N(!M),
163
- className: "inline-flex items-center gap-2 px-4 py-2 bg-surface border border-default rounded-lg text-sm text-text-secondary hover:text-text-primary hover:bg-bg-sunken transition-colors",
164
- children: [
165
- /* @__PURE__ */ h(s, { size: 16 }),
166
- "Filters",
167
- /* @__PURE__ */ h(o, {
168
- size: 14,
169
- className: M ? "rotate-180 transition-transform" : "transition-transform"
170
- })
171
- ]
172
- })]
173
- }),
174
- M && /* @__PURE__ */ h("div", {
175
- className: "mb-6 p-4 bg-bg-surface border border-border-seam rounded-lg",
176
- children: /* @__PURE__ */ g("div", {
177
- className: "flex flex-wrap gap-4",
178
- children: [/* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("label", {
179
- htmlFor: "job-app-status-filter",
180
- className: "block text-xs font-medium text-text-secondary mb-1",
181
- children: "Status"
182
- }), /* @__PURE__ */ g("select", {
183
- id: "job-app-status-filter",
184
- value: O,
185
- onChange: (e) => k(e.target.value),
186
- className: "px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50",
250
+ /* @__PURE__ */ x("div", {
251
+ className: "flex flex-col sm:flex-row items-stretch sm:items-center gap-4 p-4 rounded-xl border border-border-seam bg-bg-surface mb-6",
252
+ children: [
253
+ /* @__PURE__ */ x("div", {
254
+ className: "relative flex-1",
255
+ children: [/* @__PURE__ */ b(h, {
256
+ size: 18,
257
+ className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"
258
+ }), /* @__PURE__ */ b(n, {
259
+ type: "text",
260
+ "aria-label": "Search applications",
261
+ placeholder: "Search by name, email, or position...",
262
+ value: D,
263
+ onChange: (e) => O(e.target.value),
264
+ className: "pl-10"
265
+ })]
266
+ }),
267
+ /* @__PURE__ */ x("div", {
268
+ className: "flex items-center gap-1 p-1 rounded-lg border bg-bg-sunken/50",
269
+ children: [/* @__PURE__ */ b(t, {
270
+ variant: L === "list" ? "secondary" : "ghost",
271
+ size: "sm",
272
+ onClick: () => R("list"),
273
+ className: "px-3",
274
+ "aria-label": "Show applications as a list",
275
+ children: /* @__PURE__ */ b(f, { size: 18 })
276
+ }), /* @__PURE__ */ b(t, {
277
+ variant: L === "kanban" ? "secondary" : "ghost",
278
+ size: "sm",
279
+ onClick: () => R("kanban"),
280
+ className: "px-3",
281
+ "aria-label": "Show applications as a kanban board",
282
+ children: /* @__PURE__ */ b(te, { size: 18 })
283
+ })]
284
+ }),
285
+ /* @__PURE__ */ x(t, {
286
+ variant: F ? "secondary" : "outline",
287
+ size: "sm",
288
+ onClick: () => I(!F),
289
+ className: "gap-2",
187
290
  children: [
188
- /* @__PURE__ */ h("option", {
189
- value: "",
190
- children: "All statuses"
191
- }),
192
- /* @__PURE__ */ h("option", {
193
- value: "NEW",
194
- children: "New"
195
- }),
196
- /* @__PURE__ */ h("option", {
197
- value: "SCREENING",
198
- children: "Screening"
199
- }),
200
- /* @__PURE__ */ h("option", {
201
- value: "SHORTLISTED",
202
- children: "Shortlisted"
203
- }),
204
- /* @__PURE__ */ h("option", {
205
- value: "INTERVIEW",
206
- children: "Interview"
207
- }),
208
- /* @__PURE__ */ h("option", {
209
- value: "HIRED",
210
- children: "Hired"
211
- }),
212
- /* @__PURE__ */ h("option", {
213
- value: "REJECTED",
214
- children: "Rejected"
215
- }),
216
- /* @__PURE__ */ h("option", {
217
- value: "ARCHIVED",
218
- children: "Archived"
291
+ /* @__PURE__ */ b(ee, { size: 16 }),
292
+ "Filters",
293
+ /* @__PURE__ */ b(d, {
294
+ size: 14,
295
+ className: F ? "rotate-180 transition-transform" : "transition-transform"
219
296
  })
220
297
  ]
221
- })] }), /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("label", {
222
- htmlFor: "job-app-product-filter",
223
- className: "block text-xs font-medium text-text-secondary mb-1",
224
- children: "Product"
225
- }), /* @__PURE__ */ g("select", {
226
- id: "job-app-product-filter",
227
- value: A,
228
- onChange: (e) => j(e.target.value),
229
- className: "px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50",
230
- children: [/* @__PURE__ */ h("option", {
231
- value: "",
232
- children: "All products"
233
- }), G.map((e) => /* @__PURE__ */ h("option", {
234
- value: e,
235
- children: P[e] || e
236
- }, e))]
237
- })] })]
298
+ })
299
+ ]
300
+ }),
301
+ F && /* @__PURE__ */ b("div", {
302
+ className: "mb-6 p-4 bg-bg-surface border border-border-seam rounded-lg",
303
+ children: /* @__PURE__ */ x("div", {
304
+ className: "grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",
305
+ children: [
306
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
307
+ htmlFor: "job-app-status-filter",
308
+ className: "block text-xs font-medium text-text-secondary mb-1",
309
+ children: "Status"
310
+ }), /* @__PURE__ */ x("select", {
311
+ id: "job-app-status-filter",
312
+ value: A,
313
+ onChange: (e) => ae(e.target.value),
314
+ className: "w-full px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50",
315
+ children: [
316
+ /* @__PURE__ */ b("option", {
317
+ value: "",
318
+ children: "All statuses"
319
+ }),
320
+ /* @__PURE__ */ b("option", {
321
+ value: "NEW",
322
+ children: "New"
323
+ }),
324
+ /* @__PURE__ */ b("option", {
325
+ value: "SCREENING",
326
+ children: "Screening"
327
+ }),
328
+ /* @__PURE__ */ b("option", {
329
+ value: "SHORTLISTED",
330
+ children: "Shortlisted"
331
+ }),
332
+ /* @__PURE__ */ b("option", {
333
+ value: "INTERVIEW",
334
+ children: "Interview"
335
+ }),
336
+ /* @__PURE__ */ b("option", {
337
+ value: "HIRED",
338
+ children: "Hired"
339
+ }),
340
+ /* @__PURE__ */ b("option", {
341
+ value: "REJECTED",
342
+ children: "Rejected"
343
+ }),
344
+ /* @__PURE__ */ b("option", {
345
+ value: "ARCHIVED",
346
+ children: "Archived"
347
+ })
348
+ ]
349
+ })] }),
350
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
351
+ htmlFor: "job-app-product-filter",
352
+ className: "block text-xs font-medium text-text-secondary mb-1",
353
+ children: "Product"
354
+ }), /* @__PURE__ */ x("select", {
355
+ id: "job-app-product-filter",
356
+ value: j,
357
+ onChange: (e) => M(e.target.value),
358
+ className: "w-full px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50",
359
+ children: [/* @__PURE__ */ b("option", {
360
+ value: "",
361
+ children: "All products"
362
+ }), Z.map((e) => /* @__PURE__ */ b("option", {
363
+ value: e,
364
+ children: z[e] || e
365
+ }, e))]
366
+ })] }),
367
+ /* @__PURE__ */ x("div", { children: [/* @__PURE__ */ b("label", {
368
+ htmlFor: "job-app-posting-filter",
369
+ className: "block text-xs font-medium text-text-secondary mb-1",
370
+ children: "Job Posting"
371
+ }), /* @__PURE__ */ x("select", {
372
+ id: "job-app-posting-filter",
373
+ value: N,
374
+ onChange: (e) => P(e.target.value),
375
+ disabled: q,
376
+ className: "w-full px-3 py-2 bg-surface border border-default rounded-lg text-sm text-text-primary focus:outline-none focus:ring-2 focus:ring-accent/50 disabled:opacity-50",
377
+ children: [/* @__PURE__ */ b("option", {
378
+ value: "",
379
+ children: "All postings"
380
+ }), (K?.jobPostings?.items ?? []).map((e) => /* @__PURE__ */ b("option", {
381
+ value: e.id,
382
+ children: e.title
383
+ }, e.id))]
384
+ })] })
385
+ ]
238
386
  })
239
387
  }),
240
- H.length === 0 ? /* @__PURE__ */ h(_, {
388
+ J.length === 0 ? /* @__PURE__ */ b(ne, {
241
389
  illustration: "empty-people",
242
390
  title: "No applications yet",
243
391
  description: "Job applications from your careers pages will appear here."
244
- }) : /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h("div", {
392
+ }) : /* @__PURE__ */ x(y, { children: [L === "list" ? /* @__PURE__ */ b("div", {
245
393
  className: "space-y-3",
246
- children: H.map((e) => /* @__PURE__ */ h("button", {
247
- type: "button",
248
- onClick: () => S(`/support/applications/${e.id}${C}`),
249
- className: "w-full text-left p-4 bg-bg-surface border border-border-seam rounded-lg shadow-[var(--shadow-pop)] hover:border-border-strong hover:shadow-[var(--shadow-pop-hover)] transition-[box-shadow,border-color] duration-200 group",
250
- children: /* @__PURE__ */ g("div", {
251
- className: "flex items-start justify-between gap-4",
252
- children: [/* @__PURE__ */ g("div", {
253
- className: "flex-1 min-w-0",
254
- children: [
255
- /* @__PURE__ */ g("div", {
256
- className: "flex items-center gap-2 mb-1 flex-wrap",
257
- children: [
258
- /* @__PURE__ */ g("h3", {
259
- className: "text-sm font-semibold text-text-primary truncate group-hover:text-accent transition-colors",
260
- children: [
261
- e.firstName,
262
- " ",
263
- e.lastName
264
- ]
265
- }),
266
- /* @__PURE__ */ h("span", {
267
- className: `inline-flex items-center px-2 py-0.5 rounded-full text-xs font-medium ${y[e.status] || y.NEW} ${e.status === "NEW" ? "motion-safe:animate-vc-glow-pulse" : ""}`,
268
- children: b[e.status] || e.status
269
- }),
270
- e.productId && P[e.productId] && /* @__PURE__ */ h("span", {
271
- className: "inline-flex items-center px-2 py-0.5 rounded-full text-xs font-medium bg-accent-purple-subtle text-accent-purple",
272
- title: `Product: ${P[e.productId]}`,
273
- children: P[e.productId]
274
- }),
275
- e.resumeFileName && /* @__PURE__ */ g("span", {
276
- className: "inline-flex items-center gap-1 px-2 py-0.5 rounded-full text-xs font-medium bg-accent-blue-subtle text-accent-blue",
277
- children: [/* @__PURE__ */ h(l, { size: 11 }), "Resume"]
278
- })
279
- ]
280
- }),
281
- /* @__PURE__ */ g("p", {
282
- className: "text-sm text-text-secondary mb-1",
283
- children: [/* @__PURE__ */ h("span", {
284
- className: "font-medium",
285
- children: e.position
286
- }), e.department && /* @__PURE__ */ g(m, { children: [/* @__PURE__ */ h("span", {
287
- className: "mx-1.5 text-text-secondary/50",
288
- children: "·"
289
- }), /* @__PURE__ */ h("span", { children: e.department })] })]
290
- }),
291
- /* @__PURE__ */ h("p", {
292
- className: "text-xs text-text-secondary truncate",
293
- children: e.email
394
+ children: J.map((e) => $(e))
395
+ }) : /* @__PURE__ */ b("div", {
396
+ className: "flex gap-4 overflow-x-auto pb-4",
397
+ children: S.map((t) => {
398
+ let n = ce[t] ?? [];
399
+ return /* @__PURE__ */ x("div", {
400
+ className: "flex flex-col gap-3 w-[280px] flex-shrink-0 max-h-[calc(100vh-280px)]",
401
+ children: [/* @__PURE__ */ x("div", {
402
+ className: "flex items-center justify-between px-1",
403
+ children: [/* @__PURE__ */ b("h3", {
404
+ className: "text-sm font-semibold text-text-primary",
405
+ children: w[t]
406
+ }), /* @__PURE__ */ b(e, {
407
+ variant: "secondary",
408
+ className: C[t],
409
+ children: n.length
410
+ })]
411
+ }), /* @__PURE__ */ x("div", {
412
+ className: "flex flex-col gap-3 overflow-y-auto pr-1",
413
+ children: [n.length === 0 && /* @__PURE__ */ b("div", {
414
+ className: "text-center py-6 px-3 rounded-lg border border-dashed border-border-seam bg-bg-sunken/30",
415
+ children: /* @__PURE__ */ b("p", {
416
+ className: "text-xs text-text-secondary",
417
+ children: "No applications"
294
418
  })
295
- ]
296
- }), /* @__PURE__ */ h("div", {
297
- className: "text-xs text-text-secondary whitespace-nowrap",
298
- children: x(e.createdAt)
419
+ }), n.map((e) => $(e, !0))]
299
420
  })]
300
- })
301
- }, e.id))
302
- }), W && /* @__PURE__ */ h("div", {
421
+ }, t);
422
+ })
423
+ }), X && /* @__PURE__ */ b("div", {
303
424
  className: "flex justify-center mt-6",
304
- children: /* @__PURE__ */ g("button", {
305
- type: "button",
306
- onClick: () => {
307
- W && V({
308
- variables: { offset: H.length },
309
- updateQuery: (e, { fetchMoreResult: t }) => t ? { jobApplications: {
310
- ...t.jobApplications,
311
- items: [...e.jobApplications?.items ?? [], ...t.jobApplications?.items ?? []]
312
- } } : e
313
- });
314
- },
315
- disabled: z,
316
- className: "inline-flex items-center gap-2 px-6 py-2 bg-surface border border-default rounded-lg text-sm text-text-secondary hover:text-text-primary hover:bg-bg-sunken transition-colors disabled:opacity-50",
317
- children: [z ? /* @__PURE__ */ h(c, {
425
+ children: /* @__PURE__ */ x(t, {
426
+ variant: "outline",
427
+ size: "sm",
428
+ onClick: se,
429
+ disabled: U,
430
+ className: "gap-2",
431
+ children: [U ? /* @__PURE__ */ b(p, {
318
432
  size: 14,
319
433
  className: "animate-spin"
320
434
  }) : null, "Load more"]
@@ -324,6 +438,6 @@ function S() {
324
438
  });
325
439
  }
326
440
  //#endregion
327
- export { S as JobApplicationsPage };
441
+ export { D as JobApplicationsPage };
328
442
 
329
443
  //# sourceMappingURL=JobApplicationsPage.js.map