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.

Merge branch 'gpui2' into marshall/gpui2-playground

Marshall Bowerse6c7e57711e5
diff --cc crates/storybook2/src/workspace.rs
index 075fd183f7e,9e0083379d4..f017a4bc982
--- a/crates/storybook2/src/workspace.rs
+++ b/crates/storybook2/src/workspace.rs
@@@ -1,8 -1,6 +1,8 @@@
+use crate::ui::prelude::*;
+use crate::ui::{Panel, Stack};
use crate::{
collab_panel::{collab_panel, CollabPanel},
- theme::theme,
+ theme::{theme, themed},
themes::rose_pine_dawn,
};
use gpui3::{
@@@ -29,72 -27,31 +29,58 @@@ impl Workspace
fn render(&mut self, cx: &mut ViewContext<Self>) -> impl Element<State = Self> {
let theme = rose_pine_dawn();
- themed(rose_pine_dawn(), cx, |cx| {
- div()
- .size_full()
- .flex()
- .flex_col()
- .font("Courier")
- .gap_0()
- .justify_start()
- .items_start()
- .text_color(theme.lowest.base.default.foreground)
- .fill(theme.middle.base.default.background)
- .child(titlebar(cx))
- .child(
- div()
- .flex_1()
- .w_full()
- .flex()
- .flex_row()
- .overflow_hidden()
- .child(self.left_panel.clone())
- .child(div().h_full().flex_1())
- .child(self.right_panel.clone()),
- )
- .child(statusbar::statusbar(cx))
- })
+
+ div()
+ .size_full()
+ .v_stack()
+ .fill(theme.lowest.base.default.background)
+ .child(Panel::new(ScrollState::default()))
+ .child(
+ div()
+ .size_full()
+ .h_stack()
+ .gap_3()
+ .children((0..4).map(|i| {
+ div().size_full().flex().fill(gpui3::hsla(
+ 0. + (i as f32 / 7.),
+ 0. + (i as f32 / 5.),
+ 0.5,
+ 1.,
+ ))
+ })),
+ )
+ .child(
+ div()
+ .size_full()
+ .flex()
+ .fill(theme.middle.negative.default.background),
+ )
+
- // div()
- // .font("Helvetica")
- // .text_base()
- // .size_full()
- // .fill(theme.middle.positive.default.background)
- // .child("Hello world")
-
- // TODO: Implement style.
- //.size_full().fill(gpui3::hsla(0.83, 1., 0.5, 1.))
-
- // TODO: Debug font not font.
- //.child("Is this thing on?")
-
+ // themed(rose_pine_dawn(), cx, |cx| {
+ // div()
+ // .size_full()
+ // .flex()
+ // .flex_col()
- // .font("Zed Sans Extended")
++ // .font("Courier")
+ // .gap_0()
+ // .justify_start()
+ // .items_start()
+ // .text_color(theme.lowest.base.default.foreground)
- // // .fill(theme.middle.base.default.background)
- // .fill(gpui3::hsla(0.83, 1., 0.5, 1.))
++ // .fill(theme.middle.base.default.background)
+ // .child(titlebar(cx))
+ // .child(
+ // div()
+ // .flex_1()
+ // .w_full()
+ // .flex()
+ // .flex_row()
+ // .overflow_hidden()
+ // .child(self.left_panel.clone())
+ // .child(div().h_full().flex_1())
+ // .child(self.right_panel.clone()),
+ // )
+ // .child(statusbar::statusbar(cx))
+ // })
}
}