Files
zed/crates/git_ui
Shuvro Roy 93d7456688 git_ui: Fix commit editor button hover colors (#65448)
## Summary

Closes #65376. Replaces #65411 with the hover behavior handled inside
the button component, as requested in review.

My original description of the problem:

> The main problem is when I hover in the blank area the icon color got
changed

Each commit editor button now uses 0.6 opacity normally and 1.0 only
while that button is hovered. The opacity options are handled by
`IconButton` and `ButtonLike`, and the component preview includes an
example.

### Before fix


https://github.com/user-attachments/assets/b7ad6980-e382-4bef-904a-74d877da0291

### After fix


https://github.com/user-attachments/assets/3089e783-c54a-4a94-9e47-a169483aface

## Testing

- Built and ran the development app on macOS. Manually checked
blank-area hover, each icon independently, expand/collapse actions, and
light and dark themes.
- `cargo test --locked -p ui --lib`: all 89 existing tests passed. This
visual change is covered by manual testing; no dedicated automated
regression test was added.
- `cargo fmt --all -- --check` and `git diff --check` passed.
- `cargo build --locked -p zed --bin zed` passed with the macOS
development environment configured.

To check, open a Git repository and its Git panel. Move the pointer
between the blank space below the commit editor buttons and each button.
Only the hovered button should brighten. Also expand and collapse the
commit editor.

## Self-review

- [x] I've reviewed my diff for quality, security, reliability, and
performance.
- [x] UI changes follow the
[checklist](https://zed.dev/docs/development/ui-checklist).
- [x] Tests cover the new or changed behavior through the manual checks
described above.

Release Notes:

- Fixed Git panel commit editor buttons changing opacity when hovering
empty space.

---------

Co-authored-by: MrSubidubi <finn@zed.dev>
2026-10-10 22:13:37 +00:00
..