
This PR mainlines the current state of new GPUI2-based UI from the `gpui2-ui` branch. Release Notes: - N/A --------- Co-authored-by: Nate Butler <iamnbutler@gmail.com> Co-authored-by: Max Brunsfeld <maxbrunsfeld@gmail.com> Co-authored-by: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com> Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com> Co-authored-by: Nate <nate@zed.dev> Co-authored-by: Mikayla <mikayla@zed.dev>
25 lines
651 B
Rust
25 lines
651 B
Rust
use gpui2::geometry::AbsoluteLength;
|
|
use gpui2::{hsla, Hsla};
|
|
|
|
#[derive(Clone, Copy)]
|
|
pub struct Token {
|
|
pub list_indent_depth: AbsoluteLength,
|
|
pub default_panel_size: AbsoluteLength,
|
|
pub state_hover_background: Hsla,
|
|
pub state_active_background: Hsla,
|
|
}
|
|
|
|
impl Default for Token {
|
|
fn default() -> Self {
|
|
Self {
|
|
list_indent_depth: AbsoluteLength::Rems(0.5),
|
|
default_panel_size: AbsoluteLength::Rems(16.),
|
|
state_hover_background: hsla(0.0, 0.0, 0.0, 0.08),
|
|
state_active_background: hsla(0.0, 0.0, 0.0, 0.16),
|
|
}
|
|
}
|
|
}
|
|
|
|
pub fn token() -> Token {
|
|
Token::default()
|
|
}
|