# git panel: Fix file path truncation and add some UI code clean up \(\#45161\) · gitcafe/zed

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

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

Visibility: public

Requested revision: 302a4bbdd0d30286b7688c4f2972e2f99d66999e

Requested commit: 302a4bbdd0d30286b7688c4f2972e2f99d66999e

Commit: 302a4bbdd0d30286b7688c4f2972e2f99d66999e

Tree: b4e939ca58dd3dd6a831eca1f70118b2d242bc73

Author: Danilo Leal

Committer: GitHub

## Message

```
git panel: Fix file path truncation and add some UI code clean up (#45161)

This PR ensures truncation works for the file paths, which should set up
the stage for when the new GPUI `truncation_start` method lands
(https://github.com/zed-industries/zed/pull/45122) so that we can use
for them. In the process of doing so and figuring it out why it wasn't
working as well before, I noticed some opportunities to clean up some UI
code: removing unnecessary styles, making the file easier to navigate
given all of the different UI conditions, etc.

Note: You might notice a subtle label flashing that comes with the label
truncation and that's a standalone GPUI bug that's also visible in other
surface areas of the app. I don't think it should block these changes
here as it's something we should fix on its own...

Release Notes:

- N/A
```

## Parents

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

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