@hadoku/jobplatform 3.42.66 → 3.42.67
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 → ApplicationTracking-DqGyNvqa.js} +2 -2
- package/dist/{ApplicationsList-DDjncd7P.js → ApplicationsList-DpngRfs5.js} +1 -1
- package/dist/ClipboardPalette-BE0vKatt.js +59 -0
- package/dist/InsightsPage-Cu5XjnLT.js +181 -0
- package/dist/{PacketDetail-KOXrbMqc.js → PacketDetail-CvwUpvvn.js} +1 -1
- package/dist/{PacketsList-llRBP10u.js → PacketsList-8q3k_RTG.js} +1 -1
- package/dist/{PipelineBoard-BLmNwNaq.js → PipelineBoard-BlszMNIX.js} +2 -2
- package/dist/ProfilePage-DPmqqHL0.js +370 -0
- package/dist/api/http.d.ts +11 -0
- package/dist/api/http.d.ts.map +1 -0
- package/dist/api/jobs.d.ts +5 -0
- package/dist/api/jobs.d.ts.map +1 -1
- package/dist/api/me.d.ts +88 -0
- package/dist/api/me.d.ts.map +1 -0
- package/dist/api/pipeline.d.ts +2 -2
- package/dist/api/pipeline.d.ts.map +1 -1
- package/dist/components/ClipboardPalette.d.ts +10 -0
- package/dist/components/ClipboardPalette.d.ts.map +1 -0
- package/dist/components/InsightsPage.d.ts +9 -0
- package/dist/components/InsightsPage.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/NearFilter.d.ts +20 -0
- package/dist/components/NearFilter.d.ts.map +1 -0
- package/dist/components/ProfilePage.d.ts +9 -0
- package/dist/components/ProfilePage.d.ts.map +1 -0
- package/dist/{entry-CFBqMGn5.js → entry-BMXuZ_2X.js} +1534 -1317
- package/dist/index.js +1 -1
- package/dist/pipeline-CxkrsA19.js +36 -0
- package/dist/style.css +1 -1
- package/package.json +2 -2
- package/dist/pipeline-C2hWQq1c.js +0 -47
package/dist/App.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../src/App.tsx"],"names":[],"mappings":"AAiCA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;
|
|
1
|
+
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../src/App.tsx"],"names":[],"mappings":"AAiCA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;AA2C/C;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,GAAG,CAAC,KAAK,GAAE,gBAAqB,2CAOvD"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsxs as i, Fragment as G, jsx as a } from "react/jsx-runtime";
|
|
2
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-
|
|
4
|
-
import { l as I, s as ee, a as te, d as ae } from "./pipeline-
|
|
3
|
+
import { u as V, i as h, J as X } from "./entry-BMXuZ_2X.js";
|
|
4
|
+
import { l as I, s as ee, a as te, d as ae } from "./pipeline-CxkrsA19.js";
|
|
5
5
|
const ne = {
|
|
6
6
|
notes: null,
|
|
7
7
|
priority: null,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as i, jsx as e, Fragment as K } from "react/jsx-runtime";
|
|
2
2
|
import { useState as _, useMemo as W, useCallback as Q, useEffect as V } from "react";
|
|
3
|
-
import { l as M, a as J, J as S, s as U, f as X, b as Z, u as ee, c as ne, d as te } from "./entry-
|
|
3
|
+
import { l as M, a as J, J as S, s as U, f as X, b as Z, u as ee, c as ne, d as te } from "./entry-BMXuZ_2X.js";
|
|
4
4
|
function F(r) {
|
|
5
5
|
return r.replace(/\*/g, " ").toLowerCase().replace(/n't\b/g, " not ").replace(/[^a-z0-9]+/g, " ").trim();
|
|
6
6
|
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { jsx as a, jsxs as d } from "react/jsx-runtime";
|
|
2
|
+
import { useState as s, useRef as f, useEffect as h } from "react";
|
|
3
|
+
import { u as _, k as j } from "./entry-BMXuZ_2X.js";
|
|
4
|
+
function y(e) {
|
|
5
|
+
const t = e.work_experience?.find((i) => i.current) ?? e.work_experience?.[0];
|
|
6
|
+
return [
|
|
7
|
+
["Name", e.name],
|
|
8
|
+
["Email", e.email],
|
|
9
|
+
["Phone", e.phone],
|
|
10
|
+
["Location", e.location],
|
|
11
|
+
["LinkedIn", e.linkedin],
|
|
12
|
+
["GitHub", e.github],
|
|
13
|
+
["Portfolio", e.portfolio],
|
|
14
|
+
["Current role", t ? [t.title, t.company].filter(Boolean).join(" at ") : ""],
|
|
15
|
+
["Headline", e.headline],
|
|
16
|
+
["Summary", e.summary]
|
|
17
|
+
].flatMap(([i, o]) => o?.trim() ? [{ label: i, value: o.trim() }] : []);
|
|
18
|
+
}
|
|
19
|
+
function x({ auth: e }) {
|
|
20
|
+
const { data: t, error: p } = _("applicant-profile", () => j(e)), [i, o] = s(null), [u, c] = s(!1), n = f(null);
|
|
21
|
+
if (h(
|
|
22
|
+
() => () => {
|
|
23
|
+
n.current && clearTimeout(n.current);
|
|
24
|
+
},
|
|
25
|
+
[]
|
|
26
|
+
), p || t === void 0) return null;
|
|
27
|
+
if (t === null)
|
|
28
|
+
return /* @__PURE__ */ a("p", { className: "jp-muted jp-palette__empty", children: "Fill in the Profile tab and your contact details appear here as one-click copies." });
|
|
29
|
+
const m = (r, l) => {
|
|
30
|
+
if (!navigator.clipboard) {
|
|
31
|
+
c(!0);
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
navigator.clipboard.writeText(l).then(
|
|
35
|
+
() => {
|
|
36
|
+
c(!1), o(r), n.current && clearTimeout(n.current), n.current = setTimeout(() => o(null), 1500);
|
|
37
|
+
},
|
|
38
|
+
() => c(!0)
|
|
39
|
+
);
|
|
40
|
+
};
|
|
41
|
+
return /* @__PURE__ */ d("div", { className: "jp-palette", "data-testid": "clipboard-palette", children: [
|
|
42
|
+
/* @__PURE__ */ a("span", { className: "jp-palette__label", children: "Quick copy" }),
|
|
43
|
+
/* @__PURE__ */ a("div", { className: "jp-palette__chips", children: y(t).map(({ label: r, value: l }) => /* @__PURE__ */ a(
|
|
44
|
+
"button",
|
|
45
|
+
{
|
|
46
|
+
type: "button",
|
|
47
|
+
className: `jp-palette__chip${i === r ? " jp-palette__chip--copied" : ""}`,
|
|
48
|
+
title: l,
|
|
49
|
+
onClick: () => m(r, l),
|
|
50
|
+
children: i === r ? "Copied ✓" : r
|
|
51
|
+
},
|
|
52
|
+
r
|
|
53
|
+
)) }),
|
|
54
|
+
u && /* @__PURE__ */ a("p", { className: "jp-error", children: "The browser refused the clipboard — copy from the Profile tab." })
|
|
55
|
+
] });
|
|
56
|
+
}
|
|
57
|
+
export {
|
|
58
|
+
x as ClipboardPalette
|
|
59
|
+
};
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
import { jsx as e, jsxs as n } from "react/jsx-runtime";
|
|
2
|
+
import { u as _, J as j, j as g } from "./entry-BMXuZ_2X.js";
|
|
3
|
+
const o = (s) => s === null ? "—" : `${Math.round(s * 100)}%`;
|
|
4
|
+
function h(s) {
|
|
5
|
+
return (/* @__PURE__ */ new Date(`${s}T00:00:00Z`)).toLocaleDateString(void 0, { month: "short", day: "numeric", timeZone: "UTC" });
|
|
6
|
+
}
|
|
7
|
+
function d({ label: s, value: i, detail: c }) {
|
|
8
|
+
return /* @__PURE__ */ n("div", { className: "jp-ins__stat", children: [
|
|
9
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__stat-label", children: s }),
|
|
10
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__stat-value", children: i }),
|
|
11
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__stat-detail", children: c })
|
|
12
|
+
] });
|
|
13
|
+
}
|
|
14
|
+
function m({
|
|
15
|
+
rows: s,
|
|
16
|
+
label: i
|
|
17
|
+
}) {
|
|
18
|
+
const c = Math.max(1, ...s.map((l) => l.value));
|
|
19
|
+
return /* @__PURE__ */ e("ul", { className: "jp-ins__bars", "aria-label": i, children: s.map((l) => /* @__PURE__ */ n("li", { className: "jp-ins__bar-row", title: `${l.name}: ${l.value}`, children: [
|
|
20
|
+
/* @__PURE__ */ n("span", { className: "jp-ins__bar-name", children: [
|
|
21
|
+
l.name,
|
|
22
|
+
l.note && /* @__PURE__ */ n("span", { className: "jp-ins__bar-note", children: [
|
|
23
|
+
" ",
|
|
24
|
+
l.note
|
|
25
|
+
] })
|
|
26
|
+
] }),
|
|
27
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__bar-track", children: /* @__PURE__ */ e(
|
|
28
|
+
"span",
|
|
29
|
+
{
|
|
30
|
+
className: `jp-ins__bar${l.marked ? " jp-ins__bar--marked" : ""}`,
|
|
31
|
+
style: { width: `${l.value / c * 100}%` }
|
|
32
|
+
}
|
|
33
|
+
) }),
|
|
34
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__bar-value", children: l.value })
|
|
35
|
+
] }, l.name)) });
|
|
36
|
+
}
|
|
37
|
+
function k({ weeks: s }) {
|
|
38
|
+
const i = Math.max(1, ...s.map((a) => a.count)), c = s.reduce((a, t, p) => t.count > s[a].count ? p : a, 0), l = s.reduce((a, t) => a + t.count, 0);
|
|
39
|
+
return /* @__PURE__ */ n("figure", { className: "jp-ins__weekly", children: [
|
|
40
|
+
/* @__PURE__ */ e("div", { className: "jp-ins__cols", role: "list", "aria-label": "Applications per week", children: s.map((a, t) => {
|
|
41
|
+
const p = a.count > 0 && (t === c || t === s.length - 1);
|
|
42
|
+
return /* @__PURE__ */ n(
|
|
43
|
+
"div",
|
|
44
|
+
{
|
|
45
|
+
className: "jp-ins__col",
|
|
46
|
+
role: "listitem",
|
|
47
|
+
"aria-label": `Week of ${h(a.week)}: ${a.count}`,
|
|
48
|
+
tabIndex: 0,
|
|
49
|
+
children: [
|
|
50
|
+
/* @__PURE__ */ n("span", { className: "jp-ins__col-tip", children: [
|
|
51
|
+
"Week of ",
|
|
52
|
+
h(a.week),
|
|
53
|
+
": ",
|
|
54
|
+
/* @__PURE__ */ e("strong", { children: a.count })
|
|
55
|
+
] }),
|
|
56
|
+
p && /* @__PURE__ */ e("span", { className: "jp-ins__col-value", children: a.count }),
|
|
57
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__col-bar", style: { height: `${a.count / i * 100}%` } })
|
|
58
|
+
]
|
|
59
|
+
},
|
|
60
|
+
a.week
|
|
61
|
+
);
|
|
62
|
+
}) }),
|
|
63
|
+
/* @__PURE__ */ e("div", { className: "jp-ins__axis", "aria-hidden": "true", children: s.map((a, t) => /* @__PURE__ */ e("span", { children: t % 3 === 0 || t === s.length - 1 ? h(a.week) : "" }, a.week)) }),
|
|
64
|
+
/* @__PURE__ */ n("figcaption", { className: "jp-muted", children: [
|
|
65
|
+
l,
|
|
66
|
+
" in the last ",
|
|
67
|
+
s.length,
|
|
68
|
+
" weeks"
|
|
69
|
+
] })
|
|
70
|
+
] });
|
|
71
|
+
}
|
|
72
|
+
const N = {
|
|
73
|
+
remote: "Remote",
|
|
74
|
+
hybrid: "Hybrid",
|
|
75
|
+
onsite: "On-site",
|
|
76
|
+
unknown: "Not stated"
|
|
77
|
+
};
|
|
78
|
+
function b({ auth: s }) {
|
|
79
|
+
const { data: i, loading: c, error: l } = _("insights", () => g(s));
|
|
80
|
+
if (!s.signedIn) return /* @__PURE__ */ e("p", { className: "jp-muted", children: "Insights are per-account — sign in." });
|
|
81
|
+
if (c) return /* @__PURE__ */ e("p", { className: "jp-muted", children: "Loading insights…" });
|
|
82
|
+
if (l || !i)
|
|
83
|
+
return /* @__PURE__ */ e("p", { className: "jp-error", children: l instanceof j ? l.message : "Failed to load insights" });
|
|
84
|
+
const { reached: a, rates: t } = i;
|
|
85
|
+
return Object.values(i.states).reduce((r, u) => r + u, 0) === 0 && a.applied === 0 ? /* @__PURE__ */ e("p", { className: "jp-muted", "data-testid": "insights-empty", children: "Nothing to summarise yet. Save, apply to and track postings, and this page fills in." }) : /* @__PURE__ */ n("div", { className: "jp-ins", "data-testid": "insights", children: [
|
|
86
|
+
/* @__PURE__ */ n("div", { className: "jp-ins__stats", children: [
|
|
87
|
+
/* @__PURE__ */ e(d, { label: "Applied", value: String(a.applied), detail: "postings, ever" }),
|
|
88
|
+
/* @__PURE__ */ e(
|
|
89
|
+
d,
|
|
90
|
+
{
|
|
91
|
+
label: "Response rate",
|
|
92
|
+
value: o(t.response),
|
|
93
|
+
detail: `${a.responded} heard back`
|
|
94
|
+
}
|
|
95
|
+
),
|
|
96
|
+
/* @__PURE__ */ e(
|
|
97
|
+
d,
|
|
98
|
+
{
|
|
99
|
+
label: "Interview rate",
|
|
100
|
+
value: o(t.interview),
|
|
101
|
+
detail: `${a.interviewed} interviewed`
|
|
102
|
+
}
|
|
103
|
+
),
|
|
104
|
+
/* @__PURE__ */ e(
|
|
105
|
+
d,
|
|
106
|
+
{
|
|
107
|
+
label: "Offer rate",
|
|
108
|
+
value: o(t.offer),
|
|
109
|
+
detail: `${a.offered} offer${a.offered === 1 ? "" : "s"}`
|
|
110
|
+
}
|
|
111
|
+
)
|
|
112
|
+
] }),
|
|
113
|
+
/* @__PURE__ */ n("section", { className: "jp-ins__panel", children: [
|
|
114
|
+
/* @__PURE__ */ e("h3", { children: "Funnel" }),
|
|
115
|
+
/* @__PURE__ */ e(
|
|
116
|
+
m,
|
|
117
|
+
{
|
|
118
|
+
label: "Postings that reached each stage",
|
|
119
|
+
rows: [
|
|
120
|
+
{ name: "Applied", value: a.applied },
|
|
121
|
+
{ name: "Heard back", value: a.responded },
|
|
122
|
+
{ name: "Interviewed", value: a.interviewed },
|
|
123
|
+
{ name: "Offered", value: a.offered }
|
|
124
|
+
]
|
|
125
|
+
}
|
|
126
|
+
)
|
|
127
|
+
] }),
|
|
128
|
+
/* @__PURE__ */ n("section", { className: "jp-ins__panel", children: [
|
|
129
|
+
/* @__PURE__ */ e("h3", { children: "Weekly pace" }),
|
|
130
|
+
/* @__PURE__ */ e(k, { weeks: i.weekly_applied })
|
|
131
|
+
] }),
|
|
132
|
+
i.workplace.length > 0 && /* @__PURE__ */ n("section", { className: "jp-ins__panel", children: [
|
|
133
|
+
/* @__PURE__ */ e("h3", { children: "Where you applied" }),
|
|
134
|
+
/* @__PURE__ */ e(
|
|
135
|
+
m,
|
|
136
|
+
{
|
|
137
|
+
label: "Applications by workplace type",
|
|
138
|
+
rows: i.workplace.map((r) => ({
|
|
139
|
+
name: N[r.workplace_type] ?? r.workplace_type,
|
|
140
|
+
value: r.count
|
|
141
|
+
}))
|
|
142
|
+
}
|
|
143
|
+
)
|
|
144
|
+
] }),
|
|
145
|
+
i.skills.length > 0 && /* @__PURE__ */ n("section", { className: "jp-ins__panel jp-ins__panel--wide", children: [
|
|
146
|
+
/* @__PURE__ */ e("h3", { children: "What your pipeline asks for" }),
|
|
147
|
+
/* @__PURE__ */ n("p", { className: "jp-muted", children: [
|
|
148
|
+
"Across ",
|
|
149
|
+
i.skill_postings,
|
|
150
|
+
" posting",
|
|
151
|
+
i.skill_postings === 1 ? "" : "s",
|
|
152
|
+
" you are tracking."
|
|
153
|
+
] }),
|
|
154
|
+
/* @__PURE__ */ n("div", { className: "jp-ins__legend", "aria-hidden": "true", children: [
|
|
155
|
+
/* @__PURE__ */ n("span", { children: [
|
|
156
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__swatch jp-ins__swatch--marked" }),
|
|
157
|
+
" In your stack"
|
|
158
|
+
] }),
|
|
159
|
+
/* @__PURE__ */ n("span", { children: [
|
|
160
|
+
/* @__PURE__ */ e("span", { className: "jp-ins__swatch" }),
|
|
161
|
+
" Not in any profile's stack"
|
|
162
|
+
] })
|
|
163
|
+
] }),
|
|
164
|
+
/* @__PURE__ */ e(
|
|
165
|
+
m,
|
|
166
|
+
{
|
|
167
|
+
label: "Skills by how many tracked postings name them",
|
|
168
|
+
rows: i.skills.map((r) => ({
|
|
169
|
+
name: r.skill,
|
|
170
|
+
value: r.postings,
|
|
171
|
+
marked: r.in_stack,
|
|
172
|
+
note: r.in_stack ? "✓" : void 0
|
|
173
|
+
}))
|
|
174
|
+
}
|
|
175
|
+
)
|
|
176
|
+
] })
|
|
177
|
+
] });
|
|
178
|
+
}
|
|
179
|
+
export {
|
|
180
|
+
b as InsightsPage
|
|
181
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as t, jsx as a, Fragment as d } from "react/jsx-runtime";
|
|
2
2
|
import { useState as i, useEffect as _ } from "react";
|
|
3
|
-
import { g as y, J as b, D as v } from "./entry-
|
|
3
|
+
import { g as y, J as b, D as v } from "./entry-BMXuZ_2X.js";
|
|
4
4
|
import { g, p as E, a as P } from "./packets-BfqJIYHB.js";
|
|
5
5
|
function L({ auth: f, jobId: m, slug: n, onClose: s }) {
|
|
6
6
|
const [e, h] = i(null), [o, k] = i(null), [r, j] = i(null), [p, u] = i(null);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as n, jsxs as l, Fragment as R } from "react/jsx-runtime";
|
|
2
2
|
import { useState as f, useEffect as x, useMemo as q } from "react";
|
|
3
|
-
import { u as U, i as m, J as w, h as J } from "./entry-
|
|
4
|
-
import { g as B } from "./pipeline-
|
|
3
|
+
import { u as U, i as m, J as w, h as J } from "./entry-BMXuZ_2X.js";
|
|
4
|
+
import { g as B } from "./pipeline-CxkrsA19.js";
|
|
5
5
|
const F = [
|
|
6
6
|
{ state: "interested", label: "Interested" },
|
|
7
7
|
{ state: "saved", label: "Saved" },
|
|
@@ -0,0 +1,370 @@
|
|
|
1
|
+
import { jsx as a, jsxs as c } from "react/jsx-runtime";
|
|
2
|
+
import { useState as y, useEffect as R } from "react";
|
|
3
|
+
import { u as A, k as F, m as P, J as L, n as M, i as C, o as w, p as D } from "./entry-BMXuZ_2X.js";
|
|
4
|
+
const N = (e, n) => e instanceof L ? e.message : n, Y = [
|
|
5
|
+
{ key: "name", label: "Full name" },
|
|
6
|
+
{ key: "email", label: "Email", type: "email" },
|
|
7
|
+
{ key: "phone", label: "Phone", type: "tel" },
|
|
8
|
+
{ key: "location", label: "Location", hint: 'As forms should read it — "Seattle, WA"' },
|
|
9
|
+
{ key: "headline", label: "Headline", hint: '"Staff engineer, distributed systems"' },
|
|
10
|
+
{ key: "linkedin", label: "LinkedIn URL", type: "url" },
|
|
11
|
+
{ key: "github", label: "GitHub URL", type: "url" },
|
|
12
|
+
{ key: "portfolio", label: "Portfolio / website", type: "url" }
|
|
13
|
+
], H = [
|
|
14
|
+
"phone",
|
|
15
|
+
"location",
|
|
16
|
+
"headline",
|
|
17
|
+
"summary",
|
|
18
|
+
"linkedin",
|
|
19
|
+
"github",
|
|
20
|
+
"portfolio"
|
|
21
|
+
], E = { name: "", email: "" }, m = (e) => typeof e == "string" || typeof e == "number" ? String(e) : "";
|
|
22
|
+
function J(e, n) {
|
|
23
|
+
const i = { ...e ?? {}, ...n };
|
|
24
|
+
i.name = i.name.trim(), i.email = i.email.trim();
|
|
25
|
+
for (const t of H) {
|
|
26
|
+
const r = i[t];
|
|
27
|
+
typeof r == "string" && !r.trim() ? delete i[t] : typeof r == "string" && (i[t] = r.trim());
|
|
28
|
+
}
|
|
29
|
+
return i.work_experience = (n.work_experience ?? []).filter((t) => t.company.trim()), i.education = (n.education ?? []).filter((t) => t.school.trim()), i;
|
|
30
|
+
}
|
|
31
|
+
const $ = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
|
|
32
|
+
function x({
|
|
33
|
+
label: e,
|
|
34
|
+
month: n,
|
|
35
|
+
year: i,
|
|
36
|
+
onChange: t
|
|
37
|
+
}) {
|
|
38
|
+
const r = m(n), s = /^\d+$/.test(r) ? String(Number(r)) : r, u = s === "" || /^\d+$/.test(s);
|
|
39
|
+
return /* @__PURE__ */ c("span", { className: "jp-me__when", children: [
|
|
40
|
+
/* @__PURE__ */ c(
|
|
41
|
+
"select",
|
|
42
|
+
{
|
|
43
|
+
"aria-label": `${e} month`,
|
|
44
|
+
value: s,
|
|
45
|
+
onChange: (p) => t(p.target.value, m(i)),
|
|
46
|
+
children: [
|
|
47
|
+
/* @__PURE__ */ a("option", { value: "", children: e }),
|
|
48
|
+
!u && /* @__PURE__ */ a("option", { value: s, children: s }),
|
|
49
|
+
$.map((p, _) => /* @__PURE__ */ a("option", { value: String(_ + 1), children: p }, p))
|
|
50
|
+
]
|
|
51
|
+
}
|
|
52
|
+
),
|
|
53
|
+
/* @__PURE__ */ a(
|
|
54
|
+
"input",
|
|
55
|
+
{
|
|
56
|
+
"aria-label": `${e} year`,
|
|
57
|
+
placeholder: "Year",
|
|
58
|
+
inputMode: "numeric",
|
|
59
|
+
maxLength: 4,
|
|
60
|
+
value: m(i),
|
|
61
|
+
onChange: (p) => t(m(n), p.target.value)
|
|
62
|
+
}
|
|
63
|
+
)
|
|
64
|
+
] });
|
|
65
|
+
}
|
|
66
|
+
function B({
|
|
67
|
+
row: e,
|
|
68
|
+
onChange: n,
|
|
69
|
+
onRemove: i
|
|
70
|
+
}) {
|
|
71
|
+
return /* @__PURE__ */ c("fieldset", { className: "jp-me__row", children: [
|
|
72
|
+
/* @__PURE__ */ a(
|
|
73
|
+
"input",
|
|
74
|
+
{
|
|
75
|
+
"aria-label": "Company",
|
|
76
|
+
placeholder: "Company",
|
|
77
|
+
value: e.company,
|
|
78
|
+
onChange: (t) => n({ ...e, company: t.target.value })
|
|
79
|
+
}
|
|
80
|
+
),
|
|
81
|
+
/* @__PURE__ */ a(
|
|
82
|
+
"input",
|
|
83
|
+
{
|
|
84
|
+
"aria-label": "Title",
|
|
85
|
+
placeholder: "Title",
|
|
86
|
+
value: m(e.title),
|
|
87
|
+
onChange: (t) => n({ ...e, title: t.target.value })
|
|
88
|
+
}
|
|
89
|
+
),
|
|
90
|
+
/* @__PURE__ */ a(
|
|
91
|
+
x,
|
|
92
|
+
{
|
|
93
|
+
label: "Start",
|
|
94
|
+
month: e.start_month,
|
|
95
|
+
year: e.start_year,
|
|
96
|
+
onChange: (t, r) => n({ ...e, start_month: t, start_year: r })
|
|
97
|
+
}
|
|
98
|
+
),
|
|
99
|
+
e.current ? /* @__PURE__ */ a("span", { className: "jp-me__present", children: "Present" }) : /* @__PURE__ */ a(
|
|
100
|
+
x,
|
|
101
|
+
{
|
|
102
|
+
label: "End",
|
|
103
|
+
month: e.end_month,
|
|
104
|
+
year: e.end_year,
|
|
105
|
+
onChange: (t, r) => n({ ...e, end_month: t, end_year: r })
|
|
106
|
+
}
|
|
107
|
+
),
|
|
108
|
+
/* @__PURE__ */ c("label", { className: "jp-me__check", children: [
|
|
109
|
+
/* @__PURE__ */ a(
|
|
110
|
+
"input",
|
|
111
|
+
{
|
|
112
|
+
type: "checkbox",
|
|
113
|
+
checked: !!e.current,
|
|
114
|
+
onChange: (t) => n({ ...e, current: t.target.checked })
|
|
115
|
+
}
|
|
116
|
+
),
|
|
117
|
+
"Current"
|
|
118
|
+
] }),
|
|
119
|
+
/* @__PURE__ */ a("button", { type: "button", className: "jp-me__remove", onClick: i, "aria-label": "Remove", children: "×" })
|
|
120
|
+
] });
|
|
121
|
+
}
|
|
122
|
+
function I({
|
|
123
|
+
row: e,
|
|
124
|
+
onChange: n,
|
|
125
|
+
onRemove: i
|
|
126
|
+
}) {
|
|
127
|
+
return /* @__PURE__ */ c("fieldset", { className: "jp-me__row", children: [
|
|
128
|
+
/* @__PURE__ */ a(
|
|
129
|
+
"input",
|
|
130
|
+
{
|
|
131
|
+
"aria-label": "School",
|
|
132
|
+
placeholder: "School",
|
|
133
|
+
value: e.school,
|
|
134
|
+
onChange: (t) => n({ ...e, school: t.target.value })
|
|
135
|
+
}
|
|
136
|
+
),
|
|
137
|
+
/* @__PURE__ */ a(
|
|
138
|
+
"input",
|
|
139
|
+
{
|
|
140
|
+
"aria-label": "Degree",
|
|
141
|
+
placeholder: "Degree",
|
|
142
|
+
value: m(e.degree),
|
|
143
|
+
onChange: (t) => n({ ...e, degree: t.target.value })
|
|
144
|
+
}
|
|
145
|
+
),
|
|
146
|
+
/* @__PURE__ */ a(
|
|
147
|
+
"input",
|
|
148
|
+
{
|
|
149
|
+
"aria-label": "Field of study",
|
|
150
|
+
placeholder: "Field of study",
|
|
151
|
+
value: m(e.discipline),
|
|
152
|
+
onChange: (t) => n({ ...e, discipline: t.target.value })
|
|
153
|
+
}
|
|
154
|
+
),
|
|
155
|
+
/* @__PURE__ */ a(
|
|
156
|
+
"input",
|
|
157
|
+
{
|
|
158
|
+
"aria-label": "Start year",
|
|
159
|
+
placeholder: "Start year",
|
|
160
|
+
inputMode: "numeric",
|
|
161
|
+
value: m(e.start_year),
|
|
162
|
+
onChange: (t) => n({ ...e, start_year: t.target.value })
|
|
163
|
+
}
|
|
164
|
+
),
|
|
165
|
+
/* @__PURE__ */ a(
|
|
166
|
+
"input",
|
|
167
|
+
{
|
|
168
|
+
"aria-label": "End year",
|
|
169
|
+
placeholder: "End year",
|
|
170
|
+
inputMode: "numeric",
|
|
171
|
+
value: m(e.end_year),
|
|
172
|
+
onChange: (t) => n({ ...e, end_year: t.target.value })
|
|
173
|
+
}
|
|
174
|
+
),
|
|
175
|
+
/* @__PURE__ */ a("button", { type: "button", className: "jp-me__remove", onClick: i, "aria-label": "Remove", children: "×" })
|
|
176
|
+
] });
|
|
177
|
+
}
|
|
178
|
+
function O({ auth: e }) {
|
|
179
|
+
const {
|
|
180
|
+
data: n,
|
|
181
|
+
loading: i,
|
|
182
|
+
error: t
|
|
183
|
+
} = A("applicant-profile", () => F(e)), [r, s] = y(null), [u, p] = y(!1), [_, f] = y(null), [v, g] = y(null);
|
|
184
|
+
if (R(() => {
|
|
185
|
+
n !== void 0 && r === null && s(n ?? E);
|
|
186
|
+
}, [n, r]), i || r === null)
|
|
187
|
+
return t ? /* @__PURE__ */ a("p", { className: "jp-error", children: N(t, "Failed to load") }) : /* @__PURE__ */ a("p", { className: "jp-muted", children: "Loading your profile…" });
|
|
188
|
+
const o = (l) => {
|
|
189
|
+
f(null), s((d) => ({ ...d ?? E, ...l }));
|
|
190
|
+
}, b = r.work_experience ?? [], j = r.education ?? [], T = async () => {
|
|
191
|
+
p(!0), g(null);
|
|
192
|
+
try {
|
|
193
|
+
const l = J(n ?? null, r), d = await M(l, e);
|
|
194
|
+
C("applicant-profile"), s(l), f(d);
|
|
195
|
+
} catch (l) {
|
|
196
|
+
g(N(l, "Failed to save"));
|
|
197
|
+
} finally {
|
|
198
|
+
p(!1);
|
|
199
|
+
}
|
|
200
|
+
};
|
|
201
|
+
return /* @__PURE__ */ c(
|
|
202
|
+
"form",
|
|
203
|
+
{
|
|
204
|
+
className: "jp-me__form",
|
|
205
|
+
onSubmit: (l) => {
|
|
206
|
+
l.preventDefault(), T();
|
|
207
|
+
},
|
|
208
|
+
"data-testid": "applicant-profile-form",
|
|
209
|
+
children: [
|
|
210
|
+
/* @__PURE__ */ a("p", { className: "jp-muted", children: "What an application form asks about you. The Fill extension fills from it, and the drawer's Quick copy reads it for the forms you fill by hand." }),
|
|
211
|
+
/* @__PURE__ */ c("div", { className: "jp-me__grid", children: [
|
|
212
|
+
Y.map((l) => /* @__PURE__ */ c("label", { className: "jp-me__field", children: [
|
|
213
|
+
/* @__PURE__ */ c("span", { children: [
|
|
214
|
+
l.label,
|
|
215
|
+
(l.key === "name" || l.key === "email") && " *"
|
|
216
|
+
] }),
|
|
217
|
+
/* @__PURE__ */ a(
|
|
218
|
+
"input",
|
|
219
|
+
{
|
|
220
|
+
type: l.type ?? "text",
|
|
221
|
+
value: m(r[l.key]),
|
|
222
|
+
required: l.key === "name" || l.key === "email",
|
|
223
|
+
placeholder: l.hint,
|
|
224
|
+
onChange: (d) => o({ [l.key]: d.target.value }),
|
|
225
|
+
"data-testid": `me-${l.key}`
|
|
226
|
+
}
|
|
227
|
+
)
|
|
228
|
+
] }, l.key)),
|
|
229
|
+
/* @__PURE__ */ c("label", { className: "jp-me__field jp-me__field--wide", children: [
|
|
230
|
+
/* @__PURE__ */ a("span", { children: "Summary" }),
|
|
231
|
+
/* @__PURE__ */ a(
|
|
232
|
+
"textarea",
|
|
233
|
+
{
|
|
234
|
+
rows: 4,
|
|
235
|
+
value: m(r.summary),
|
|
236
|
+
placeholder: "Two or three sentences for the 'tell us about yourself' box",
|
|
237
|
+
onChange: (l) => o({ summary: l.target.value })
|
|
238
|
+
}
|
|
239
|
+
)
|
|
240
|
+
] })
|
|
241
|
+
] }),
|
|
242
|
+
/* @__PURE__ */ a("h3", { className: "jp-me__subhead", children: "Work history" }),
|
|
243
|
+
b.map((l, d) => /* @__PURE__ */ a(
|
|
244
|
+
B,
|
|
245
|
+
{
|
|
246
|
+
row: l,
|
|
247
|
+
onChange: (k) => o({ work_experience: b.map((h, S) => S === d ? k : h) }),
|
|
248
|
+
onRemove: () => o({ work_experience: b.filter((k, h) => h !== d) })
|
|
249
|
+
},
|
|
250
|
+
d
|
|
251
|
+
)),
|
|
252
|
+
/* @__PURE__ */ a(
|
|
253
|
+
"button",
|
|
254
|
+
{
|
|
255
|
+
type: "button",
|
|
256
|
+
className: "jp-drawer__cta",
|
|
257
|
+
onClick: () => o({ work_experience: [...b, { company: "" }] }),
|
|
258
|
+
children: "Add a role"
|
|
259
|
+
}
|
|
260
|
+
),
|
|
261
|
+
/* @__PURE__ */ a("h3", { className: "jp-me__subhead", children: "Education" }),
|
|
262
|
+
j.map((l, d) => /* @__PURE__ */ a(
|
|
263
|
+
I,
|
|
264
|
+
{
|
|
265
|
+
row: l,
|
|
266
|
+
onChange: (k) => o({ education: j.map((h, S) => S === d ? k : h) }),
|
|
267
|
+
onRemove: () => o({ education: j.filter((k, h) => h !== d) })
|
|
268
|
+
},
|
|
269
|
+
d
|
|
270
|
+
)),
|
|
271
|
+
/* @__PURE__ */ a(
|
|
272
|
+
"button",
|
|
273
|
+
{
|
|
274
|
+
type: "button",
|
|
275
|
+
className: "jp-drawer__cta",
|
|
276
|
+
onClick: () => o({ education: [...j, { school: "" }] }),
|
|
277
|
+
children: "Add a school"
|
|
278
|
+
}
|
|
279
|
+
),
|
|
280
|
+
/* @__PURE__ */ c("div", { className: "jp-me__actions", children: [
|
|
281
|
+
/* @__PURE__ */ a(
|
|
282
|
+
"button",
|
|
283
|
+
{
|
|
284
|
+
type: "submit",
|
|
285
|
+
className: "jp-drawer__cta jp-drawer__cta--primary",
|
|
286
|
+
disabled: u,
|
|
287
|
+
"data-testid": "me-save",
|
|
288
|
+
children: u ? "Saving…" : "Save profile"
|
|
289
|
+
}
|
|
290
|
+
),
|
|
291
|
+
_ && /* @__PURE__ */ a("span", { className: "jp-muted", children: "Saved ✓" })
|
|
292
|
+
] }),
|
|
293
|
+
v && /* @__PURE__ */ a("p", { className: "jp-error", children: v })
|
|
294
|
+
]
|
|
295
|
+
}
|
|
296
|
+
);
|
|
297
|
+
}
|
|
298
|
+
function W({ auth: e }) {
|
|
299
|
+
const { data: n, loading: i, error: t, reload: r } = A(
|
|
300
|
+
"blocked-companies",
|
|
301
|
+
() => P(e)
|
|
302
|
+
), [s, u] = y(""), [p, _] = y(!1), [f, v] = y(null), g = async (o) => {
|
|
303
|
+
_(!0), v(null);
|
|
304
|
+
try {
|
|
305
|
+
await o(), C("blocked-companies"), C("jobs:"), r();
|
|
306
|
+
} catch (b) {
|
|
307
|
+
v(N(b, "Request failed"));
|
|
308
|
+
} finally {
|
|
309
|
+
_(!1);
|
|
310
|
+
}
|
|
311
|
+
};
|
|
312
|
+
return /* @__PURE__ */ c("div", { "data-testid": "blocked-companies", children: [
|
|
313
|
+
/* @__PURE__ */ a("p", { className: "jp-muted", children: "Their postings never reach your feed. Your pipeline and the State filter still find anything you already track." }),
|
|
314
|
+
/* @__PURE__ */ c(
|
|
315
|
+
"form",
|
|
316
|
+
{
|
|
317
|
+
className: "jp-me__block-add",
|
|
318
|
+
onSubmit: (o) => {
|
|
319
|
+
o.preventDefault(), s.trim() && g(() => w(s.trim(), e)).then(() => u(""));
|
|
320
|
+
},
|
|
321
|
+
children: [
|
|
322
|
+
/* @__PURE__ */ a(
|
|
323
|
+
"input",
|
|
324
|
+
{
|
|
325
|
+
"aria-label": "Company to hide",
|
|
326
|
+
placeholder: "Company name",
|
|
327
|
+
value: s,
|
|
328
|
+
onChange: (o) => u(o.target.value)
|
|
329
|
+
}
|
|
330
|
+
),
|
|
331
|
+
/* @__PURE__ */ a("button", { type: "submit", className: "jp-drawer__cta", disabled: p || !s.trim(), children: "Hide" })
|
|
332
|
+
]
|
|
333
|
+
}
|
|
334
|
+
),
|
|
335
|
+
f && /* @__PURE__ */ a("p", { className: "jp-error", children: f }),
|
|
336
|
+
i && /* @__PURE__ */ a("p", { className: "jp-muted", children: "Loading…" }),
|
|
337
|
+
t !== null && !i && /* @__PURE__ */ a("p", { className: "jp-error", children: N(t, "Failed to load hidden companies") }),
|
|
338
|
+
n && n.length === 0 && /* @__PURE__ */ a("p", { className: "jp-muted", children: "You haven't hidden anyone." }),
|
|
339
|
+
n && n.length > 0 && /* @__PURE__ */ a("ul", { className: "jp-me__blocked", children: n.map((o) => /* @__PURE__ */ c("li", { children: [
|
|
340
|
+
/* @__PURE__ */ a("span", { children: o.company }),
|
|
341
|
+
/* @__PURE__ */ a(
|
|
342
|
+
"button",
|
|
343
|
+
{
|
|
344
|
+
type: "button",
|
|
345
|
+
className: "jp-drawer__link",
|
|
346
|
+
disabled: p,
|
|
347
|
+
onClick: () => {
|
|
348
|
+
g(() => D(o.company, e));
|
|
349
|
+
},
|
|
350
|
+
children: "Show again"
|
|
351
|
+
}
|
|
352
|
+
)
|
|
353
|
+
] }, o.company_key)) })
|
|
354
|
+
] });
|
|
355
|
+
}
|
|
356
|
+
function G({ auth: e }) {
|
|
357
|
+
return e.signedIn ? /* @__PURE__ */ c("div", { className: "jp-me", children: [
|
|
358
|
+
/* @__PURE__ */ c("section", { className: "jp-me__section", children: [
|
|
359
|
+
/* @__PURE__ */ a("h2", { children: "About you" }),
|
|
360
|
+
/* @__PURE__ */ a(O, { auth: e })
|
|
361
|
+
] }),
|
|
362
|
+
/* @__PURE__ */ c("section", { className: "jp-me__section", children: [
|
|
363
|
+
/* @__PURE__ */ a("h2", { children: "Hidden companies" }),
|
|
364
|
+
/* @__PURE__ */ a(W, { auth: e })
|
|
365
|
+
] })
|
|
366
|
+
] }) : /* @__PURE__ */ a("p", { className: "jp-muted", children: "Your profile is per-account — sign in to edit it." });
|
|
367
|
+
}
|
|
368
|
+
export {
|
|
369
|
+
G as ProfilePage
|
|
370
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The worker's wrapped-response fetch, for the API modules written after
|
|
3
|
+
* jobs.ts (which keeps its own parseWrapped). Same contract: `{ success,
|
|
4
|
+
* data }` on success, a JobsApiError carrying the server's message otherwise.
|
|
5
|
+
*/
|
|
6
|
+
import { type Auth } from './auth';
|
|
7
|
+
export declare const BASE_URL = "/jobplatform/api";
|
|
8
|
+
export declare function call<T>(path: string, auth: Auth | undefined, init?: RequestInit, json?: boolean): Promise<T>;
|
|
9
|
+
/** A JSON body for `call`. */
|
|
10
|
+
export declare function jsonBody(method: string, body: unknown): RequestInit;
|
|
11
|
+
//# sourceMappingURL=http.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/api/http.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAe,KAAK,IAAI,EAAE,MAAM,QAAQ,CAAA;AAG/C,eAAO,MAAM,QAAQ,qBAAqB,CAAA;AAS1C,wBAAsB,IAAI,CAAC,CAAC,EAC1B,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,IAAI,GAAG,SAAS,EACtB,IAAI,GAAE,WAAgB,EACtB,IAAI,UAAQ,GACX,OAAO,CAAC,CAAC,CAAC,CAWZ;AAED,8BAA8B;AAC9B,wBAAgB,QAAQ,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,WAAW,CAEnE"}
|