Skip to content

Commit

Permalink
Remove gap in layout of notifications (#23303)
Browse files Browse the repository at this point in the history
* Increases width of notification message to remove a gap

* Puts the close button in the top right

Release Notes:

- N/A

Co-authored-by: Nate <[email protected]>
  • Loading branch information
mgsloan and iamnbutler authored Jan 17, 2025
1 parent e338a17 commit bf0578e
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions crates/workspace/src/notifications.rs
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,7 @@ impl Render for LanguageServerPrompt {
.child(
h_flex()
.justify_between()
.items_start()
.child(
h_flex()
.gap_2()
Expand Down Expand Up @@ -396,7 +397,7 @@ impl Render for ErrorMessagePrompt {
.child(
div()
.id("error_message")
.max_w_80()
.max_w_96()
.max_h_40()
.overflow_y_scroll()
.child(Label::new(self.message.clone()).size(LabelSize::Small)),
Expand Down Expand Up @@ -503,7 +504,8 @@ pub mod simple_message_notification {
h_flex()
.gap_4()
.justify_between()
.child(div().max_w_80().child((self.content)(cx)))
.items_start()
.child(div().max_w_96().child((self.content)(cx)))
.child(
IconButton::new("close", IconName::Close)
.on_click(cx.listener(|this, _, cx| this.dismiss(cx))),
Expand Down

0 comments on commit bf0578e

Please sign in to comment.