feat(web): rich hover tooltips on session-list attention indicators#45
Closed
heavygee wants to merge 4 commits into
Closed
feat(web): rich hover tooltips on session-list attention indicators#45heavygee wants to merge 4 commits into
heavygee wants to merge 4 commits into
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
The session-row attention dots and the future-scheduled clock icon used
plain `title=""` attributes which gave only a one-word label ("Permission
required"). Replace those with hover/focus-revealed tooltips that name
*which* tools are blocking, count background tasks, surface the
"updated Nm ago" timestamp, and explain the pending schedule.
To make per-tool copy possible without an extra round trip,
`SessionSummary` now carries a structured slice of the pending tool
requests, capped at `PENDING_REQUEST_SUMMARY_CAP = 5` oldest-first:
pendingRequests: Array<{ id; kind; tool; since }>
`pendingRequestsCount` remains the authoritative total;
`pendingRequestKinds` is still derived from the FULL request set so a
single `'input'` request beyond the cap still surfaces its kind on the
session row.
The tooltip primitive (`HoverTooltip`) is a CSS-driven reveal — no
portal, no positioning JS — so it composes cheaply inside the existing
session-row `<button>` and stays out of the way on touch devices, which
keep getting the same `aria-label` the old `title=""` attribute provided
to screen readers.
Test coverage: shared derivation + cap + tie-break + full-set kind
behaviour; web tooltip render across all four attention kinds plus
mixed-kind overflow suppression and aria-label exposure.
Co-authored-by: Cursor <cursoragent@cursor.com>
Two operator-feedback fixes on the new session-list HoverTooltip:
1. Tooltip background was bg-[var(--app-bg)] - the same variable as the
session row underneath - so the tooltip looked translucent and the row
text bled through. Switch to bg-[var(--app-secondary-bg)] (#2C2C2E
dark / #f3f4f6 light, both opaque) and bump shadow-md -> shadow-lg.
Telegram-themed clients still pick up tg-theme-secondary-bg-color so
the tooltip stays on-theme.
2. The 'unread' attention dot tooltip rendered 'New activity / Updated 5m
ago', but the relative-time pill ('5m ago') is already on the right
edge of the same session row. The tooltip body just duplicated info.
Render only the title for the unread case; drop the
session.tooltip.unread.body i18n key from en + zh-CN.
The other tooltip kinds (permission/input list tools, background lists
task count) keep their bodies - those facts are not visible elsewhere on
the row.
Co-authored-by: Cursor <cursoragent@cursor.com>
The schedule clock tooltip previously said only "Will fire when due." while the row already showed a relative updated-at pill. Extend the session-list API with nextScheduledAt (MIN future scheduled_at per session, same filter as futureScheduledMessageCount) and render: - single scheduled: "Fires in 5m · Jun 16, 1:45 PM" - multiple: "Next in 5m · Jun 16, 1:45 PM · +2 more" Extract formatScheduledTime from QueuedMessagesBar into web/lib/ scheduledTime.ts alongside formatFutureRelativeTime and the tooltip composer. SSE upsert preserves nextScheduledAt until the list refetch that already runs on schedule-related events. Co-authored-by: Cursor <cursoragent@cursor.com>
heavygee
force-pushed
the
feat/session-list-rich-tooltips
branch
from
June 17, 2026 11:13
eb26006 to
f93e599
Compare
Address PR tiann#941 Major review: aria-describedby and tooltip visibility were on a non-focusable inner span, so keyboard users tabbing the session row button never received the rich tooltip description and group-focus-within never matched. - Session row button owns aria-describedby (attention + schedule ids) - Add group/session-row + SESSION_ROW_TOOLTIP_FOCUS_CLASS reveal on :focus-visible - HoverTooltip takes required id; drop inner aria-label/describedby - useSessionRowTooltipIds helper composes stable row tooltip ids - Tests for id wiring and parent-focus reveal classes Co-authored-by: Cursor <cursoragent@cursor.com>
Owner
Author
|
Superseded by upstream tiann#941 (merged path). Closing fork dogfood PR. |
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.
Summary
The session-row attention dots and future-scheduled clock icon (added in tiann#699) currently use plain
title=""attributes which only surface a one-word label ("Permission required"). Replace those with hover/focus-revealed tooltips that explain why the indicator is showing — naming the pending tools, counting background tasks, surfacing the "updated Nm ago" timestamp, and explaining the pending schedule.To make per-tool copy possible without a follow-up
GET /sessions/:idround trip,SessionSummarynow carries a structured slice of the pending tool requests, capped atPENDING_REQUEST_SUMMARY_CAP = 5oldest-first:pendingRequestsCountremains the authoritative total;pendingRequestKindsis still derived from the FULL request set so a single'input'request beyond the cap still correctly surfaces its kind on the session row.The tooltip primitive (
HoverTooltip) is a CSS-driven reveal — no portal, no positioning JS, no new dependency — so it composes cheaply inside the existing session-row<button>and stays out of the way on touch devices, which keep getting the samearia-labelthe oldtitle=""attribute provided to screen readers.What you'll see
Files
Compatibility
Test plan
Disclosure
Drafted with `claude-opus-4.7-thinking-high` via Cursor; reviewed and tested by the human contributor.
Made with Cursor