@hadoku/jobplatform 3.42.62 → 3.42.64
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.
- package/dist/App.d.ts.map +1 -1
- package/dist/ApplicationTracking-BhpParbe.js +282 -0
- package/dist/ApplicationsList-DDjncd7P.js +1753 -0
- package/dist/PacketDetail-KOXrbMqc.js +110 -0
- package/dist/PacketsList-llRBP10u.js +49 -0
- package/dist/PipelineBoard-BLmNwNaq.js +208 -0
- package/dist/api/jobs.d.ts +3 -0
- package/dist/api/jobs.d.ts.map +1 -1
- package/dist/api/pipeline.d.ts +64 -0
- package/dist/api/pipeline.d.ts.map +1 -0
- package/dist/components/ApplicationTracking.d.ts +22 -0
- package/dist/components/ApplicationTracking.d.ts.map +1 -0
- package/dist/components/JobDrawer.d.ts +3 -1
- package/dist/components/JobDrawer.d.ts.map +1 -1
- package/dist/components/JobsList.d.ts.map +1 -1
- package/dist/components/PipelineBoard.d.ts +30 -0
- package/dist/components/PipelineBoard.d.ts.map +1 -0
- package/dist/entry-CFBqMGn5.js +3861 -0
- package/dist/index.js +6 -5685
- package/dist/packets-BfqJIYHB.js +17 -0
- package/dist/pipeline-C2hWQq1c.js +47 -0
- package/dist/style.css +1 -1
- package/package.json +2 -2
package/dist/App.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../src/App.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../src/App.tsx"],"names":[],"mappings":"AAiCA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;AAkC/C;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,GAAG,CAAC,KAAK,GAAE,gBAAqB,2CAOvD"}
|
|
@@ -0,0 +1,282 @@
|
|
|
1
|
+
import { jsxs as i, Fragment as G, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { useRef as K, useState as l, useEffect as Q } from "react";
|
|
3
|
+
import { u as V, i as h, J as X } from "./entry-CFBqMGn5.js";
|
|
4
|
+
import { l as I, s as ee, a as te, d as ae } from "./pipeline-C2hWQq1c.js";
|
|
5
|
+
const ne = {
|
|
6
|
+
notes: null,
|
|
7
|
+
priority: null,
|
|
8
|
+
follow_up_at: null,
|
|
9
|
+
contact_name: null,
|
|
10
|
+
contact_email: null
|
|
11
|
+
}, g = {
|
|
12
|
+
note: "Note",
|
|
13
|
+
interview: "Interview",
|
|
14
|
+
contact: "Contact",
|
|
15
|
+
follow_up: "Follow-up"
|
|
16
|
+
}, k = {
|
|
17
|
+
interested: "Interested",
|
|
18
|
+
saved: "Saved",
|
|
19
|
+
applied: "Applied",
|
|
20
|
+
interviewing: "Interviewing",
|
|
21
|
+
offered: "Offered",
|
|
22
|
+
rejected: "Rejected",
|
|
23
|
+
dismissed: "Dismissed"
|
|
24
|
+
}, _ = (e, n) => e instanceof X ? e.message : n;
|
|
25
|
+
function Z(e) {
|
|
26
|
+
return {
|
|
27
|
+
priority: e.priority ? String(e.priority) : "",
|
|
28
|
+
follow_up_at: e.follow_up_at ?? "",
|
|
29
|
+
contact_name: e.contact_name ?? "",
|
|
30
|
+
contact_email: e.contact_email ?? "",
|
|
31
|
+
notes: e.notes ?? ""
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
function ie(e, n) {
|
|
35
|
+
const r = {};
|
|
36
|
+
e.priority !== n.priority && (r.priority = e.priority ? Number(e.priority) : null);
|
|
37
|
+
for (const o of ["follow_up_at", "contact_name", "contact_email", "notes"])
|
|
38
|
+
e[o] !== n[o] && (r[o] = e[o].trim() || null);
|
|
39
|
+
return r;
|
|
40
|
+
}
|
|
41
|
+
function re(e) {
|
|
42
|
+
const n = new Date(e);
|
|
43
|
+
return Number.isNaN(n.getTime()) ? e : e.endsWith("T00:00:00Z") || e.endsWith("T00:00:00.000Z") ? n.toLocaleDateString(void 0, { timeZone: "UTC", dateStyle: "medium" }) : n.toLocaleString(void 0, { dateStyle: "medium", timeStyle: "short" });
|
|
44
|
+
}
|
|
45
|
+
function le() {
|
|
46
|
+
const e = /* @__PURE__ */ new Date(), n = (r) => String(r).padStart(2, "0");
|
|
47
|
+
return `${e.getFullYear()}-${n(e.getMonth() + 1)}-${n(e.getDate())}`;
|
|
48
|
+
}
|
|
49
|
+
function oe({ event: e, onDelete: n }) {
|
|
50
|
+
return /* @__PURE__ */ i("li", { className: `jp-timeline__item jp-timeline__item--${e.kind}`, children: [
|
|
51
|
+
/* @__PURE__ */ i("div", { className: "jp-timeline__head", children: [
|
|
52
|
+
/* @__PURE__ */ a("span", { className: "jp-timeline__kind", children: e.kind === "state" ? e.from_state ? `${k[e.from_state] ?? e.from_state} → ${k[e.to_state ?? ""] ?? e.to_state}` : `Added as ${k[e.to_state ?? ""] ?? e.to_state}` : g[e.kind] }),
|
|
53
|
+
/* @__PURE__ */ a("time", { className: "jp-timeline__when", dateTime: e.occurred_at, children: re(e.occurred_at) }),
|
|
54
|
+
n && /* @__PURE__ */ a(
|
|
55
|
+
"button",
|
|
56
|
+
{
|
|
57
|
+
type: "button",
|
|
58
|
+
className: "jp-timeline__delete",
|
|
59
|
+
onClick: n,
|
|
60
|
+
"aria-label": `Delete this ${g[e.kind].toLowerCase()}`,
|
|
61
|
+
children: "×"
|
|
62
|
+
}
|
|
63
|
+
)
|
|
64
|
+
] }),
|
|
65
|
+
e.note && /* @__PURE__ */ a("p", { className: "jp-timeline__note", children: e.note })
|
|
66
|
+
] });
|
|
67
|
+
}
|
|
68
|
+
function pe({ auth: e, jobId: n, state: r, tracking: o, onChanged: f }) {
|
|
69
|
+
const d = K(Z(o ?? ne)), [s, S] = l(d.current), [v, L] = l(!1), [B, E] = l(!1), [T, x] = l(null), [C, M] = l("note"), [m, D] = l(""), [$, Y] = l(le), [y, A] = l(!1), [F, p] = l(null), u = `events:${n}`, {
|
|
70
|
+
data: J,
|
|
71
|
+
loading: P,
|
|
72
|
+
error: R,
|
|
73
|
+
reload: N
|
|
74
|
+
} = V(u, () => I(n, e)), W = K(!1);
|
|
75
|
+
Q(() => {
|
|
76
|
+
if (!W.current) {
|
|
77
|
+
W.current = !0;
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
h(u), N();
|
|
81
|
+
}, [r]);
|
|
82
|
+
const O = ie(s, d.current), w = Object.keys(O).length > 0, c = (t, b) => {
|
|
83
|
+
E(!1), S((z) => ({ ...z, [t]: b }));
|
|
84
|
+
}, H = async () => {
|
|
85
|
+
if (!(!w || v)) {
|
|
86
|
+
L(!0), x(null);
|
|
87
|
+
try {
|
|
88
|
+
const t = await ee(n, O, e);
|
|
89
|
+
d.current = Z(t), S(d.current), E(!0), h(`job:${n}:`), f();
|
|
90
|
+
} catch (t) {
|
|
91
|
+
x(_(t, "Failed to save"));
|
|
92
|
+
} finally {
|
|
93
|
+
L(!1);
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}, U = async () => {
|
|
97
|
+
if (!(!m.trim() || y)) {
|
|
98
|
+
A(!0), p(null);
|
|
99
|
+
try {
|
|
100
|
+
await te(n, { kind: C, note: m.trim(), occurred_at: $ || void 0 }, e), D(""), h(u), N(), f();
|
|
101
|
+
} catch (t) {
|
|
102
|
+
p(_(t, "Failed to log it"));
|
|
103
|
+
} finally {
|
|
104
|
+
A(!1);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}, q = async (t) => {
|
|
108
|
+
p(null);
|
|
109
|
+
try {
|
|
110
|
+
await ae(n, t, e), h(u), N(), f();
|
|
111
|
+
} catch (b) {
|
|
112
|
+
p(_(b, "Failed to delete it"));
|
|
113
|
+
}
|
|
114
|
+
}, j = [...J ?? []].reverse();
|
|
115
|
+
return /* @__PURE__ */ i(G, { children: [
|
|
116
|
+
/* @__PURE__ */ i("section", { className: "jp-drawer__section", "data-testid": "tracking-panel", "data-state": r, children: [
|
|
117
|
+
/* @__PURE__ */ a("h3", { children: "Tracking" }),
|
|
118
|
+
/* @__PURE__ */ i(
|
|
119
|
+
"form",
|
|
120
|
+
{
|
|
121
|
+
className: "jp-tracking",
|
|
122
|
+
onSubmit: (t) => {
|
|
123
|
+
t.preventDefault(), H();
|
|
124
|
+
},
|
|
125
|
+
children: [
|
|
126
|
+
/* @__PURE__ */ i("label", { className: "jp-tracking__field", children: [
|
|
127
|
+
/* @__PURE__ */ a("span", { children: "Priority" }),
|
|
128
|
+
/* @__PURE__ */ i(
|
|
129
|
+
"select",
|
|
130
|
+
{
|
|
131
|
+
value: s.priority,
|
|
132
|
+
onChange: (t) => c("priority", t.target.value),
|
|
133
|
+
children: [
|
|
134
|
+
/* @__PURE__ */ a("option", { value: "", children: "—" }),
|
|
135
|
+
/* @__PURE__ */ a("option", { value: "1", children: "High" }),
|
|
136
|
+
/* @__PURE__ */ a("option", { value: "2", children: "Normal" }),
|
|
137
|
+
/* @__PURE__ */ a("option", { value: "3", children: "Low" })
|
|
138
|
+
]
|
|
139
|
+
}
|
|
140
|
+
)
|
|
141
|
+
] }),
|
|
142
|
+
/* @__PURE__ */ i("label", { className: "jp-tracking__field", children: [
|
|
143
|
+
/* @__PURE__ */ a("span", { children: "Follow up on" }),
|
|
144
|
+
/* @__PURE__ */ a(
|
|
145
|
+
"input",
|
|
146
|
+
{
|
|
147
|
+
type: "date",
|
|
148
|
+
value: s.follow_up_at,
|
|
149
|
+
onChange: (t) => c("follow_up_at", t.target.value),
|
|
150
|
+
"data-testid": "tracking-follow-up"
|
|
151
|
+
}
|
|
152
|
+
)
|
|
153
|
+
] }),
|
|
154
|
+
/* @__PURE__ */ i("label", { className: "jp-tracking__field", children: [
|
|
155
|
+
/* @__PURE__ */ a("span", { children: "Contact" }),
|
|
156
|
+
/* @__PURE__ */ a(
|
|
157
|
+
"input",
|
|
158
|
+
{
|
|
159
|
+
type: "text",
|
|
160
|
+
value: s.contact_name,
|
|
161
|
+
placeholder: "Recruiter or hiring manager",
|
|
162
|
+
maxLength: 200,
|
|
163
|
+
onChange: (t) => c("contact_name", t.target.value)
|
|
164
|
+
}
|
|
165
|
+
)
|
|
166
|
+
] }),
|
|
167
|
+
/* @__PURE__ */ i("label", { className: "jp-tracking__field", children: [
|
|
168
|
+
/* @__PURE__ */ a("span", { children: "Contact email" }),
|
|
169
|
+
/* @__PURE__ */ a(
|
|
170
|
+
"input",
|
|
171
|
+
{
|
|
172
|
+
type: "email",
|
|
173
|
+
value: s.contact_email,
|
|
174
|
+
maxLength: 320,
|
|
175
|
+
onChange: (t) => c("contact_email", t.target.value)
|
|
176
|
+
}
|
|
177
|
+
)
|
|
178
|
+
] }),
|
|
179
|
+
/* @__PURE__ */ i("label", { className: "jp-tracking__field jp-tracking__field--wide", children: [
|
|
180
|
+
/* @__PURE__ */ a("span", { children: "Notes" }),
|
|
181
|
+
/* @__PURE__ */ a(
|
|
182
|
+
"textarea",
|
|
183
|
+
{
|
|
184
|
+
rows: 3,
|
|
185
|
+
value: s.notes,
|
|
186
|
+
maxLength: 5e3,
|
|
187
|
+
onChange: (t) => c("notes", t.target.value)
|
|
188
|
+
}
|
|
189
|
+
)
|
|
190
|
+
] }),
|
|
191
|
+
/* @__PURE__ */ i("div", { className: "jp-tracking__actions", children: [
|
|
192
|
+
/* @__PURE__ */ a(
|
|
193
|
+
"button",
|
|
194
|
+
{
|
|
195
|
+
type: "submit",
|
|
196
|
+
className: "jp-drawer__cta jp-drawer__cta--primary",
|
|
197
|
+
disabled: !w || v,
|
|
198
|
+
"data-testid": "tracking-save",
|
|
199
|
+
children: v ? "Saving…" : "Save"
|
|
200
|
+
}
|
|
201
|
+
),
|
|
202
|
+
B && !w && /* @__PURE__ */ a("span", { className: "jp-muted", children: "Saved ✓" })
|
|
203
|
+
] }),
|
|
204
|
+
T && /* @__PURE__ */ a("p", { className: "jp-error", children: T })
|
|
205
|
+
]
|
|
206
|
+
}
|
|
207
|
+
)
|
|
208
|
+
] }),
|
|
209
|
+
/* @__PURE__ */ i("section", { className: "jp-drawer__section", "data-testid": "timeline", children: [
|
|
210
|
+
/* @__PURE__ */ a("h3", { children: "Timeline" }),
|
|
211
|
+
/* @__PURE__ */ i(
|
|
212
|
+
"form",
|
|
213
|
+
{
|
|
214
|
+
className: "jp-timeline__add",
|
|
215
|
+
onSubmit: (t) => {
|
|
216
|
+
t.preventDefault(), U();
|
|
217
|
+
},
|
|
218
|
+
children: [
|
|
219
|
+
/* @__PURE__ */ a(
|
|
220
|
+
"select",
|
|
221
|
+
{
|
|
222
|
+
value: C,
|
|
223
|
+
onChange: (t) => M(t.target.value),
|
|
224
|
+
"aria-label": "What happened",
|
|
225
|
+
children: Object.keys(g).map((t) => /* @__PURE__ */ a("option", { value: t, children: g[t] }, t))
|
|
226
|
+
}
|
|
227
|
+
),
|
|
228
|
+
/* @__PURE__ */ a(
|
|
229
|
+
"input",
|
|
230
|
+
{
|
|
231
|
+
type: "date",
|
|
232
|
+
value: $,
|
|
233
|
+
onChange: (t) => Y(t.target.value),
|
|
234
|
+
"aria-label": "When it happened"
|
|
235
|
+
}
|
|
236
|
+
),
|
|
237
|
+
/* @__PURE__ */ a(
|
|
238
|
+
"textarea",
|
|
239
|
+
{
|
|
240
|
+
className: "jp-timeline__add-note",
|
|
241
|
+
rows: 2,
|
|
242
|
+
value: m,
|
|
243
|
+
maxLength: 5e3,
|
|
244
|
+
placeholder: "Phone screen with Pat — next round is a system design loop",
|
|
245
|
+
onChange: (t) => D(t.target.value),
|
|
246
|
+
"aria-label": "What to log",
|
|
247
|
+
"data-testid": "timeline-note"
|
|
248
|
+
}
|
|
249
|
+
),
|
|
250
|
+
/* @__PURE__ */ a(
|
|
251
|
+
"button",
|
|
252
|
+
{
|
|
253
|
+
type: "submit",
|
|
254
|
+
className: "jp-drawer__cta",
|
|
255
|
+
disabled: !m.trim() || y,
|
|
256
|
+
"data-testid": "timeline-add",
|
|
257
|
+
children: y ? "Logging…" : "Log it"
|
|
258
|
+
}
|
|
259
|
+
)
|
|
260
|
+
]
|
|
261
|
+
}
|
|
262
|
+
),
|
|
263
|
+
F && /* @__PURE__ */ a("p", { className: "jp-error", children: F }),
|
|
264
|
+
P && /* @__PURE__ */ a("p", { className: "jp-muted", children: "Loading the timeline…" }),
|
|
265
|
+
R !== null && !P && /* @__PURE__ */ a("p", { className: "jp-error", children: _(R, "Failed to load the timeline") }),
|
|
266
|
+
j.length > 0 && /* @__PURE__ */ a("ol", { className: "jp-timeline", children: j.map((t) => /* @__PURE__ */ a(
|
|
267
|
+
oe,
|
|
268
|
+
{
|
|
269
|
+
event: t,
|
|
270
|
+
onDelete: t.kind === "state" ? void 0 : () => {
|
|
271
|
+
q(t.id);
|
|
272
|
+
}
|
|
273
|
+
},
|
|
274
|
+
t.id
|
|
275
|
+
)) }),
|
|
276
|
+
J && j.length === 0 && /* @__PURE__ */ a("p", { className: "jp-muted", children: "Nothing recorded yet. Postings tracked before the timeline existed start here." })
|
|
277
|
+
] })
|
|
278
|
+
] });
|
|
279
|
+
}
|
|
280
|
+
export {
|
|
281
|
+
pe as ApplicationTracking
|
|
282
|
+
};
|