Skip to content

fix(tui): read a listing's applications instead of an apply form against it - #160

Merged
ralyodio merged 2 commits into
profullstack:masterfrom
mrfandu1:fix/tui-listings-applications-20260920
Sep 21, 2026
Merged

ralyodio merged 2 commits into
profullstack:masterfrom
mrfandu1:fix/tui-listings-applications-20260920

Conversation

@mrfandu1

Copy link
Copy Markdown
Contributor

On the TUI's "Your listings" tab, the bottom bar promises enter: applications, and the TUI's own header describes its employer half as "read what came back". Pressing enter on one of your listings actually opens the job detail - the same screen as the find tab - with "a: apply" and "d: prepare draft" hints against your own listing, and there is no way in the TUI to see the applications a listing received at all.

The cause is twofold: activate treats the listings tab exactly like the find tab (open detail, done), and the detail key hints are drawn from detail !== null alone, so the candidate-facing apply keys are offered regardless of whose listing is open. An employer who follows the hint ends up invited to apply to their own post, and the applications the API already serves at GET /api/v1/jobs/<slug>/applications never appear.

With this change, enter on a listing loads that endpoint and shows the applications - name, email, status, agent disclosure and how long ago - inline beside the listing. The apply and prepare-draft keys only appear on the find tab's detail, esc, tab and / clear the open applications together with the detail, and a listing nobody has answered yet says "Nobody yet."

Validation: tsc --noEmit and build pass. The five new rendering/state regressions in test/tui-applications.test.ts run against the real layout through hqtui's text renderer: on unmodified master four fail and the one find-tab guard passes; with the fix all five pass, and the full local suite is 368/368.

AI-assisted contribution, submitted under the published bug-fix offer (https://ugig.net/gigs/8b2a21db-ce15-433f-a73d-68f2e3349e87).

…nst it

The Your listings tab's help bar promises 'enter: applications', and the
TUI's own header calls its employer half 'read what came back'. Enter
actually opened the job detail - the same screen as the find tab - with
'a: apply' and 'd: prepare draft' hints against the employer's own
listing, and there was no way to read received applications from the TUI
at all.

Enter on a listing now loads GET /api/v1/jobs/<slug>/applications and
shows them (status, when, agent disclosure). The candidate-facing apply
and draft keys only appear on the find tab's detail, esc/search/tab
clear the applications with the detail, and an unanswered listing says
'Nobody yet.'
Copilot AI lite review requested due to automatic review settings September 20, 2026 17:00

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

Three unresolved moderate issues affect key dispatch, stale async responses, and hired-status rendering.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 2 Medium severity

Open (2)
What changed in this PR

Updates the TUI’s “Your listings” tab to display received applications instead of candidate application actions.

Changes:

  • Loads and tracks applications for owned listings.
  • Renders applicant details and empty states.
  • Separates employer and candidate key hints.
  • Adds rendering and navigation regression tests.
File Summary and review notes
test/​tui-applications.test.ts Adds application rendering and state regression tests.
src/​tui/​views.ts Renders application rows and empty states. Moderate issue (3 votes): compare status with hired, not accepted.
src/​tui/​state.ts Tracks application views and navigation state.
src/​tui/​index.ts Loads applications and clears detail state. Moderate issues: guard application-view key dispatch (2 votes) and prevent stale async responses after navigation (1 vote).

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/tui/index.ts
invalidate({
...state,
detail: job,
applications: result.items as ApplicationRow[],
Comment thread src/tui/views.ts Outdated
label: `${name}${email === undefined || email === '' ? '' : ` <${email}>`} | ${ago(application.createdAt)}${agent}`,
badge: application.status,
color:
application.status === 'accepted'
The applications view reuses detail state, so a/d still fired apply against your own listing even with the hints hidden. Guard the dispatch on applications === null. The success badge compared against 'accepted', which is not an application status; the positive decision is 'hired'.
@mrfandu1

Copy link
Copy Markdown
Contributor Author

Fixed both Copilot findings in 496f9f2:

  • the applications view reuses detail, so a/d could still fire apply against your own listing with the hints hidden — the dispatch is now guarded on applications === null
  • the success badge compared against accepted, which isn't an application status; it now matches hired

Full suite passes locally (368 tests), CI re-running.

@ralyodio
ralyodio merged commit 29bdae8 into profullstack:master Sep 21, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants