revert popover changes

Nate Butler created

[no ci]

Change summary

crates/ui2/src/components/popover.rs | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)

Detailed changes

crates/ui2/src/components/popover.rs 🔗

@@ -44,18 +44,21 @@ impl RenderOnce for Popover {
     type Rendered = Div;
 
     fn render(self, cx: &mut WindowContext) -> Self::Rendered {
-        div()
-            .flex()
-            .flex_none()
-            .gap_1()
-            .child(v_stack().elevation_2(cx).p_1().children(self.children))
+        v_stack()
+            .relative()
+            .elevation_2(cx)
+            .p_1()
+            .children(self.children)
             .when_some(self.aside, |this, aside| {
                 // TODO: This will statically position the aside to the top right of the popover.
                 // We should update this to use gpui2::overlay avoid collisions with the window edges.
                 this.child(
                     v_stack()
+                        .top_0()
+                        .left_full()
+                        .ml_1()
+                        .absolute()
                         .elevation_2(cx)
-                        .flex_1()
                         .bg(cx.theme().colors().surface_background)
                         .p_1()
                         .child(aside),