@burdenoff/microfe-support 2026.817.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,29 +1,29 @@
1
1
  import { useSupport as e } from "../providers/SupportProvider.js";
2
- import { Badge as t, Button as n, Card as ee, CardContent as te, Dialog as r, DialogContent as i, DialogFooter as a, DialogHeader as o, DialogTitle as s, Input as c, Label as l, PagePurpose as ne, Select as u, SelectContent as d, SelectItem as f, SelectTrigger as p, SelectValue as m, Textarea as re } from "../components/ui.js";
3
- import { useCreateJobPostingMutation as ie, useDeleteJobPostingMutation as ae, useGetJobPostingsQuery as oe, useUpdateJobPostingMutation as se } from "../../generated/global-operations.js";
4
- import { EmploymentType as h, JobPostingStatus as g } from "../../generated/global-types.js";
5
- import { cn as _ } from "../utils/cn.js";
6
- import { EmptyState as ce, LoadingState as le, PageLayout as v } from "../components/PageLayout.js";
2
+ import { Badge as t, Button as n, Card as ee, CardContent as te, Dialog as r, DialogContent as i, DialogFooter as ne, DialogHeader as a, DialogTitle as o, Input as s, Label as c, PagePurpose as re, Select as l, SelectContent as u, SelectItem as d, SelectTrigger as f, SelectValue as p, Textarea as ie } from "../components/ui.js";
3
+ import { useCreateJobPostingMutation as ae, useDeleteJobPostingMutation as oe, useGetJobPostingsQuery as se, useUpdateJobPostingMutation as ce } from "../../generated/global-operations.js";
4
+ import { EmploymentType as m, JobPostingStatus as h } from "../../generated/global-types.js";
5
+ import { cn as g } from "../utils/cn.js";
6
+ import { EmptyState as _, LoadingState as le, PageLayout as v } from "../components/PageLayout.js";
7
7
  import { useEffect as ue, useState as y } from "react";
8
8
  import { AlertCircle as b, Briefcase as x, Building2 as de, Edit2 as fe, Loader2 as S, MapPin as pe, Plus as C, Search as me, Trash2 as he, Users as ge } from "lucide-react";
9
9
  import { useNavigate as _e } from "react-router";
10
10
  import { Fragment as w, jsx as T, jsxs as E } from "react/jsx-runtime";
11
11
  //#region src/support/pages/JobPostingsPage.tsx
12
12
  var ve = {
13
- [g.Open]: "bg-status-success-bg-subtle text-status-success-text",
14
- [g.Draft]: "bg-status-warning-bg-subtle text-status-warning-text",
15
- [g.Closed]: "bg-status-error-bg-subtle text-status-error-text",
16
- [g.Archived]: "bg-bg-sunken text-text-secondary"
13
+ [h.Open]: "bg-status-success-bg-subtle text-status-success-text",
14
+ [h.Draft]: "bg-status-warning-bg-subtle text-status-warning-text",
15
+ [h.Closed]: "bg-status-error-bg-subtle text-status-error-text",
16
+ [h.Archived]: "bg-bg-sunken text-text-secondary"
17
17
  }, ye = {
18
- [g.Open]: "Open",
19
- [g.Draft]: "Draft",
20
- [g.Closed]: "Closed",
21
- [g.Archived]: "Archived"
18
+ [h.Open]: "Open",
19
+ [h.Draft]: "Draft",
20
+ [h.Closed]: "Closed",
21
+ [h.Archived]: "Archived"
22
22
  }, be = {
23
- [h.FullTime]: "Full-time",
24
- [h.PartTime]: "Part-time",
25
- [h.Contract]: "Contract",
26
- [h.Internship]: "Internship"
23
+ [m.FullTime]: "Full-time",
24
+ [m.PartTime]: "Part-time",
25
+ [m.Contract]: "Contract",
26
+ [m.Internship]: "Internship"
27
27
  };
28
28
  function xe(e) {
29
29
  return new Date(e).toLocaleDateString("en-US", {
@@ -32,7 +32,7 @@ function xe(e) {
32
32
  year: "numeric"
33
33
  });
34
34
  }
35
- var D = {
35
+ var D = "ALL", O = {
36
36
  title: "",
37
37
  department: "",
38
38
  location: "",
@@ -41,43 +41,43 @@ var D = {
41
41
  status: "",
42
42
  productId: ""
43
43
  };
44
- function O() {
45
- let O = _e(), { basePath: Se = "" } = e(), [k, Ce] = y(""), [A, we] = y(""), [j, Te] = y(""), [Ee, M] = y(!1), [N, P] = y(null), [F, I] = y(D), [De, L] = y(!1), [R, z] = y(null), [B, V] = y(null);
44
+ function k() {
45
+ let k = _e(), { basePath: Se = "" } = e(), [A, Ce] = y(""), [j, we] = y(""), [M, Te] = y(D), [Ee, N] = y(!1), [P, F] = y(null), [I, L] = y(O), [De, R] = y(!1), [z, B] = y(null), [V, H] = y(null);
46
46
  ue(() => {
47
- let e = setTimeout(() => we(k), 300);
47
+ let e = setTimeout(() => we(A), 300);
48
48
  return () => clearTimeout(e);
49
- }, [k]);
50
- let H = {};
51
- A && (H.search = A), j && (H.status = j);
52
- let { data: U, loading: W, error: G, fetchMore: Oe, refetch: ke } = oe({
49
+ }, [A]);
50
+ let U = {};
51
+ j && (U.search = j), M !== D && (U.status = M);
52
+ let { data: W, loading: G, error: K, fetchMore: Oe, refetch: ke } = se({
53
53
  variables: {
54
- filter: H,
54
+ filter: U,
55
55
  limit: 50,
56
56
  offset: 0
57
57
  },
58
58
  fetchPolicy: "cache-and-network"
59
- }), K = U?.jobPostings?.items ?? [], q = U?.jobPostings?.total ?? 0, J = U?.jobPostings?.hasMore ?? !1, [Ae, { loading: Y }] = ie({
59
+ }), q = W?.jobPostings?.items ?? [], J = W?.jobPostings?.total ?? 0, Y = W?.jobPostings?.hasMore ?? !1, [Ae, { loading: X }] = ae({
60
60
  refetchQueries: ["GetJobPostings"],
61
61
  awaitRefetchQueries: !0
62
- }), [je, { loading: X }] = se({
62
+ }), [je, { loading: Z }] = ce({
63
63
  refetchQueries: ["GetJobPostings"],
64
64
  awaitRefetchQueries: !0
65
- }), [Me, { loading: Z }] = ae({
65
+ }), [Me, { loading: Q }] = oe({
66
66
  refetchQueries: ["GetJobPostings"],
67
67
  awaitRefetchQueries: !0
68
- }), Q = (e, t) => {
69
- V({
68
+ }), $ = (e, t) => {
69
+ H({
70
70
  type: e,
71
71
  message: t
72
- }), setTimeout(() => V(null), 4e3);
72
+ }), setTimeout(() => H(null), 4e3);
73
73
  }, Ne = () => {
74
- P(null), I({
75
- ...D,
76
- status: g.Open,
77
- employmentType: h.FullTime
78
- }), M(!0);
74
+ F(null), L({
75
+ ...O,
76
+ status: h.Open,
77
+ employmentType: m.FullTime
78
+ }), N(!0);
79
79
  }, Pe = (e) => {
80
- P(e), I({
80
+ F(e), L({
81
81
  title: e.title,
82
82
  department: e.department ?? "",
83
83
  location: e.location ?? "",
@@ -85,50 +85,50 @@ function O() {
85
85
  description: e.description ?? "",
86
86
  status: e.status,
87
87
  productId: e.productId ?? ""
88
- }), M(!0);
89
- }, $ = () => {
90
- M(!1), P(null), I(D);
91
- }, Fe = async (e) => {
92
- if (e.preventDefault(), F.title.trim()) try {
93
- N ? (await je({ variables: {
94
- id: N.id,
88
+ }), N(!0);
89
+ }, Fe = () => {
90
+ N(!1), F(null), L(O);
91
+ }, Ie = async (e) => {
92
+ if (e.preventDefault(), I.title.trim()) try {
93
+ P ? (await je({ variables: {
94
+ id: P.id,
95
95
  input: {
96
- title: F.title,
97
- department: F.department || void 0,
98
- location: F.location || void 0,
99
- employmentType: F.employmentType || void 0,
100
- description: F.description || void 0,
101
- status: F.status || void 0,
102
- productId: F.productId || void 0
96
+ title: I.title,
97
+ department: I.department || void 0,
98
+ location: I.location || void 0,
99
+ employmentType: I.employmentType || void 0,
100
+ description: I.description || void 0,
101
+ status: I.status || void 0,
102
+ productId: I.productId || void 0
103
103
  }
104
- } }), Q("success", "Job posting updated.")) : (await Ae({ variables: { input: {
105
- title: F.title,
106
- department: F.department || void 0,
107
- location: F.location || void 0,
108
- employmentType: F.employmentType || void 0,
109
- description: F.description || void 0,
110
- status: F.status || g.Open,
111
- productId: F.productId || void 0
112
- } } }), Q("success", "Job posting created.")), $();
104
+ } }), $("success", "Job posting updated.")) : (await Ae({ variables: { input: {
105
+ title: I.title,
106
+ department: I.department || void 0,
107
+ location: I.location || void 0,
108
+ employmentType: I.employmentType || void 0,
109
+ description: I.description || void 0,
110
+ status: I.status || h.Open,
111
+ productId: I.productId || void 0
112
+ } } }), $("success", "Job posting created.")), Fe();
113
113
  } catch (e) {
114
- Q("error", e instanceof Error ? e.message : "Something went wrong.");
114
+ $("error", e instanceof Error ? e.message : "Something went wrong.");
115
115
  }
116
- }, Ie = (e) => {
117
- z(e), L(!0);
116
+ }, Le = (e) => {
117
+ B(e), R(!0);
118
118
  };
119
- return W && K.length === 0 ? /* @__PURE__ */ T(v, {
119
+ return G && q.length === 0 ? /* @__PURE__ */ T(v, {
120
120
  title: "Job Postings",
121
121
  subtitle: "Manage open roles and hiring pipelines",
122
122
  icon: /* @__PURE__ */ T(x, { size: 24 }),
123
123
  children: /* @__PURE__ */ T(le, { message: "Loading job postings…" })
124
- }) : G ? /* @__PURE__ */ T(v, {
124
+ }) : K ? /* @__PURE__ */ T(v, {
125
125
  title: "Job Postings",
126
126
  subtitle: "Manage open roles and hiring pipelines",
127
127
  icon: /* @__PURE__ */ T(x, { size: 24 }),
128
- children: /* @__PURE__ */ T(ce, {
128
+ children: /* @__PURE__ */ T(_, {
129
129
  icon: /* @__PURE__ */ T(b, { size: 48 }),
130
130
  title: "Failed to load job postings",
131
- description: G.message,
131
+ description: K.message,
132
132
  action: /* @__PURE__ */ T(n, {
133
133
  variant: "outline",
134
134
  onClick: () => ke(),
@@ -144,15 +144,15 @@ function O() {
144
144
  children: [/* @__PURE__ */ T(C, { size: 18 }), "New Job Posting"]
145
145
  }),
146
146
  children: [
147
- /* @__PURE__ */ T(ne, { children: "Create and manage job postings across your products. Each posting drives your careers page and collects applications that you can review, screen, and move through interviews." }),
148
- B && /* @__PURE__ */ T("div", {
149
- className: _("fixed right-4 top-[calc(var(--header-height,4rem)+1rem)] z-[200] flex items-center gap-3 px-5 py-3 rounded-xl shadow-2xl border border-border-subtle animate-in slide-in-from-top-4 duration-200", B.type === "success" ? "bg-status-success-bg-subtle text-status-success-text" : "bg-status-error-bg-subtle text-status-error-text"),
150
- children: B.type === "success" ? /* @__PURE__ */ T("span", {
147
+ /* @__PURE__ */ T(re, { children: "Create and manage job postings across your products. Each posting drives your careers page and collects applications that you can review, screen, and move through interviews." }),
148
+ V && /* @__PURE__ */ T("div", {
149
+ className: g("fixed right-4 top-[calc(var(--header-height,4rem)+1rem)] z-[200] flex items-center gap-3 px-5 py-3 rounded-xl shadow-2xl border border-border-subtle animate-in slide-in-from-top-4 duration-200", V.type === "success" ? "bg-status-success-bg-subtle text-status-success-text" : "bg-status-error-bg-subtle text-status-error-text"),
150
+ children: V.type === "success" ? /* @__PURE__ */ T("span", {
151
151
  className: "font-medium",
152
- children: B.message
152
+ children: V.message
153
153
  }) : /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T(b, { size: 18 }), /* @__PURE__ */ T("span", {
154
154
  className: "font-medium",
155
- children: B.message
155
+ children: V.message
156
156
  })] })
157
157
  }),
158
158
  /* @__PURE__ */ E("div", {
@@ -162,39 +162,39 @@ function O() {
162
162
  children: [/* @__PURE__ */ T(me, {
163
163
  size: 16,
164
164
  className: "absolute left-3 top-1/2 -translate-y-1/2 text-text-secondary"
165
- }), /* @__PURE__ */ T(c, {
165
+ }), /* @__PURE__ */ T(s, {
166
166
  type: "text",
167
167
  "aria-label": "Search job postings",
168
168
  placeholder: "Search by title, department, or location…",
169
- value: k,
169
+ value: A,
170
170
  onChange: (e) => Ce(e.target.value),
171
171
  className: "pl-9"
172
172
  })]
173
- }), /* @__PURE__ */ E(u, {
174
- value: j,
173
+ }), /* @__PURE__ */ E(l, {
174
+ value: M,
175
175
  onValueChange: (e) => Te(e),
176
- children: [/* @__PURE__ */ T(p, {
176
+ children: [/* @__PURE__ */ T(f, {
177
177
  className: "w-full sm:w-[180px]",
178
- children: /* @__PURE__ */ T(m, { placeholder: "All statuses" })
179
- }), /* @__PURE__ */ E(d, { children: [
180
- /* @__PURE__ */ T(f, {
181
- value: "",
178
+ children: /* @__PURE__ */ T(p, { placeholder: "All statuses" })
179
+ }), /* @__PURE__ */ E(u, { children: [
180
+ /* @__PURE__ */ T(d, {
181
+ value: D,
182
182
  children: "All statuses"
183
183
  }),
184
- /* @__PURE__ */ T(f, {
185
- value: g.Open,
184
+ /* @__PURE__ */ T(d, {
185
+ value: h.Open,
186
186
  children: "Open"
187
187
  }),
188
- /* @__PURE__ */ T(f, {
189
- value: g.Draft,
188
+ /* @__PURE__ */ T(d, {
189
+ value: h.Draft,
190
190
  children: "Draft"
191
191
  }),
192
- /* @__PURE__ */ T(f, {
193
- value: g.Closed,
192
+ /* @__PURE__ */ T(d, {
193
+ value: h.Closed,
194
194
  children: "Closed"
195
195
  }),
196
- /* @__PURE__ */ T(f, {
197
- value: g.Archived,
196
+ /* @__PURE__ */ T(d, {
197
+ value: h.Archived,
198
198
  children: "Archived"
199
199
  })
200
200
  ] })]
@@ -203,12 +203,12 @@ function O() {
203
203
  /* @__PURE__ */ E("p", {
204
204
  className: "text-sm text-text-secondary",
205
205
  children: [
206
- q,
206
+ J,
207
207
  " posting",
208
- q === 1 ? "" : "s"
208
+ J === 1 ? "" : "s"
209
209
  ]
210
210
  }),
211
- K.length === 0 ? /* @__PURE__ */ T(ce, {
211
+ q.length === 0 ? /* @__PURE__ */ T(_, {
212
212
  illustration: "empty-files",
213
213
  title: "No job postings yet",
214
214
  description: "Create your first job posting to start collecting applications.",
@@ -218,9 +218,9 @@ function O() {
218
218
  })
219
219
  }) : /* @__PURE__ */ E(w, { children: [/* @__PURE__ */ T("div", {
220
220
  className: "grid grid-cols-1 md:grid-cols-2 xl:grid-cols-3 gap-4",
221
- children: K.map((e) => /* @__PURE__ */ E(ee, {
221
+ children: q.map((e) => /* @__PURE__ */ E(ee, {
222
222
  className: "group cursor-pointer transition-[box-shadow,border-color] duration-200 hover:shadow-[var(--shadow-pop-hover)] hover:border-border-strong",
223
- onClick: () => O(`${Se}/applications/postings/${e.id}`),
223
+ onClick: () => k(`${Se}/applications/postings/${e.id}`),
224
224
  children: [/* @__PURE__ */ E(te, {
225
225
  className: "p-5",
226
226
  children: [
@@ -236,7 +236,7 @@ function O() {
236
236
  children: [/* @__PURE__ */ T(de, { size: 12 }), e.department]
237
237
  })]
238
238
  }), /* @__PURE__ */ T(t, {
239
- className: _("text-xs", ve[e.status]),
239
+ className: g("text-xs", ve[e.status]),
240
240
  children: ye[e.status]
241
241
  })]
242
242
  }),
@@ -298,7 +298,7 @@ function O() {
298
298
  size: "sm",
299
299
  className: "text-status-error-text hover:bg-status-error-bg-subtle",
300
300
  onClick: (t) => {
301
- t.stopPropagation(), Ie(e);
301
+ t.stopPropagation(), Le(e);
302
302
  },
303
303
  children: [/* @__PURE__ */ T(he, {
304
304
  size: 14,
@@ -307,21 +307,21 @@ function O() {
307
307
  })]
308
308
  })]
309
309
  }, e.id))
310
- }), J && /* @__PURE__ */ T("div", {
310
+ }), Y && /* @__PURE__ */ T("div", {
311
311
  className: "flex justify-center mt-6",
312
312
  children: /* @__PURE__ */ E(n, {
313
313
  variant: "outline",
314
314
  onClick: () => {
315
- J && Oe({
316
- variables: { offset: K.length },
315
+ Y && Oe({
316
+ variables: { offset: q.length },
317
317
  updateQuery: (e, { fetchMoreResult: t }) => t ? { jobPostings: {
318
318
  ...t.jobPostings,
319
319
  items: [...e.jobPostings?.items ?? [], ...t.jobPostings?.items ?? []]
320
320
  } } : e
321
321
  });
322
322
  },
323
- disabled: W,
324
- children: [W ? /* @__PURE__ */ T(S, {
323
+ disabled: G,
324
+ children: [G ? /* @__PURE__ */ T(S, {
325
325
  size: 14,
326
326
  className: "animate-spin mr-2"
327
327
  }) : null, "Load more"]
@@ -329,23 +329,23 @@ function O() {
329
329
  })] }),
330
330
  /* @__PURE__ */ T(r, {
331
331
  open: Ee,
332
- onOpenChange: M,
332
+ onOpenChange: N,
333
333
  children: /* @__PURE__ */ E(i, {
334
334
  className: "w-full max-w-lg max-h-[90vh] overflow-y-auto",
335
- children: [/* @__PURE__ */ T(o, { children: /* @__PURE__ */ T(s, { children: N ? "Edit Job Posting" : "New Job Posting" }) }), /* @__PURE__ */ E("form", {
336
- onSubmit: Fe,
335
+ children: [/* @__PURE__ */ T(a, { children: /* @__PURE__ */ T(o, { children: P ? "Edit Job Posting" : "New Job Posting" }) }), /* @__PURE__ */ E("form", {
336
+ onSubmit: Ie,
337
337
  className: "space-y-5",
338
338
  children: [
339
- /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ E(l, {
339
+ /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ E(c, {
340
340
  htmlFor: "job-posting-title",
341
341
  children: ["Title ", /* @__PURE__ */ T("span", {
342
342
  className: "text-status-error-text",
343
343
  children: "*"
344
344
  })]
345
- }), /* @__PURE__ */ T(c, {
345
+ }), /* @__PURE__ */ T(s, {
346
346
  id: "job-posting-title",
347
- value: F.title,
348
- onChange: (e) => I((t) => ({
347
+ value: I.title,
348
+ onChange: (e) => L((t) => ({
349
349
  ...t,
350
350
  title: e.target.value
351
351
  })),
@@ -355,25 +355,25 @@ function O() {
355
355
  })] }),
356
356
  /* @__PURE__ */ E("div", {
357
357
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
358
- children: [/* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(l, {
358
+ children: [/* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(c, {
359
359
  htmlFor: "job-posting-department",
360
360
  children: "Department"
361
- }), /* @__PURE__ */ T(c, {
361
+ }), /* @__PURE__ */ T(s, {
362
362
  id: "job-posting-department",
363
- value: F.department,
364
- onChange: (e) => I((t) => ({
363
+ value: I.department,
364
+ onChange: (e) => L((t) => ({
365
365
  ...t,
366
366
  department: e.target.value
367
367
  })),
368
368
  placeholder: "e.g., Engineering",
369
369
  className: "mt-1.5"
370
- })] }), /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(l, {
370
+ })] }), /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(c, {
371
371
  htmlFor: "job-posting-location",
372
372
  children: "Location"
373
- }), /* @__PURE__ */ T(c, {
373
+ }), /* @__PURE__ */ T(s, {
374
374
  id: "job-posting-location",
375
- value: F.location,
376
- onChange: (e) => I((t) => ({
375
+ value: I.location,
376
+ onChange: (e) => L((t) => ({
377
377
  ...t,
378
378
  location: e.target.value
379
379
  })),
@@ -383,90 +383,90 @@ function O() {
383
383
  }),
384
384
  /* @__PURE__ */ E("div", {
385
385
  className: "grid grid-cols-1 sm:grid-cols-2 gap-4",
386
- children: [/* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(l, {
386
+ children: [/* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(c, {
387
387
  htmlFor: "job-posting-employment-type",
388
388
  children: "Employment Type"
389
- }), /* @__PURE__ */ E(u, {
390
- value: F.employmentType,
391
- onValueChange: (e) => I((t) => ({
389
+ }), /* @__PURE__ */ E(l, {
390
+ value: I.employmentType,
391
+ onValueChange: (e) => L((t) => ({
392
392
  ...t,
393
393
  employmentType: e
394
394
  })),
395
- children: [/* @__PURE__ */ T(p, {
395
+ children: [/* @__PURE__ */ T(f, {
396
396
  id: "job-posting-employment-type",
397
397
  className: "mt-1.5",
398
- children: /* @__PURE__ */ T(m, { placeholder: "Select type" })
399
- }), /* @__PURE__ */ E(d, { children: [
400
- /* @__PURE__ */ T(f, {
401
- value: h.FullTime,
398
+ children: /* @__PURE__ */ T(p, { placeholder: "Select type" })
399
+ }), /* @__PURE__ */ E(u, { children: [
400
+ /* @__PURE__ */ T(d, {
401
+ value: m.FullTime,
402
402
  children: "Full-time"
403
403
  }),
404
- /* @__PURE__ */ T(f, {
405
- value: h.PartTime,
404
+ /* @__PURE__ */ T(d, {
405
+ value: m.PartTime,
406
406
  children: "Part-time"
407
407
  }),
408
- /* @__PURE__ */ T(f, {
409
- value: h.Contract,
408
+ /* @__PURE__ */ T(d, {
409
+ value: m.Contract,
410
410
  children: "Contract"
411
411
  }),
412
- /* @__PURE__ */ T(f, {
413
- value: h.Internship,
412
+ /* @__PURE__ */ T(d, {
413
+ value: m.Internship,
414
414
  children: "Internship"
415
415
  })
416
416
  ] })]
417
- })] }), /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(l, {
417
+ })] }), /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(c, {
418
418
  htmlFor: "job-posting-status",
419
419
  children: "Status"
420
- }), /* @__PURE__ */ E(u, {
421
- value: F.status,
422
- onValueChange: (e) => I((t) => ({
420
+ }), /* @__PURE__ */ E(l, {
421
+ value: I.status,
422
+ onValueChange: (e) => L((t) => ({
423
423
  ...t,
424
424
  status: e
425
425
  })),
426
- children: [/* @__PURE__ */ T(p, {
426
+ children: [/* @__PURE__ */ T(f, {
427
427
  id: "job-posting-status",
428
428
  className: "mt-1.5",
429
- children: /* @__PURE__ */ T(m, { placeholder: "Select status" })
430
- }), /* @__PURE__ */ E(d, { children: [
431
- /* @__PURE__ */ T(f, {
432
- value: g.Open,
429
+ children: /* @__PURE__ */ T(p, { placeholder: "Select status" })
430
+ }), /* @__PURE__ */ E(u, { children: [
431
+ /* @__PURE__ */ T(d, {
432
+ value: h.Open,
433
433
  children: "Open"
434
434
  }),
435
- /* @__PURE__ */ T(f, {
436
- value: g.Draft,
435
+ /* @__PURE__ */ T(d, {
436
+ value: h.Draft,
437
437
  children: "Draft"
438
438
  }),
439
- /* @__PURE__ */ T(f, {
440
- value: g.Closed,
439
+ /* @__PURE__ */ T(d, {
440
+ value: h.Closed,
441
441
  children: "Closed"
442
442
  }),
443
- /* @__PURE__ */ T(f, {
444
- value: g.Archived,
443
+ /* @__PURE__ */ T(d, {
444
+ value: h.Archived,
445
445
  children: "Archived"
446
446
  })
447
447
  ] })]
448
448
  })] })]
449
449
  }),
450
- /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(l, {
450
+ /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(c, {
451
451
  htmlFor: "job-posting-product-id",
452
452
  children: "Product ID"
453
- }), /* @__PURE__ */ T(c, {
453
+ }), /* @__PURE__ */ T(s, {
454
454
  id: "job-posting-product-id",
455
- value: F.productId,
456
- onChange: (e) => I((t) => ({
455
+ value: I.productId,
456
+ onChange: (e) => L((t) => ({
457
457
  ...t,
458
458
  productId: e.target.value
459
459
  })),
460
460
  placeholder: "Optional product identifier",
461
461
  className: "mt-1.5"
462
462
  })] }),
463
- /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(l, {
463
+ /* @__PURE__ */ E("div", { children: [/* @__PURE__ */ T(c, {
464
464
  htmlFor: "job-posting-description",
465
465
  children: "Description"
466
- }), /* @__PURE__ */ T(re, {
466
+ }), /* @__PURE__ */ T(ie, {
467
467
  id: "job-posting-description",
468
- value: F.description,
469
- onChange: (e) => I((t) => ({
468
+ value: I.description,
469
+ onChange: (e) => L((t) => ({
470
470
  ...t,
471
471
  description: e.target.value
472
472
  })),
@@ -474,18 +474,18 @@ function O() {
474
474
  rows: 5,
475
475
  className: "mt-1.5 resize-none"
476
476
  })] }),
477
- /* @__PURE__ */ E(a, { children: [/* @__PURE__ */ T(n, {
477
+ /* @__PURE__ */ E(ne, { children: [/* @__PURE__ */ T(n, {
478
478
  type: "button",
479
479
  variant: "outline",
480
- onClick: $,
480
+ onClick: Fe,
481
481
  children: "Cancel"
482
482
  }), /* @__PURE__ */ E(n, {
483
483
  type: "submit",
484
- disabled: Y || X,
485
- children: [Y || X ? /* @__PURE__ */ T(S, {
484
+ disabled: X || Z,
485
+ children: [X || Z ? /* @__PURE__ */ T(S, {
486
486
  size: 16,
487
487
  className: "animate-spin mr-2"
488
- }) : null, N ? "Save Changes" : "Create Posting"]
488
+ }) : null, P ? "Save Changes" : "Create Posting"]
489
489
  })] })
490
490
  ]
491
491
  })]
@@ -493,41 +493,42 @@ function O() {
493
493
  }),
494
494
  /* @__PURE__ */ T(r, {
495
495
  open: De,
496
- onOpenChange: L,
496
+ onOpenChange: R,
497
497
  children: /* @__PURE__ */ E(i, {
498
498
  className: "w-full max-w-md",
499
499
  children: [
500
- /* @__PURE__ */ T(o, { children: /* @__PURE__ */ T(s, { children: "Delete job posting?" }) }),
500
+ /* @__PURE__ */ T(a, { children: /* @__PURE__ */ T(o, { children: "Delete job posting?" }) }),
501
501
  /* @__PURE__ */ E("p", {
502
502
  className: "text-sm text-text-secondary",
503
503
  children: [
504
- "This will permanently remove ",
504
+ "This will permanently remove",
505
+ " ",
505
506
  /* @__PURE__ */ T("strong", {
506
507
  className: "text-text-primary",
507
- children: R?.title
508
+ children: z?.title
508
509
  }),
509
510
  " and cannot be undone."
510
511
  ]
511
512
  }),
512
- /* @__PURE__ */ E(a, { children: [/* @__PURE__ */ T(n, {
513
+ /* @__PURE__ */ E(ne, { children: [/* @__PURE__ */ T(n, {
513
514
  type: "button",
514
515
  variant: "outline",
515
- onClick: () => L(!1),
516
+ onClick: () => R(!1),
516
517
  children: "Cancel"
517
518
  }), /* @__PURE__ */ E(n, {
518
519
  type: "button",
519
520
  variant: "destructive",
520
521
  onClick: async () => {
521
- if (R) try {
522
- await Me({ variables: { id: R.id } }), Q("success", "Job posting deleted.");
522
+ if (z) try {
523
+ await Me({ variables: { id: z.id } }), $("success", "Job posting deleted.");
523
524
  } catch (e) {
524
- Q("error", e instanceof Error ? e.message : "Failed to delete posting.");
525
+ $("error", e instanceof Error ? e.message : "Failed to delete posting.");
525
526
  } finally {
526
- L(!1), z(null);
527
+ R(!1), B(null);
527
528
  }
528
529
  },
529
- disabled: Z,
530
- children: [Z ? /* @__PURE__ */ T(S, {
530
+ disabled: Q,
531
+ children: [Q ? /* @__PURE__ */ T(S, {
531
532
  size: 16,
532
533
  className: "animate-spin mr-2"
533
534
  }) : null, "Delete"]
@@ -539,6 +540,6 @@ function O() {
539
540
  });
540
541
  }
541
542
  //#endregion
542
- export { O as JobPostingsPage };
543
+ export { k as JobPostingsPage };
543
544
 
544
545
  //# sourceMappingURL=JobPostingsPage.js.map