Prevent long extension descriptions from overflowing (#9348)

This PR fixes an issue where long extension descriptions could take up
more room than intended, pushing the GitHub repository icon off the
screen.

<img width="901" alt="Screenshot 2024-03-14 at 12 54 14 PM"
src="https://github.com/zed-industries/zed/assets/1486634/befce468-f8df-4183-b3cc-9d088dd53b4e">

Fixes #9331.

Release Notes:

- Fixed an issue where long extension descriptions could push the GitHub
repository icon off the screen
([#9331](https://github.com/zed-industries/zed/issues/9331)).
This commit is contained in:
Marshall Bowers 2024-03-14 13:06:42 -04:00 committed by GitHub
parent 3610b076a0
commit a183c33367
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -391,11 +391,14 @@ impl ExtensionsPage {
)
.child(
h_flex()
.gap_2()
.justify_between()
.children(extension.description.as_ref().map(|description| {
Label::new(description.clone())
.size(LabelSize::Small)
.color(Color::Default)
h_flex().overflow_x_hidden().child(
Label::new(description.clone())
.size(LabelSize::Small)
.color(Color::Default),
)
}))
.child(
IconButton::new(