# Simplify sidebar active state \(\#52799\) · gitcafe/zed

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

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

Visibility: public

Requested revision: 7719d2978fb76a375022aa0ca3604d2ec3c6f576

Requested commit: 7719d2978fb76a375022aa0ca3604d2ec3c6f576

Commit: 7719d2978fb76a375022aa0ca3604d2ec3c6f576

Tree: 8fc7257610f6a906835af1dcc02c6ebaa2f2fa92

Author: Mikayla Maki

Committer: GitHub

## Message

```
Simplify sidebar active state (#52799)

This changes the terminology from "focused entry" to "active entry", and
adds 4 properties that rebuild_contents should maintain for the active
entry:

- We should always have an active_entry after rebuild_contents
- The active entry's workspace should always be == to the active
multiworkspace
- If there's a thread, the active entry should always reflect that
thread
- There should always be exactly 1 active entry

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 is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

Closes #ISSUE

Release Notes:

- N/A
```

## Parents

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

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