# Align agent sidebar headers with title bar \(\#62079\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/b036368ce9b664c93493165acbed5826410c9e5a)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: b036368ce9b664c93493165acbed5826410c9e5a

Requested commit: b036368ce9b664c93493165acbed5826410c9e5a

Commit: b036368ce9b664c93493165acbed5826410c9e5a

Tree: 2c5bcdb9ba1d6e89fd4ec72512fb3e62164e8149

Author: feeiyu

Committer: GitHub

## Message

```
Align agent sidebar headers with title bar (#62079)

# Objective

Fix the Agent sidebar header being two pixels lower than the title bar
on Linux.

This only affects Linux with client-side decorations: the main title bar
uses a negative one-pixel margin to overlap the client-drawn window
border, while the sidebar previously used a positive one-pixel margin on
every platform.

Fixes #53739

## Solution

Match the sidebar header spacing to the window decoration mode:

- Use `-1px` top margin for client-side decorations.
- Preserve the existing spacing for server-side decorations.
- Apply the fix to both the thread list and archive headers.

## Testing

- Manually tested on Linux. This only affects Linux because its
client-side window decorations require the adjusted title bar offset.

## Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content adheres to Zed's UI standards
([[UX/UI](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
and
[[icon](https://github.com/zed-industries/zed/blob/main/crates/icons/README.md)](https://github.com/zed-industries/zed/blob/main/crates/icons/README.md)
guidelines)
- [ ] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable


## Showcase

After this change：

[2026-08-02
18-20-19.webm](https://github.com/user-attachments/assets/1ef13ff2-2036-442b-8bcc-74ebeb8436c7)


---

Release Notes:

- Fixed misaligned Agent sidebar headers on Linux.
```

## Parents

- [be8c6f9fb356dcd40a7ff06149568753e64ee171](https://git.cafe/gitcafe/zed/commit/be8c6f9fb356dcd40a7ff06149568753e64ee171?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/b036368ce9b664c93493165acbed5826410c9e5a?format=markdown)
