# agent: Show actual file name and icon in context pill \(\#31813\) · gitcafe/zed

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

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

Visibility: public

Requested revision: 9c715b470e46a9e500d5fb6139122fd5ed4707da

Requested commit: 9c715b470e46a9e500d5fb6139122fd5ed4707da

Commit: 9c715b470e46a9e500d5fb6139122fd5ed4707da

Tree: e41ff11be7db29d81032c49e4b7ebc7d7ac42e43

Author: Umesh Yadav

Committer: GitHub

## Message

```
agent: Show actual file name and icon in context pill (#31813)

Previously in the agent context pill if we added images it showed
generic Image tag on the image context pill. This PR make sure if we
have a path available for a image context show the filename which is in
line with other context pills.


Before | After
--- | ---
![Screenshot 2025-05-31 at 3 14 07
PM](https://github.com/user-attachments/assets/b342f046-2c1c-4c18-bb26-2926933d5d34)
| ![Screenshot 2025-05-31 at 3 14 07
PM](https://github.com/user-attachments/assets/90ad4062-cdc6-4274-b9cd-834b76e8e11b)





Release Notes:

- N/A

---------

Co-authored-by: Bennet Bo Fenner <bennetbo@gmx.de>
```

## Parents

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

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