Repository navigation
feat(people): add the Linking page and an invite landing page outside the dashboard - #149
Merged
Merged
Conversation
…nced to Auth Phase 1 pages (#139) on the backend's new People API (PoliNetworkOrg/backend#105, #106). The contract is now a copy of the backend's: a record has a name and contacts, and its roles are assignments (Admin, Capo Admin, team member or Lead) whose status says where each stands with PoliNetwork Auth: pending until linked, waiting for Auth, applied, or refused with Auth's reason. - Overview: filters by role, team, account and status with Auth. - Person page: each role with its status and Auth's refusal, past roles, account, HR notes and history, with actors named from linked records. - Add person: only the name is required; contacts and starting roles are optional, and a refused role is reported without undoing the record. - Admins: admins with their Capo Admin of reference (set or change), and Capo Admins with their scope (appoint, change, end). - Capo Admin area: read-only, laid out so management can be added. - Teams: members and Leads, honouring which roles Auth binds; a Lead manages their team's members. - My area: own record, roles and their status. - New permission people:link for linking by hand and unlinking; unlinking takes a reason and Auth revokes the roles first. - The Design team is Design & Marketing. - Agent mode: fixtures cover linked, invited and unlinked records and every assignment status. BREAKING CHANGE: requires the backend's Phase 1 People API (PoliNetworkOrg/backend#105 and #106) and the people:link permission in the IdP.
… the dashboard #140, on PoliNetworkOrg/backend#106 and #109. - Linking: records without an account (send an invite, link by hand), open invites with their expiry (resend, revoke), and links of the last 30 days with account, method, date and who did it. Unlink asks for a reason and explains that Auth revokes the roles first, and that they come back as pending. - The link dialog confirms which account is linked and how many roles go to Auth. - /people/invite stands outside the gated dashboard shell, so any signed-in account can open it, including one with no permissions: it asks "Link this account to <name>?", links on confirmation, then shows the roles as Auth applies or refuses them. Its copy says any account works, the link works once, and who to ask when it has expired. - Links to /dashboard/account/me?peopleInvite= redirect there before the dashboard's gate; My area no longer accepts invites.
Contributor
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
This was referenced Oct 31, 2026
The invite landing page showed "This link doesn't work" and told the person to ask for a new invite for any error from `me.invite`, including a backend outage or a contract mismatch, with the raw error as the reason. Only the backend's NOT_FOUND (spent, revoked or expired token) now means a dead link; anything else reaches the route's error state, which offers Retry. Also: - say that using another account means opening the email link again, since signing out returns to the dashboard, not the invite; - count Linking search results as records, invites or links, not "results" (docs/design.md §7); - replace design.md's stale Linking entry (Needs review queue) with the three segments and the landing page; - reflow the AGENTS.md People paragraph.
…gent mode Review fixes for the Phase 1 People pages (#139): - Add to team: a "Team Lead" choice no longer carries over to a team that can't take a Lead, which the backend refused. - Capo Admin pickers leave out Capo Admins whose appointment Auth hasn't confirmed: the backend only accepts one in effect. - After a failed role change the page reloads behind the dialog, since the backend records Auth's refusal (a refused start ends the assignment) before answering. - Start dates default to today in Europe/Rome, the calendar the backend checks them against, including the roles Add person starts with on the server. - Add person no longer lists a team that offers no role, and the refusal alert no longer doubles a refusal's final period. - A record waiting for Auth keeps the actions that stay in People (Capo Admin of reference, scope, team fields), as the backend allows them. - Former team members sort by their end date; empty action slots no longer leave a blank strip on mobile cards. - Agent mode counts assignments in effect as the backend does (pending ones included, starts waiting for Auth not), lets anyone give up their own role, ends roles that aren't bound, and clears Capo Admin references once Auth confirms the end for a linked record. Docs and tests follow.
…eat/people-linking-invite
The backend records Auth's refusal, or a link it couldn't finish, before it answers with the error, so the page behind the dialog reloads to show it, as role changes already do since #148.
BIA3IA
approved these changes
Nov 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #140. Stacked on #148 (#139). The backend side is PoliNetworkOrg/backend#106, and PoliNetworkOrg/backend#109 changes the invite email's link to this page. The roadmap is #146.
Linking page
Three views of People › Linking, with search:
people:write, when there's a contact email) and Link account (people:link).people:link) asks for a reason.Manual link: the dialog searches the IdP directory. Once you pick an account, it confirms which one and how many roles go to Auth, acting as you. It warns when that account is already linked to another record.
Invite landing page:
/people/invite?token=…It sits outside the gated dashboard shell. Its server functions use a new
peopleInviteMiddleware: signed in, no dashboard permission needed, and the token is the proof. An account with no permissions at all can open it.The flow:
The result:
people:self).After accepting, the URL switches to
?linked=true, so a reload shows the result instead of a spent link.The copy says:
Use another account signs out. An invalid or expired link shows the backend's message.
Old links:
/dashboard/account/me?peopleInvite=<token>redirects to the new page before the dashboard's gate, so invites already sent keep working. My area no longer accepts invites itself.Testing
pnpm check(0 errors; the 28 warnings are in untouched test files),pnpm typecheck,pnpm test(186 passed),pnpm build./people/invite?token=….adminscope to accounts that have no dashboard permissions; the backend'sme.inviteandme.acceptInviterequire it.Deploy
With #148. PoliNetworkOrg/backend#109 can go out before or after this: the redirect keeps both link formats working.