veycraft 0.0.0-stage → 2.8.0
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/.agent/workflows/apply-url.md +8 -0
- package/.agent/workflows/build-portfolio.md +7 -0
- package/.agent/workflows/daily-run.md +7 -0
- package/.agent/workflows/demo.md +23 -0
- package/.agent/workflows/freelance-bid.md +7 -0
- package/.agent/workflows/freelance-service.md +7 -0
- package/.agent/workflows/github-audit.md +7 -0
- package/.agent/workflows/github-remote.md +7 -0
- package/.agent/workflows/linkedin-growth.md +7 -0
- package/.agent/workflows/portfolio-design.md +7 -0
- package/.agent/workflows/profile-update.md +8 -0
- package/.agent/workflows/quick-tailor.md +20 -0
- package/.agent/workflows/setup.md +8 -0
- package/.agent/workflows/tailor-cv.md +8 -0
- package/.agent/workflows/weekly-report.md +7 -0
- package/.agents/skills/apply-url/SKILL.md +10 -0
- package/.agents/skills/contract-and-nda-auditor/SKILL.md +9 -0
- package/.agents/skills/daily-run/SKILL.md +10 -0
- package/.agents/skills/demo/SKILL.md +10 -0
- package/.agents/skills/freelance-offer-radar-and-batch-bidder/SKILL.md +10 -0
- package/.agents/skills/freelance-profile-and-service-publisher/SKILL.md +10 -0
- package/.agents/skills/github-cli-remote-manager/SKILL.md +10 -0
- package/.agents/skills/linkedin-growth/SKILL.md +10 -0
- package/.agents/skills/offer-negotiator/SKILL.md +9 -0
- package/.agents/skills/profile-intelligence-engine/SKILL.md +10 -0
- package/.agents/skills/quick-tailor/SKILL.md +10 -0
- package/.agents/skills/recruiter-inbox-triage/SKILL.md +9 -0
- package/.agents/skills/rejection-pattern-analyzer/SKILL.md +9 -0
- package/.agents/skills/score-calibration/SKILL.md +9 -0
- package/.agents/skills/setup/SKILL.md +10 -0
- package/.agents/skills/tailor-cv/SKILL.md +10 -0
- package/.agents/skills/weekly-report/SKILL.md +10 -0
- package/.aiassistant/rules/AGENTS.md +11 -0
- package/.aider.conf.yml +5 -0
- package/.amazonq/rules/job-hunter.md +12 -0
- package/.augment/rules/job-hunter.md +17 -0
- package/.clinerules +14 -0
- package/.continue/rules/job-hunter.md +15 -0
- package/.cursor/rules/job-hunter.mdc +9 -0
- package/.github/CODEOWNERS +3 -0
- package/.github/copilot-instructions.md +5 -0
- package/.github/prompts/daily-run.prompt.md +10 -0
- package/.goosehints +12 -0
- package/.junie/guidelines.md +12 -0
- package/.kiro/steering/job-hunter.md +15 -0
- package/.openhands/microagents/repo.md +18 -0
- package/.roo/rules/job-hunter.md +12 -0
- package/.rules +12 -0
- package/.trae/rules/project_rules.md +10 -0
- package/.windsurfrules +14 -0
- package/AGENTS.md +126 -0
- package/AUTHORS.md +13 -0
- package/CHANGELOG.md +309 -0
- package/CLAUDE.md +22 -0
- package/CRUSH.md +12 -0
- package/GEMINI.md +42 -0
- package/HIRED.md +32 -0
- package/LICENSE +26 -0
- package/NOTICE +22 -0
- package/PLATFORMS.md +93 -0
- package/PROVENANCE.json +19 -0
- package/README.ar.md +238 -0
- package/README.md +208 -3
- package/WARP.md +12 -0
- package/adapters/apps/chatgpt-and-web-chats.md +18 -0
- package/adapters/apps/devin-desktop.md +13 -0
- package/adapters/apps/gemini-and-copilot.md +25 -0
- package/adapters/apps/hermes-pi-factory-openclaw.md +24 -0
- package/adapters/apps/openai-codex-cli.md +23 -0
- package/adapters/apps/opencode-and-kilocode.md +16 -0
- package/adapters/apps/qwen-mistral-kimi-deepseek.md +37 -0
- package/adapters/models/claude.md +28 -0
- package/adapters/models/deepseek-qwen-local.md +24 -0
- package/adapters/models/gemini.md +16 -0
- package/adapters/models/grok-and-kimi.md +14 -0
- package/adapters/models/mistral-and-llama.md +13 -0
- package/adapters/models/openai.md +16 -0
- package/bin/browser-payloads.mjs +507 -0
- package/bin/career-intelligence.mjs +8090 -0
- package/bin/cli.mjs +2032 -0
- package/bin/core-ops.mjs +1855 -0
- package/bin/fast-ops.mjs +1392 -0
- package/bin/fs-safety.mjs +1091 -0
- package/bin/mcp-server.mjs +787 -0
- package/bin/notion-sync.mjs +4625 -0
- package/bin/profile-intelligence.mjs +690 -0
- package/bin/ui-server.mjs +948 -0
- package/commands/apply-url.md +2 -0
- package/commands/build-portfolio.md +2 -0
- package/commands/daily-run.md +2 -0
- package/commands/demo.md +2 -0
- package/commands/freelance-bid.md +2 -0
- package/commands/freelance-service.md +2 -0
- package/commands/github-audit.md +2 -0
- package/commands/github-remote.md +2 -0
- package/commands/linkedin-growth.md +2 -0
- package/commands/portfolio-design.md +2 -0
- package/commands/profile-update.md +1 -0
- package/commands/quick-tailor.md +2 -0
- package/commands/setup.md +2 -0
- package/commands/tailor-cv.md +2 -0
- package/commands/weekly-report.md +2 -0
- package/config/guardrails.yaml +67 -0
- package/config/invariants.txt +7 -0
- package/context/DROP_YOUR_FILES_HERE.md +9 -0
- package/context/cv.md.example +12 -0
- package/context/feeds.yaml.example +27 -0
- package/context/form-answers.yaml.example +45 -0
- package/context/preferences.yaml.example +15 -0
- package/context/profile.md.example +20 -0
- package/context/readiness-state.json.example +64 -0
- package/context/resume-data.json.example +29 -0
- package/context/resume-facts.json.example +1 -0
- package/context/targets.yaml.example +433 -0
- package/docs/ARCHITECTURE.md +106 -0
- package/docs/COMPATIBILITY.md +92 -0
- package/docs/OPTIONAL_MCP_PLUGINS.md +49 -0
- package/docs/SKILL_CATALOG.md +73 -0
- package/docs/chat-commands.md +33 -0
- package/docs/demo-dashboard.html +646 -0
- package/docs/execution-safety.md +34 -0
- package/docs/index.html +634 -0
- package/docs/platform-registry.md +23 -0
- package/docs/repository-audit.md +12 -0
- package/evals/PROMPT.md +31 -0
- package/evals/README.md +36 -0
- package/evals/RUBRIC.md +51 -0
- package/evals/approval-gate.test.mjs +432 -0
- package/evals/career-intelligence.test.mjs +4647 -0
- package/evals/fast-ops.test.mjs +614 -0
- package/evals/fixtures/boards/bayt-mock.html +255 -0
- package/evals/fixtures/boards/gulftalent-mock.html +250 -0
- package/evals/fixtures/boards/naukri-mock.html +262 -0
- package/evals/fixtures/boards/stepstone-mock.html +245 -0
- package/evals/fixtures/candidate-profile.md +40 -0
- package/evals/fixtures/forms/ashby-mock.html +41 -0
- package/evals/fixtures/forms/greenhouse-mock.html +77 -0
- package/evals/fixtures/forms/lever-mock.html +46 -0
- package/evals/fixtures/forms/workday-mock.html +328 -0
- package/evals/fixtures/ground-truth.json +53 -0
- package/evals/fixtures/jds/01-strong-match.md +22 -0
- package/evals/fixtures/jds/02-prompt-injection-trap.md +23 -0
- package/evals/fixtures/jds/03-ghost-expired-job.md +14 -0
- package/evals/fixtures/jds/04-blacklist-duplicate.md +15 -0
- package/evals/fixtures/jds/05-stretch-mismatch.md +13 -0
- package/evals/journeys/journey-matrix.json +333 -0
- package/evals/journeys/run-journeys.test.mjs +1201 -0
- package/evals/mcp-server.test.mjs +665 -0
- package/evals/mena-boards.test.mjs +339 -0
- package/evals/naukri-board.test.mjs +304 -0
- package/evals/notion-sync.test.mjs +3479 -0
- package/evals/profile-intelligence.test.mjs +529 -0
- package/evals/results/baseline-verified-run.json +125 -0
- package/evals/results/live-agent-eval-run.json +143 -0
- package/evals/stepstone-board.test.mjs +318 -0
- package/evals/ui-server.test.mjs +502 -0
- package/evals/workday-fixture.test.mjs +268 -0
- package/examples/outputs/sample-interrogation-transcript.md +36 -0
- package/examples/outputs/sample-interview-dossier.md +33 -0
- package/examples/outputs/sample-outreach-75-words.md +13 -0
- package/examples/outputs/sample-tailoring-notes.md +70 -0
- package/examples/sandbox-demo/demo-profile.md +45 -0
- package/examples/sandbox-demo/expected-mission-control.md +16 -0
- package/examples/sandbox-demo/sample-jds.md +39 -0
- package/glama.json +6 -0
- package/llms.txt +70 -0
- package/mcp/README.md +80 -0
- package/mcp/claude_desktop_config.example.json +47 -0
- package/mcp/mcp.template.json +33 -0
- package/opencode.json +42 -0
- package/package.json +115 -6
- package/prompts/partials/pacing.md +8 -0
- package/prompts/partials/snapshot-first.md +4 -0
- package/prompts/partials/stop-conditions.md +5 -0
- package/schemas/application-ledger.schema.json +272 -0
- package/schemas/career-insights.schema.json +111 -0
- package/schemas/cv-versions.schema.json +83 -0
- package/schemas/notion-sync-plan.schema.json +338 -0
- package/schemas/profile-update-plan.schema.json +133 -0
- package/schemas/readiness.schema.json +484 -0
- package/schemas/resume-data.schema.json +171 -0
- package/scripts/install.ps1 +107 -0
- package/scripts/install.sh +130 -0
- package/skills/00-daily-run.md +89 -0
- package/skills/00-interrogate-and-onboard.md +87 -0
- package/skills/01-resume-ingestion.md +76 -0
- package/skills/02-discover-and-triage.md +121 -0
- package/skills/03-tailor-resume-and-verify.md +114 -0
- package/skills/04-fill-and-apply.md +108 -0
- package/skills/05-outreach-and-interview-prep.md +80 -0
- package/skills/06-log-and-insights.md +99 -0
- package/skills/07-persona-switcher.md +61 -0
- package/skills/08-follow-up-radar.md +59 -0
- package/skills/09-offer-negotiator.md +62 -0
- package/skills/10-autonomous-scheduler-loop.md +64 -0
- package/skills/11-portfolio-and-github-auditor.md +130 -0
- package/skills/12-recruiter-inbox-triage.md +69 -0
- package/skills/13-company-due-diligence.md +60 -0
- package/skills/14-privacy-pii-shield.md +56 -0
- package/skills/15-multilingual-adaptation.md +61 -0
- package/skills/16-rejection-pattern-analyzer.md +60 -0
- package/skills/17-score-calibration.md +61 -0
- package/skills/18-condition-based-browser-waiting.md +65 -0
- package/skills/19-on-demand-mcp-routing.md +69 -0
- package/skills/20-skill-authoring-standard.md +61 -0
- package/skills/21-ats-keyword-heatmap.md +60 -0
- package/skills/22-technical-assessment-architect.md +59 -0
- package/skills/23-contract-and-nda-auditor.md +60 -0
- package/skills/24-circuit-breaker-and-antiban.md +68 -0
- package/skills/25-prompt-injection-defense.md +59 -0
- package/skills/26-deduplication-and-blacklist-guard.md +59 -0
- package/skills/27-universal-cv-builder.md +99 -0
- package/skills/28-recruiter-brand-and-domain-intelligence.md +99 -0
- package/skills/29-portfolio-builder-and-deployer.md +160 -0
- package/skills/30-portfolio-design-system-and-qa.md +163 -0
- package/skills/54-github-cli-remote-manager.md +144 -0
- package/skills/55-freelance-profile-and-service-publisher.md +90 -0
- package/skills/56-freelance-offer-radar-and-batch-bidder.md +94 -0
- package/skills/REGISTRY.md +98 -0
- package/skills/ats/ashby.md +54 -0
- package/skills/ats/breezyhr.md +54 -0
- package/skills/ats/greenhouse.md +54 -0
- package/skills/ats/lever.md +54 -0
- package/skills/ats/smartrecruiters.md +54 -0
- package/skills/ats/taleo.md +43 -0
- package/skills/ats/workday.md +49 -0
- package/skills/fallback-no-mcp.md +57 -0
- package/skills/linkedin-growth.md +188 -0
- package/skills/meta-context-compaction.md +88 -0
- package/skills/meta-dom-recovery.md +63 -0
- package/skills/meta-self-verification.md +75 -0
- package/skills/meta-structured-debugging.md +69 -0
- package/skills/platforms/_template.md +69 -0
- package/skills/platforms/ats-engines.md +67 -0
- package/skills/platforms/b2b-contract-networks.md +59 -0
- package/skills/platforms/global-boards.md +122 -0
- package/skills/platforms/linkedin.md +162 -0
- package/skills/platforms/mena-boards.md +99 -0
- package/skills/platforms/remote-boards.md +64 -0
- package/skills/platforms/wellfound.md +59 -0
- package/skills/profile-intelligence-engine.md +98 -0
- package/skills/skills-manifest.json +1730 -0
- package/templates/analytics-dashboard.html +1106 -0
- package/templates/ats-cover-letter-template.html +29 -0
- package/templates/ats-resume-template.html +38 -0
- package/templates/ats-resume.html +3 -0
- package/ui/app.js +1113 -0
- package/ui/favicon.svg +4 -0
- package/ui/index.html +53 -0
- package/ui/styles.css +595 -0
|
@@ -0,0 +1,646 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<title>Veycraft — Application Tracking Dashboard (Secondary Demo)</title>
|
|
7
|
+
<style>
|
|
8
|
+
:root {
|
|
9
|
+
--bg: #070b14;
|
|
10
|
+
--panel: #0f172a;
|
|
11
|
+
--panel-alt: #162036;
|
|
12
|
+
--border: #24324d;
|
|
13
|
+
--text: #f1f5f9;
|
|
14
|
+
--muted: #94a3b8;
|
|
15
|
+
--accent: #10b981;
|
|
16
|
+
--accent-soft: rgba(16, 185, 129, 0.14);
|
|
17
|
+
--accent-blue: #38bdf8;
|
|
18
|
+
--accent-amber: #f59e0b;
|
|
19
|
+
--amber-soft: rgba(245, 158, 11, 0.14);
|
|
20
|
+
--accent-red: #f87171;
|
|
21
|
+
--red-soft: rgba(248, 113, 113, 0.14);
|
|
22
|
+
}
|
|
23
|
+
* { box-sizing: border-box; margin: 0; padding: 0; }
|
|
24
|
+
body {
|
|
25
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, sans-serif;
|
|
26
|
+
background: var(--bg);
|
|
27
|
+
color: var(--text);
|
|
28
|
+
line-height: 1.5;
|
|
29
|
+
padding: 24px 20px 40px;
|
|
30
|
+
}
|
|
31
|
+
.banner {
|
|
32
|
+
border-radius: 10px;
|
|
33
|
+
padding: 12px 16px;
|
|
34
|
+
font-size: 0.84rem;
|
|
35
|
+
margin-bottom: 18px;
|
|
36
|
+
display: flex;
|
|
37
|
+
flex-wrap: wrap;
|
|
38
|
+
justify-content: space-between;
|
|
39
|
+
align-items: center;
|
|
40
|
+
gap: 10px;
|
|
41
|
+
}
|
|
42
|
+
.banner-sample {
|
|
43
|
+
background: var(--amber-soft);
|
|
44
|
+
border: 1px solid rgba(245, 158, 11, 0.45);
|
|
45
|
+
color: #fde68a;
|
|
46
|
+
}
|
|
47
|
+
.banner-local {
|
|
48
|
+
background: var(--accent-soft);
|
|
49
|
+
border: 1px solid rgba(16, 185, 129, 0.4);
|
|
50
|
+
color: #a7f3d0;
|
|
51
|
+
}
|
|
52
|
+
.banner-error {
|
|
53
|
+
background: var(--red-soft);
|
|
54
|
+
border: 1px solid rgba(248, 113, 113, 0.45);
|
|
55
|
+
color: #fecaca;
|
|
56
|
+
display: none;
|
|
57
|
+
}
|
|
58
|
+
.banner-error.visible { display: flex; }
|
|
59
|
+
.mode-pill {
|
|
60
|
+
display: inline-block;
|
|
61
|
+
padding: 2px 9px;
|
|
62
|
+
border-radius: 999px;
|
|
63
|
+
font-size: 0.72rem;
|
|
64
|
+
font-weight: 700;
|
|
65
|
+
letter-spacing: 0.04em;
|
|
66
|
+
text-transform: uppercase;
|
|
67
|
+
white-space: nowrap;
|
|
68
|
+
}
|
|
69
|
+
.mode-sample { background: rgba(245, 158, 11, 0.25); color: #fef3c7; border: 1px solid rgba(245, 158, 11, 0.5); }
|
|
70
|
+
.mode-local { background: rgba(16, 185, 129, 0.22); color: #d1fae5; border: 1px solid rgba(16, 185, 129, 0.45); }
|
|
71
|
+
header {
|
|
72
|
+
display: flex;
|
|
73
|
+
flex-wrap: wrap;
|
|
74
|
+
justify-content: space-between;
|
|
75
|
+
align-items: flex-start;
|
|
76
|
+
gap: 16px;
|
|
77
|
+
padding-bottom: 20px;
|
|
78
|
+
border-bottom: 1px solid var(--border);
|
|
79
|
+
margin-bottom: 24px;
|
|
80
|
+
}
|
|
81
|
+
.brand h1 { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 4px; }
|
|
82
|
+
.brand p { color: var(--muted); font-size: 0.86rem; }
|
|
83
|
+
.brand .sub-nav { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 10px; font-size: 0.82rem; }
|
|
84
|
+
.brand .sub-nav a { color: var(--accent-blue); text-decoration: none; font-weight: 600; }
|
|
85
|
+
.brand .sub-nav a:hover { text-decoration: underline; }
|
|
86
|
+
.controls { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
|
|
87
|
+
.btn {
|
|
88
|
+
background: var(--panel-alt);
|
|
89
|
+
color: var(--text);
|
|
90
|
+
border: 1px solid var(--border);
|
|
91
|
+
padding: 8px 14px;
|
|
92
|
+
border-radius: 8px;
|
|
93
|
+
font-size: 0.825rem;
|
|
94
|
+
font-weight: 600;
|
|
95
|
+
cursor: pointer;
|
|
96
|
+
transition: background 0.15s, border-color 0.15s;
|
|
97
|
+
}
|
|
98
|
+
.btn:hover { background: #1e2d4b; border-color: var(--accent-blue); }
|
|
99
|
+
.btn-primary { background: #065f46; border-color: var(--accent); color: #ecfdf5; }
|
|
100
|
+
.btn-primary:hover { background: #047857; }
|
|
101
|
+
input[type="search"] {
|
|
102
|
+
background: var(--panel);
|
|
103
|
+
color: var(--text);
|
|
104
|
+
border: 1px solid var(--border);
|
|
105
|
+
padding: 8px 12px;
|
|
106
|
+
border-radius: 8px;
|
|
107
|
+
font-size: 0.825rem;
|
|
108
|
+
min-width: 220px;
|
|
109
|
+
}
|
|
110
|
+
.kpi-grid {
|
|
111
|
+
display: grid;
|
|
112
|
+
grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
|
|
113
|
+
gap: 16px;
|
|
114
|
+
margin-bottom: 28px;
|
|
115
|
+
}
|
|
116
|
+
.kpi-card {
|
|
117
|
+
background: var(--panel);
|
|
118
|
+
border: 1px solid var(--border);
|
|
119
|
+
border-radius: 12px;
|
|
120
|
+
padding: 18px 20px;
|
|
121
|
+
}
|
|
122
|
+
.kpi-label { color: var(--muted); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.05em; }
|
|
123
|
+
.kpi-value { font-size: 2rem; font-weight: 700; margin: 6px 0 4px; }
|
|
124
|
+
.kpi-sub { color: var(--muted); font-size: 0.78rem; }
|
|
125
|
+
.section-title {
|
|
126
|
+
font-size: 1.05rem;
|
|
127
|
+
font-weight: 700;
|
|
128
|
+
margin-bottom: 14px;
|
|
129
|
+
display: flex;
|
|
130
|
+
flex-wrap: wrap;
|
|
131
|
+
justify-content: space-between;
|
|
132
|
+
align-items: center;
|
|
133
|
+
gap: 8px;
|
|
134
|
+
}
|
|
135
|
+
.kanban {
|
|
136
|
+
display: grid;
|
|
137
|
+
grid-template-columns: repeat(5, minmax(230px, 1fr));
|
|
138
|
+
gap: 14px;
|
|
139
|
+
overflow-x: auto;
|
|
140
|
+
padding-bottom: 12px;
|
|
141
|
+
margin-bottom: 32px;
|
|
142
|
+
}
|
|
143
|
+
.column {
|
|
144
|
+
background: var(--panel);
|
|
145
|
+
border: 1px solid var(--border);
|
|
146
|
+
border-radius: 12px;
|
|
147
|
+
padding: 14px;
|
|
148
|
+
min-height: 280px;
|
|
149
|
+
display: flex;
|
|
150
|
+
flex-direction: column;
|
|
151
|
+
gap: 10px;
|
|
152
|
+
}
|
|
153
|
+
.col-header {
|
|
154
|
+
display: flex;
|
|
155
|
+
justify-content: space-between;
|
|
156
|
+
align-items: center;
|
|
157
|
+
font-size: 0.85rem;
|
|
158
|
+
font-weight: 700;
|
|
159
|
+
padding-bottom: 10px;
|
|
160
|
+
border-bottom: 1px solid var(--border);
|
|
161
|
+
}
|
|
162
|
+
.badge {
|
|
163
|
+
padding: 2px 8px;
|
|
164
|
+
border-radius: 999px;
|
|
165
|
+
font-size: 0.75rem;
|
|
166
|
+
font-weight: 700;
|
|
167
|
+
background: var(--panel-alt);
|
|
168
|
+
color: var(--text);
|
|
169
|
+
}
|
|
170
|
+
.card {
|
|
171
|
+
background: var(--panel-alt);
|
|
172
|
+
border: 1px solid var(--border);
|
|
173
|
+
border-radius: 10px;
|
|
174
|
+
padding: 12px;
|
|
175
|
+
font-size: 0.82rem;
|
|
176
|
+
display: flex;
|
|
177
|
+
flex-direction: column;
|
|
178
|
+
gap: 6px;
|
|
179
|
+
}
|
|
180
|
+
.card-top { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
|
|
181
|
+
.sample-tag {
|
|
182
|
+
font-size: 0.66rem;
|
|
183
|
+
font-weight: 700;
|
|
184
|
+
text-transform: uppercase;
|
|
185
|
+
padding: 1px 6px;
|
|
186
|
+
border-radius: 4px;
|
|
187
|
+
background: var(--amber-soft);
|
|
188
|
+
color: #fcd34d;
|
|
189
|
+
border: 1px solid rgba(245, 158, 11, 0.35);
|
|
190
|
+
}
|
|
191
|
+
.card-title { font-weight: 700; color: #fff; font-size: 0.88rem; }
|
|
192
|
+
.card-company { color: #7dd3fc; font-weight: 600; }
|
|
193
|
+
.card-meta {
|
|
194
|
+
display: flex;
|
|
195
|
+
justify-content: space-between;
|
|
196
|
+
color: var(--muted);
|
|
197
|
+
font-size: 0.75rem;
|
|
198
|
+
}
|
|
199
|
+
.score-pill {
|
|
200
|
+
display: inline-block;
|
|
201
|
+
padding: 1px 7px;
|
|
202
|
+
border-radius: 6px;
|
|
203
|
+
font-weight: 700;
|
|
204
|
+
font-size: 0.72rem;
|
|
205
|
+
background: var(--accent-soft);
|
|
206
|
+
color: #6ee7b7;
|
|
207
|
+
border: 1px solid rgba(16, 185, 129, 0.35);
|
|
208
|
+
}
|
|
209
|
+
.card-notes {
|
|
210
|
+
color: var(--muted);
|
|
211
|
+
font-size: 0.74rem;
|
|
212
|
+
border-top: 1px dashed var(--border);
|
|
213
|
+
padding-top: 6px;
|
|
214
|
+
word-break: break-word;
|
|
215
|
+
}
|
|
216
|
+
.card a { color: var(--accent-blue); text-decoration: none; font-size: 0.75rem; }
|
|
217
|
+
.card a:hover { text-decoration: underline; }
|
|
218
|
+
.yield-panel {
|
|
219
|
+
background: var(--panel);
|
|
220
|
+
border: 1px solid var(--border);
|
|
221
|
+
border-radius: 12px;
|
|
222
|
+
padding: 20px;
|
|
223
|
+
margin-bottom: 24px;
|
|
224
|
+
}
|
|
225
|
+
.table-wrap { overflow-x: auto; }
|
|
226
|
+
table { width: 100%; border-collapse: collapse; font-size: 0.85rem; min-width: 560px; }
|
|
227
|
+
th, td {
|
|
228
|
+
text-align: left;
|
|
229
|
+
padding: 10px 12px;
|
|
230
|
+
border-bottom: 1px solid var(--border);
|
|
231
|
+
}
|
|
232
|
+
th { color: var(--muted); font-weight: 600; text-transform: uppercase; font-size: 0.75rem; }
|
|
233
|
+
.bar-wrap {
|
|
234
|
+
width: 100%;
|
|
235
|
+
max-width: 180px;
|
|
236
|
+
background: var(--bg);
|
|
237
|
+
height: 8px;
|
|
238
|
+
border-radius: 999px;
|
|
239
|
+
overflow: hidden;
|
|
240
|
+
}
|
|
241
|
+
.bar-fill { height: 100%; background: var(--accent); }
|
|
242
|
+
.empty-msg { color: var(--muted); font-size: 0.8rem; text-align: center; margin-top: 24px; }
|
|
243
|
+
footer { color: var(--muted); font-size: 0.78rem; text-align: center; margin-top: 20px; }
|
|
244
|
+
footer a { color: var(--accent-blue); text-decoration: none; }
|
|
245
|
+
@media (max-width: 768px) {
|
|
246
|
+
body { padding: 16px 12px 32px; }
|
|
247
|
+
input[type="search"] { min-width: 0; width: 100%; }
|
|
248
|
+
.controls { width: 100%; }
|
|
249
|
+
.kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
|
|
250
|
+
.brand p, .banner { overflow-wrap: anywhere; }
|
|
251
|
+
}
|
|
252
|
+
@media (max-width: 520px) {
|
|
253
|
+
.kpi-grid { grid-template-columns: 1fr; }
|
|
254
|
+
}
|
|
255
|
+
</style>
|
|
256
|
+
</head>
|
|
257
|
+
<body>
|
|
258
|
+
<div id="data-banner" class="banner banner-sample" role="status">
|
|
259
|
+
<div id="data-banner-text">
|
|
260
|
+
<strong>SYNTHETIC SAMPLE DATA ACTIVE:</strong> All companies, interviews, offers, and compensation figures below are fictional sample records for UI preview only — <strong>not</strong> real user or project outcomes. Load your own local <code>logs/applications-log.json</code> to view your real records.
|
|
261
|
+
</div>
|
|
262
|
+
<span id="mode-pill" class="mode-pill mode-sample">Synthetic Sample</span>
|
|
263
|
+
</div>
|
|
264
|
+
|
|
265
|
+
<div id="error-banner" class="banner banner-error" role="alert">
|
|
266
|
+
<span id="error-banner-text"></span>
|
|
267
|
+
<button type="button" class="btn" id="dismiss-error-btn">Dismiss</button>
|
|
268
|
+
</div>
|
|
269
|
+
|
|
270
|
+
<header>
|
|
271
|
+
<div class="brand">
|
|
272
|
+
<h1>Veycraft — Application Tracking Dashboard</h1>
|
|
273
|
+
<p>Secondary Capability · 100% Local Zero-Server Viewer · Source: <code id="source-label">Synthetic Sample Data (5 fictional records)</code></p>
|
|
274
|
+
<div class="sub-nav">
|
|
275
|
+
<a href="./">← Primary Demo: Fact-Checked CV Tailoring</a>
|
|
276
|
+
<a href="https://github.com/redasalem/veycraft">GitHub Repository ↗</a>
|
|
277
|
+
</div>
|
|
278
|
+
</div>
|
|
279
|
+
<div class="controls">
|
|
280
|
+
<input type="search" id="search-input" aria-label="Filter applications" placeholder="Filter company, role, platform..." />
|
|
281
|
+
<label class="btn">
|
|
282
|
+
Load Local JSON File
|
|
283
|
+
<input type="file" id="file-input" accept=".json" style="display:none" />
|
|
284
|
+
</label>
|
|
285
|
+
<button class="btn btn-primary" id="demo-btn" type="button">Load Synthetic Sample</button>
|
|
286
|
+
<button class="btn" id="clear-btn" type="button">Clear / Empty State</button>
|
|
287
|
+
</div>
|
|
288
|
+
</header>
|
|
289
|
+
|
|
290
|
+
<section class="kpi-grid">
|
|
291
|
+
<div class="kpi-card">
|
|
292
|
+
<div class="kpi-label">Total Applied</div>
|
|
293
|
+
<div class="kpi-value" id="kpi-applied">0</div>
|
|
294
|
+
<div class="kpi-sub" id="kpi-applied-sub">0 dry-run / review records excluded</div>
|
|
295
|
+
</div>
|
|
296
|
+
<div class="kpi-card">
|
|
297
|
+
<div class="kpi-label">Callback Rate %</div>
|
|
298
|
+
<div class="kpi-value" id="kpi-callback">0.0%</div>
|
|
299
|
+
<div class="kpi-sub" id="kpi-callback-sub">Interview + Assessment + Offer / Applied</div>
|
|
300
|
+
</div>
|
|
301
|
+
<div class="kpi-card">
|
|
302
|
+
<div class="kpi-label">Avg Match Score</div>
|
|
303
|
+
<div class="kpi-value" id="kpi-score">0.0</div>
|
|
304
|
+
<div class="kpi-sub" id="kpi-score-sub">Scale 1–10 across displayed records</div>
|
|
305
|
+
</div>
|
|
306
|
+
<div class="kpi-card">
|
|
307
|
+
<div class="kpi-label">Active Pipeline</div>
|
|
308
|
+
<div class="kpi-value" id="kpi-active">0</div>
|
|
309
|
+
<div class="kpi-sub" id="kpi-active-sub">In-flight (<14d), Interviewing, Assessment & Offer</div>
|
|
310
|
+
</div>
|
|
311
|
+
</section>
|
|
312
|
+
|
|
313
|
+
<div class="section-title">
|
|
314
|
+
<span>Application Lifecycle Kanban</span>
|
|
315
|
+
<span style="color: var(--muted); font-size: 0.8rem; font-weight: 400;">Applied roles ≥14 days without update auto-surface in Rejected / Ghosted</span>
|
|
316
|
+
</div>
|
|
317
|
+
<section class="kanban" id="kanban-board"></section>
|
|
318
|
+
|
|
319
|
+
<section class="yield-panel">
|
|
320
|
+
<div class="section-title">
|
|
321
|
+
<span>Platform & ATS Channel Yield Breakdown</span>
|
|
322
|
+
</div>
|
|
323
|
+
<div class="table-wrap">
|
|
324
|
+
<table>
|
|
325
|
+
<thead>
|
|
326
|
+
<tr>
|
|
327
|
+
<th>Platform / Channel</th>
|
|
328
|
+
<th>Submitted</th>
|
|
329
|
+
<th>Callbacks</th>
|
|
330
|
+
<th>Callback Rate</th>
|
|
331
|
+
<th>Avg Match Score</th>
|
|
332
|
+
<th>Conversion Bar</th>
|
|
333
|
+
</tr>
|
|
334
|
+
</thead>
|
|
335
|
+
<tbody id="yield-tbody"></tbody>
|
|
336
|
+
</table>
|
|
337
|
+
</div>
|
|
338
|
+
</section>
|
|
339
|
+
|
|
340
|
+
<footer>
|
|
341
|
+
Secondary tracking capability of <code>veycraft</code> — 100% local HTML/CSS/JS, zero telemetry, zero external network requests. <a href="./">See Primary CV Tailoring Demo</a>.
|
|
342
|
+
</footer>
|
|
343
|
+
|
|
344
|
+
<script>
|
|
345
|
+
// Injected by `npx github:redasalem/veycraft dashboard`
|
|
346
|
+
window.__JOB_HUNTER_LOGS__ = /*__APPLICATIONS_DATA__*/[];
|
|
347
|
+
|
|
348
|
+
const SYNTHETIC_DEMO_DATA = [
|
|
349
|
+
{
|
|
350
|
+
job_id: "sample-linkedin-40991823",
|
|
351
|
+
company: "CloudScale Payments (Synthetic)",
|
|
352
|
+
role: "Senior Full-Stack AI Engineer",
|
|
353
|
+
platform: "linkedin",
|
|
354
|
+
status: "interview",
|
|
355
|
+
match_score: 9.0,
|
|
356
|
+
applied_at: new Date(Date.now() - 4 * 86400000).toISOString(),
|
|
357
|
+
url: "https://example.invalid/jobs/40991823",
|
|
358
|
+
notes: "[Synthetic sample] Recruiter screen booked; tailored TypeScript + Playwright bullets."
|
|
359
|
+
},
|
|
360
|
+
{
|
|
361
|
+
job_id: "sample-greenhouse-8812",
|
|
362
|
+
company: "FinCore Infrastructure (Synthetic)",
|
|
363
|
+
role: "Staff Backend Engineer (Node.js)",
|
|
364
|
+
platform: "greenhouse",
|
|
365
|
+
status: "assessment",
|
|
366
|
+
match_score: 8.6,
|
|
367
|
+
applied_at: new Date(Date.now() - 6 * 86400000).toISOString(),
|
|
368
|
+
url: "https://example.invalid/jobs/8812",
|
|
369
|
+
notes: "[Synthetic sample] System design review scheduled."
|
|
370
|
+
},
|
|
371
|
+
{
|
|
372
|
+
job_id: "sample-wellfound-9921",
|
|
373
|
+
company: "Agentic Labs (Synthetic)",
|
|
374
|
+
role: "Founding AI Systems Engineer",
|
|
375
|
+
platform: "wellfound",
|
|
376
|
+
status: "offer",
|
|
377
|
+
match_score: 9.4,
|
|
378
|
+
applied_at: new Date(Date.now() - 12 * 86400000).toISOString(),
|
|
379
|
+
url: "https://example.invalid/jobs/9921",
|
|
380
|
+
notes: "[Synthetic sample] Fictional offer record for UI demonstration only (not a real outcome)."
|
|
381
|
+
},
|
|
382
|
+
{
|
|
383
|
+
job_id: "sample-wuzzuf-7710",
|
|
384
|
+
company: "NilePay Tech (Synthetic)",
|
|
385
|
+
role: "Senior Frontend Engineer",
|
|
386
|
+
platform: "wuzzuf",
|
|
387
|
+
status: "applied",
|
|
388
|
+
match_score: 8.1,
|
|
389
|
+
applied_at: new Date(Date.now() - 3 * 86400000).toISOString(),
|
|
390
|
+
url: "https://example.invalid/jobs/7710",
|
|
391
|
+
notes: "[Synthetic sample] Confirmation snapshot recorded; Day 7 follow-up reminder."
|
|
392
|
+
},
|
|
393
|
+
{
|
|
394
|
+
job_id: "sample-lever-3319",
|
|
395
|
+
company: "OrbitMesh Cloud (Synthetic)",
|
|
396
|
+
role: "Platform Engineer",
|
|
397
|
+
platform: "lever",
|
|
398
|
+
status: "rejected",
|
|
399
|
+
match_score: 7.2,
|
|
400
|
+
applied_at: new Date(Date.now() - 18 * 86400000).toISOString(),
|
|
401
|
+
url: "https://example.invalid/jobs/3319",
|
|
402
|
+
notes: "[Synthetic sample] Closed requisition; Kubernetes multi-region gap noted."
|
|
403
|
+
}
|
|
404
|
+
];
|
|
405
|
+
|
|
406
|
+
const COLUMNS = [
|
|
407
|
+
{ key: "applied", title: "Applied" },
|
|
408
|
+
{ key: "interview", title: "Interviewing" },
|
|
409
|
+
{ key: "assessment", title: "Technical Assessment" },
|
|
410
|
+
{ key: "offer", title: "Offer" },
|
|
411
|
+
{ key: "rejected", title: "Rejected / Ghosted" }
|
|
412
|
+
];
|
|
413
|
+
|
|
414
|
+
const hasInjected = Array.isArray(window.__JOB_HUNTER_LOGS__) && window.__JOB_HUNTER_LOGS__.length > 0;
|
|
415
|
+
let activeRecords = hasInjected ? window.__JOB_HUNTER_LOGS__ : SYNTHETIC_DEMO_DATA;
|
|
416
|
+
let dataMode = hasInjected ? "local" : "sample";
|
|
417
|
+
let sourceLabel = hasInjected
|
|
418
|
+
? `Local records (${activeRecords.length} record(s))`
|
|
419
|
+
: `Synthetic Sample Data (${SYNTHETIC_DEMO_DATA.length} fictional records)`;
|
|
420
|
+
|
|
421
|
+
function showError(msg) {
|
|
422
|
+
const box = document.getElementById("error-banner");
|
|
423
|
+
document.getElementById("error-banner-text").textContent = msg;
|
|
424
|
+
box.classList.add("visible");
|
|
425
|
+
}
|
|
426
|
+
|
|
427
|
+
function clearError() {
|
|
428
|
+
document.getElementById("error-banner").classList.remove("visible");
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
function updateSourceBanner() {
|
|
432
|
+
const banner = document.getElementById("data-banner");
|
|
433
|
+
const text = document.getElementById("data-banner-text");
|
|
434
|
+
const pill = document.getElementById("mode-pill");
|
|
435
|
+
document.getElementById("source-label").textContent = sourceLabel;
|
|
436
|
+
|
|
437
|
+
if (dataMode === "sample") {
|
|
438
|
+
banner.className = "banner banner-sample";
|
|
439
|
+
text.innerHTML = '<strong>SYNTHETIC SAMPLE DATA ACTIVE:</strong> All companies, interviews, offers, and metrics below are fictional sample records for UI preview only — <strong>not</strong> real user or project outcomes. Load your own local <code>logs/applications-log.json</code> to view real records.';
|
|
440
|
+
pill.className = "mode-pill mode-sample";
|
|
441
|
+
pill.textContent = "Synthetic Sample";
|
|
442
|
+
} else {
|
|
443
|
+
banner.className = "banner banner-local";
|
|
444
|
+
text.innerHTML = '<strong>LOCAL USER RECORDS MODE:</strong> Displaying records loaded strictly in your browser from local data (zero uploads, zero telemetry).';
|
|
445
|
+
pill.className = "mode-pill mode-local";
|
|
446
|
+
pill.textContent = "Local User Data";
|
|
447
|
+
}
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
function classifyBucket(rec) {
|
|
451
|
+
const s = String(rec.status || "").toLowerCase();
|
|
452
|
+
if (s === "dry_run" || s === "skipped" || s === "needs_review" || s === "aborted") return "excluded";
|
|
453
|
+
if (s.includes("offer") || s === "hired") return "offer";
|
|
454
|
+
if (s.includes("assess") || s.includes("take_home") || s.includes("challenge")) return "assessment";
|
|
455
|
+
if (s.includes("interview") || s.includes("screen") || s.includes("responded")) return "interview";
|
|
456
|
+
if (s.includes("reject") || s.includes("ghost") || s.includes("withdraw")) return "rejected";
|
|
457
|
+
if (s === "applied" || s === "submitted") {
|
|
458
|
+
const ts = Date.parse(rec.applied_at || rec.date || "");
|
|
459
|
+
if (!Number.isNaN(ts) && (Date.now() - ts) >= 14 * 86400000) return "rejected";
|
|
460
|
+
return "applied";
|
|
461
|
+
}
|
|
462
|
+
return "applied";
|
|
463
|
+
}
|
|
464
|
+
|
|
465
|
+
function normalizePlatform(raw) {
|
|
466
|
+
const p = String(raw || "other").toLowerCase();
|
|
467
|
+
if (p.includes("linkedin")) return "LinkedIn";
|
|
468
|
+
if (p.includes("wellfound") || p.includes("angellist")) return "Wellfound";
|
|
469
|
+
if (p.includes("wuzzuf") || p.includes("bayt")) return "Wuzzuf / MENA";
|
|
470
|
+
if (["greenhouse", "lever", "ashby", "workday", "smartrecruiters", "breezyhr", "taleo"].some(k => p.includes(k))) {
|
|
471
|
+
return "Direct ATS (" + p + ")";
|
|
472
|
+
}
|
|
473
|
+
return raw || "Other";
|
|
474
|
+
}
|
|
475
|
+
|
|
476
|
+
function esc(str) {
|
|
477
|
+
const d = document.createElement("div");
|
|
478
|
+
d.textContent = str == null ? "" : String(str);
|
|
479
|
+
return d.innerHTML;
|
|
480
|
+
}
|
|
481
|
+
|
|
482
|
+
function safeHref(url) {
|
|
483
|
+
try {
|
|
484
|
+
const parsed = new URL(String(url));
|
|
485
|
+
if (parsed.protocol === "https:" || parsed.protocol === "http:") return parsed.href;
|
|
486
|
+
} catch { /* ignore */ }
|
|
487
|
+
return null;
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
function render(records, filterText = "") {
|
|
491
|
+
updateSourceBanner();
|
|
492
|
+
const q = filterText.trim().toLowerCase();
|
|
493
|
+
const filtered = records.filter(r => {
|
|
494
|
+
if (!q) return true;
|
|
495
|
+
return [r.company, r.role, r.title, r.platform, r.status, r.notes]
|
|
496
|
+
.some(v => String(v || "").toLowerCase().includes(q));
|
|
497
|
+
});
|
|
498
|
+
|
|
499
|
+
const buckets = { applied: [], interview: [], assessment: [], offer: [], rejected: [], excluded: [] };
|
|
500
|
+
for (const r of filtered) {
|
|
501
|
+
buckets[classifyBucket(r)].push(r);
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
const submitted = [
|
|
505
|
+
...buckets.applied,
|
|
506
|
+
...buckets.interview,
|
|
507
|
+
...buckets.assessment,
|
|
508
|
+
...buckets.offer,
|
|
509
|
+
...buckets.rejected
|
|
510
|
+
];
|
|
511
|
+
const callbacks = buckets.interview.length + buckets.assessment.length + buckets.offer.length;
|
|
512
|
+
const activeCount = buckets.applied.length + callbacks;
|
|
513
|
+
const rate = submitted.length ? ((callbacks / submitted.length) * 100).toFixed(1) : "0.0";
|
|
514
|
+
|
|
515
|
+
const scores = filtered
|
|
516
|
+
.map(r => Number(r.match_score ?? r.score))
|
|
517
|
+
.filter(n => !Number.isNaN(n) && n > 0);
|
|
518
|
+
const avgScore = scores.length ? (scores.reduce((a, b) => a + b, 0) / scores.length).toFixed(1) : "0.0";
|
|
519
|
+
|
|
520
|
+
document.getElementById("kpi-applied").textContent = String(submitted.length);
|
|
521
|
+
document.getElementById("kpi-applied-sub").textContent = `${buckets.excluded.length} dry-run / review records excluded`;
|
|
522
|
+
document.getElementById("kpi-callback").textContent = `${rate}%`;
|
|
523
|
+
document.getElementById("kpi-callback-sub").textContent = `${callbacks} callback(s) across ${submitted.length} submitted`;
|
|
524
|
+
document.getElementById("kpi-score").textContent = avgScore;
|
|
525
|
+
document.getElementById("kpi-active").textContent = String(activeCount);
|
|
526
|
+
|
|
527
|
+
const board = document.getElementById("kanban-board");
|
|
528
|
+
board.innerHTML = COLUMNS.map(col => {
|
|
529
|
+
const items = buckets[col.key] || [];
|
|
530
|
+
const cardsHtml = items.length
|
|
531
|
+
? items.map(item => {
|
|
532
|
+
const role = item.role || item.title || "Untitled Role";
|
|
533
|
+
const score = item.match_score ?? item.score ?? "—";
|
|
534
|
+
const dateStr = (item.applied_at || item.date || "").slice(0, 10) || "n/a";
|
|
535
|
+
const href = item.url ? safeHref(item.url) : null;
|
|
536
|
+
const link = href && dataMode === "local"
|
|
537
|
+
? `<a href="${esc(href)}" target="_blank" rel="noopener noreferrer">Open posting ↗</a>`
|
|
538
|
+
: "";
|
|
539
|
+
const samplePill = dataMode === "sample" ? `<span class="sample-tag">Sample</span>` : "";
|
|
540
|
+
return `<div class="card">
|
|
541
|
+
<div class="card-top">
|
|
542
|
+
<div class="card-company">${esc(item.company || "Unknown Company")}</div>
|
|
543
|
+
${samplePill}
|
|
544
|
+
</div>
|
|
545
|
+
<div class="card-title">${esc(role)}</div>
|
|
546
|
+
<div class="card-meta">
|
|
547
|
+
<span>${esc(item.platform || "direct")} · ${esc(dateStr)}</span>
|
|
548
|
+
<span class="score-pill">${esc(score)}/10</span>
|
|
549
|
+
</div>
|
|
550
|
+
${link}
|
|
551
|
+
${item.notes ? `<div class="card-notes">${esc(item.notes)}</div>` : ""}
|
|
552
|
+
</div>`;
|
|
553
|
+
}).join("")
|
|
554
|
+
: `<div class="empty-msg">No records in ${esc(col.title)}</div>`;
|
|
555
|
+
return `<div class="column">
|
|
556
|
+
<div class="col-header">
|
|
557
|
+
<span>${esc(col.title)}</span>
|
|
558
|
+
<span class="badge">${items.length}</span>
|
|
559
|
+
</div>
|
|
560
|
+
${cardsHtml}
|
|
561
|
+
</div>`;
|
|
562
|
+
}).join("");
|
|
563
|
+
|
|
564
|
+
const byPlat = new Map();
|
|
565
|
+
for (const r of submitted) {
|
|
566
|
+
const key = normalizePlatform(r.platform);
|
|
567
|
+
if (!byPlat.has(key)) byPlat.set(key, { submitted: 0, callbacks: 0, scores: [] });
|
|
568
|
+
const entry = byPlat.get(key);
|
|
569
|
+
entry.submitted++;
|
|
570
|
+
const b = classifyBucket(r);
|
|
571
|
+
if (b === "interview" || b === "assessment" || b === "offer") entry.callbacks++;
|
|
572
|
+
const sc = Number(r.match_score ?? r.score);
|
|
573
|
+
if (!Number.isNaN(sc) && sc > 0) entry.scores.push(sc);
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
const tbody = document.getElementById("yield-tbody");
|
|
577
|
+
if (!byPlat.size) {
|
|
578
|
+
tbody.innerHTML = `<tr><td colspan="6" style="color:var(--muted);text-align:center;">No submitted applications to display. Load your local <code>logs/applications-log.json</code> file or click "Load Synthetic Sample" above.</td></tr>`;
|
|
579
|
+
} else {
|
|
580
|
+
tbody.innerHTML = [...byPlat.entries()]
|
|
581
|
+
.sort((a, b) => b[1].submitted - a[1].submitted)
|
|
582
|
+
.map(([plat, stat]) => {
|
|
583
|
+
const pct = stat.submitted ? ((stat.callbacks / stat.submitted) * 100).toFixed(1) : "0.0";
|
|
584
|
+
const avg = stat.scores.length ? (stat.scores.reduce((x, y) => x + y, 0) / stat.scores.length).toFixed(1) : "—";
|
|
585
|
+
return `<tr>
|
|
586
|
+
<td><strong>${esc(plat)}</strong></td>
|
|
587
|
+
<td>${stat.submitted}</td>
|
|
588
|
+
<td>${stat.callbacks}</td>
|
|
589
|
+
<td>${pct}%</td>
|
|
590
|
+
<td>${avg}</td>
|
|
591
|
+
<td><div class="bar-wrap"><div class="bar-fill" style="width:${Math.min(100, Number(pct))}%"></div></div></td>
|
|
592
|
+
</tr>`;
|
|
593
|
+
}).join("");
|
|
594
|
+
}
|
|
595
|
+
}
|
|
596
|
+
|
|
597
|
+
document.getElementById("dismiss-error-btn").addEventListener("click", clearError);
|
|
598
|
+
|
|
599
|
+
document.getElementById("search-input").addEventListener("input", e => {
|
|
600
|
+
render(activeRecords, e.target.value);
|
|
601
|
+
});
|
|
602
|
+
|
|
603
|
+
document.getElementById("demo-btn").addEventListener("click", () => {
|
|
604
|
+
clearError();
|
|
605
|
+
activeRecords = SYNTHETIC_DEMO_DATA;
|
|
606
|
+
dataMode = "sample";
|
|
607
|
+
sourceLabel = `Synthetic Sample Data (${SYNTHETIC_DEMO_DATA.length} fictional records)`;
|
|
608
|
+
render(activeRecords, document.getElementById("search-input").value);
|
|
609
|
+
});
|
|
610
|
+
|
|
611
|
+
document.getElementById("clear-btn").addEventListener("click", () => {
|
|
612
|
+
clearError();
|
|
613
|
+
activeRecords = [];
|
|
614
|
+
dataMode = "local";
|
|
615
|
+
sourceLabel = "No local file loaded (0 records)";
|
|
616
|
+
render(activeRecords, document.getElementById("search-input").value);
|
|
617
|
+
});
|
|
618
|
+
|
|
619
|
+
document.getElementById("file-input").addEventListener("change", e => {
|
|
620
|
+
const file = e.target.files && e.target.files[0];
|
|
621
|
+
if (!file) return;
|
|
622
|
+
const reader = new FileReader();
|
|
623
|
+
reader.onload = () => {
|
|
624
|
+
try {
|
|
625
|
+
const parsed = JSON.parse(String(reader.result || ""));
|
|
626
|
+
const records = Array.isArray(parsed) ? parsed : (Array.isArray(parsed?.applications) ? parsed.applications : null);
|
|
627
|
+
if (!records) {
|
|
628
|
+
throw new Error("Expected a JSON array or an object with an 'applications' array.");
|
|
629
|
+
}
|
|
630
|
+
clearError();
|
|
631
|
+
activeRecords = records;
|
|
632
|
+
dataMode = "local";
|
|
633
|
+
sourceLabel = `${file.name} (${records.length} local record(s))`;
|
|
634
|
+
render(activeRecords, document.getElementById("search-input").value);
|
|
635
|
+
} catch (err) {
|
|
636
|
+
showError(`Could not parse "${file.name}": ${err.message}`);
|
|
637
|
+
}
|
|
638
|
+
};
|
|
639
|
+
reader.readAsText(file);
|
|
640
|
+
e.target.value = "";
|
|
641
|
+
});
|
|
642
|
+
|
|
643
|
+
render(activeRecords);
|
|
644
|
+
</script>
|
|
645
|
+
</body>
|
|
646
|
+
</html>
|