fade out lens chat#304
Merged
Merged
Conversation
Expose built-in default values alongside resolved config in the admin API so the dashboard can show whether each setting's current value matches its default. The SourceBadge chip now displays "MODIFIED" in amber when the resolved value differs from the built-in default, replacing the previous provenance-only indicator. - config.ts: add getDefaultValues() to extract defaults for all tracked keys - runtime-config-service: expose defaults getter - admin-handler: include defaults map in GET/PUT /api/admin/config responses - coc-client: add defaults to AdminConfigResponse contract - AdminPanel: compute isDefaultValue() and pass to all SourceBadge instances - admin-redesign.css: add ar-src-modified styling - Tests for getDefaultValues() and admin handler defaults response Co-authored-by: Cursor <cursoragent@cursor.com>
… chat
When the review chat lens is enabled, the lens now automatically
transitions to a dormant state when the cursor leaves it (after 600ms).
Two dormant modes are available, selectable from Admin → Features:
- **Ghost fade** (default): lens fades to near-transparent (18% opacity)
with a subtle scale-down; clicks pass through to content underneath.
- **Collapse to pill**: lens collapses into a compact status pill showing
the chat title and identifier; hovering the pill restores the full card.
Re-entering the lens or pill restores focus immediately.
Configuration is wired end-to-end:
- `features.commitChatLensDormantMode` config field ('ghost' | 'pill')
- Admin registry, schema validation, namespace merge, runtime handler
- SPA bootstrap config, client config getter, HTML template injection
- Admin UI dropdown (shown when lens is enabled)
Tests cover ghost transition timing, pill visibility, focus restoration,
cancellation of dormant timer, config getter edge cases, and admin field
validation.
Co-authored-by: Cursor <cursoragent@cursor.com>
The pill dormant mode was fundamentally broken due to using element-level mouseenter/leave for focus detection. When the card set pointerEvents:none (ghost mode) or collapsed to a pill (pill mode), hover events stopped reaching the correct elements, making it impossible to restore focus. Replace the mouseenter/leave approach with document-level mousemove hit-testing (matching the reference prototype). The hook now continuously checks cursor distance to the active hit-rect — the card when focused, or the pill when dormant in pill mode — on every mousemove event. Also adds a pill ref for accurate bounding-rect hit-testing and updates tests with proper mousemove simulation and mock bounding rects. Co-authored-by: Cursor <cursoragent@cursor.com>
The dormant engine's kickTimer (30ms after mount) and poll interval (every 250ms) called tick(-9999, -9999) — hardcoded coordinates far from any element — causing the lens to start the dormant countdown even when the cursor was still inside the chat window. Remove both timers. The lens now starts focused (default) and only transitions to dormant when a real mousemove event shows the cursor outside the card rect. The dormant delay timer already handles the "mouse stationary outside" case once set by a real mousemove. Adds a regression test verifying the lens stays focused when no mousemove events have been fired. Co-authored-by: Cursor <cursoragent@cursor.com>
The lens resize grip now saves the final size to localStorage under `coc.commitChatLens.size` when the user releases the mouse. On mount, the component reads the persisted size and clamps it to valid viewport bounds. The storage key is global (not per-target) since lens size is a UI preference that applies across all chat targets. Adds tests for restoring persisted size, persisting after resize, handling malformed data, and clamping to min bounds. Co-authored-by: Cursor <cursoragent@cursor.com>
Add the new features.commitChatLensDormantMode key to the resolved-config tests and stub getCommitChatLensDormantMode in the PullRequestDetail config mock so the lens dormant-mode feature does not break existing suites. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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.
No description provided.