Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

Occlude only modal and not the space around it used to center it

Antonio Scandurra2b67bb27cf87
diff --git a/crates/workspace/src/modal_layer.rs b/crates/workspace/src/modal_layer.rs
index 8208d808e90..f64df94cae9 100644
--- a/crates/workspace/src/modal_layer.rs
+++ b/crates/workspace/src/modal_layer.rs
@@ -139,21 +139,15 @@ impl Render for ModalLayer {
return div();
};
- div()
- .occlude()
- .absolute()
- .size_full()
- .top_0()
- .left_0()
- .child(
- v_flex()
- .h(px(0.0))
- .top_20()
- .flex()
- .flex_col()
- .items_center()
- .track_focus(&active_modal.focus_handle)
- .child(h_flex().child(active_modal.modal.view())),
- )
+ div().absolute().size_full().top_0().left_0().child(
+ v_flex()
+ .h(px(0.0))
+ .top_20()
+ .flex()
+ .flex_col()
+ .items_center()
+ .track_focus(&active_modal.focus_handle)
+ .child(h_flex().occlude().child(active_modal.modal.view())),
+ )
}
}