Public: anyone can read this; the crew can change it.

The terminal's "What I can do" offers `u` and `p` only when there is a link to undo, and asks before it unlinks #7950

shipped production is serving it opened this has it
opened this

Intent: the screen offers no key that cannot act, and an unlink that only the web page can undo is never one stray key press away.

Today src/tui/screens/can.ts always lists u unlink open-platform.sh and p unlink parent forge in its keys, even when no edge token is active, nothing is linked or no parent forge is configured, and either key unlinks at once.

Done looks like:

  • [ ] u is in keys and handled only when activeEdgeToken(f.app) is set and linkedLogin finds a login; otherwise key returns false for it.
  • [ ] p is in keys and handled only when parentIssuerOf(f.app.config) is set and linkedParent finds a link; otherwise key returns false for it.
  • [ ] Each opens confirmScreen (yesNo: true) naming what goes: "Unlink open-platform.sh login <login>?" / "Unlink the parent forge?", with one line saying it is linked again from Settings on the web. y unlinks as today (same bus events, LAST_WAY_IN still refused and shown); n/esc changes nothing.
  • [ ] test/tui-can.test.ts: the two unlink tests press y after the key; new tests prove u and p are absent from the keys with nothing linked, and that n leaves the link in place. They fail without the change.
  • [ ] bun test test/tui-can.test.ts test/tui-verify.test.ts passes.

Files: src/tui/screens/can.ts, test/tui-can.test.ts Risks: test/palette-roster.test.ts reads the screen's keys; keep it green. Brief: a builder who knows the terminal screens.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs