Skip to content

fix(cards): drop fake key hints + CtxCard CardHeader + TaskCard meta tidy#145

Merged
esengine merged 1 commit intomainfrom
fix/cards-polish
May 3, 2026
Merged

fix(cards): drop fake key hints + CtxCard CardHeader + TaskCard meta tidy#145
esengine merged 1 commit intomainfrom
fix/cards-polish

Conversation

@esengine
Copy link
Copy Markdown
Owner

@esengine esengine commented May 3, 2026

Summary

Card-stream polish from a full audit of the 14 non-polished cards. Four targeted fixes:

A. Drop misleading inline keybind hints

PlanCard and ErrorCard advertised inline keys in their footers but no handler was ever wired to scrollback cards. The actual flows go through modal pickers (PlanConfirm for revise/skip, prompt-loop for retry).

  • PlanCard.tsx:27[r] revise [s] skip step [↵] expand item — removed footer + the constant
  • ErrorCard.tsx:51-57[r] retry [s] skip — removed footer

Affordance contract: if a key is shown, it must work. These didn't, so they go.

B. CtxCard → CardHeader

CtxCard.tsx:30-37 hand-rolled a header (raw <Box> + <Text> with manual indent + custom glyph color) instead of using the shared CardHeader primitive every other card uses. Routed through CardHeader with tone="usage" and the existing glyph; rendered output is visually identical, but consistency contract restored.

C. TaskCard meta double-space

TaskCard.tsx:44meta={ ${elapsed} · } (trailing space). CardHeader already inserts a space before the trailing badge, producing X.Xs · done (double space). Trimmed to ${elapsed} ·.

D. Dead ternary branch in PlanCard

PlanCard.tsx:42 had isActive ? FG.strong : step.status === "queued" ? FG.sub : FG.sub — both inner arms identical. Collapsed to isActive ? FG.strong : FG.sub.

Test plan

  • npm run verify — 1829/1829 tests pass
  • CI green
  • Visual: PlanCard / ErrorCard scrollback no longer show key-hint footers; CtxCard header reads identically to other cards

Out of scope (deferred from audit)

  • BranchCard borrowing tone="streaming" (cosmetic naming only — colors are equivalent)
  • Truncation hint phrasing duplicated across 6 cards (elisionHint(count, kind) util refactor)
  • Progress-bar reuse between UsageCard / CtxCard / BranchCard (<ProgressBar> primitive)
  • Adding section Pill badges to ErrorCard / WarnCard (would dilute the live-activity-card visual language)

Refs

…tidy

Plan + Error cards advertised inline keybinds in their footers
(`[r] revise` / `[r] retry` etc.) but no handler was ever wired
to scrollback cards — the actual revise/retry flow runs through
PlanConfirm modals via arrow + Enter. Pressing the advertised key
did nothing. Removed the misleading footers; the modal flows are
unchanged.

CtxCard hand-rolled its own header instead of using CardHeader,
breaking the visual contract every other card follows. Routed it
through CardHeader with the same tone/glyph/meta shape.

TaskCard's `meta` ended in a trailing space (`X.Xs · `) and
CardHeader inserts its own space before the trailing badge, so the
rendered output had a double space before the status word.

Also collapsed a dead ternary branch in PlanCard step-color logic
where two arms produced the same value.
@esengine esengine merged commit 11c7150 into main May 3, 2026
1 check passed
@esengine esengine deleted the fix/cards-polish branch May 3, 2026 03:31
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.

1 participant