Reduce PopoverContent padding (#186)

This commit is contained in:
Floyd Wang 2024-08-29 11:35:38 +08:00 committed by GitHub
parent f7f3fcedf3
commit 7286866afd
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -48,7 +48,10 @@ impl FocusableView for PopoverContent {
impl Render for PopoverContent {
fn render(&mut self, cx: &mut ViewContext<Self>) -> impl IntoElement {
div().p_4().when_some(self.max_width, |this, v| this.max_w(v)).child(self.content.clone()(cx))
div()
.p_2()
.when_some(self.max_width, |this, v| this.max_w(v))
.child(self.content.clone()(cx))
}
}