fix: highlight the palette row under the pointer - #414
Merged
Conversation
Palette rows have been full-width click targets since they were built, but nothing painted under the pointer — only the keyboard-selected row was tinted, so there was no way to tell what a click would run. The title-bar popover rows already highlight on hover via SessionPopoverRow, and README documents that behavior, so the palette was the one clickable list in the app with no pointer feedback. PaletteRow now carries its own hover state, keeping the diffing boundary the struct exists for. Hover paints a neutral wash instead of a weaker accent so it cannot be mistaken for a second selection when both are on screen; selection still wins on the row that has it, and hover stays purely visual — it does not move the keyboard cursor, which would thrash the theme palette's live preview. Fix #408
Deploying agterm with
|
| Latest commit: |
4c24be2
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://2d84ad02.agterm.pages.dev |
| Branch Preview URL: | https://fix-palette-row-hover.agterm.pages.dev |
There was a problem hiding this comment.
Pull request overview
This PR adds pointer-hover feedback to command palette rows so users can see which full-width row will be activated before clicking, bringing the palette in line with existing hover behavior in SessionPopoverRow and addressing Issue #408.
Changes:
- Add per-row hover tracking (
@State hovering+.onHover) toPaletteRow. - Introduce a neutral hover tint (
Color.primary.opacity(0.04)) and arowTintresolver so keyboard selection and pointer hover can coexist without stacking. - Replace the previous selection-only background with the unified
rowTintbackground.
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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.
palette rows have been full-width click targets since they were built, but nothing painted under the pointer. Only the keyboard-selected row was tinted, so there was no way to tell what a click would run until you clicked it.
the title-bar popover rows already highlight on hover through
SessionPopoverRow, and README documents that behavior, so the palette was the one clickable list in the app with no pointer feedback. The Ctrl-Tab switcher is the opposite case and stays as it is: same accent selection, no hover, and its rows are not clickable.what changed
PaletteRowgets its own@State hoveringand.onHover, so the diffing boundary the struct exists for is unchanged.Color.primary.opacity(0.04), not a weaker accent. Hover and the accent-tinted selection can sit on different rows at once, so the same hue at two strengths would read as a second selection. It also has to hold up over both panel backings,.regularMaterialand the opaque Reduce Transparency one.onSelectand thrash the theme palette's live preview on every mouse move across the list.covers the action, session, theme, attention and control-API
pickpalettes, since they all render throughPaletteRow.not included
the issue also lists sidebar row tinting and the eight
.plain/.borderlessbuttons. Left alone here, per the reporter's own offer to split them.testing
no automated test. Hover is private view state painting a background color, so there is no host-free surface and XCUITest cannot assert it. Same as
SessionPopoverRow, which has no hover test either. Verified by running it, plusControlPickUITestsrow click andPaletteUITestsarrow navigation to confirm the hit target and AX tree are unchanged.Fix #408