wip: refactor

This commit is contained in:
2025-02-03 08:23:03 +07:00
parent c982c802e2
commit d921720042
29 changed files with 534 additions and 265 deletions

View File

@@ -1,7 +1,7 @@
use crate::theme::{scale::ColorScaleStep, ActiveTheme};
use gpui::{
div, px, App, AppContext, Context, Entity, IntoElement, ParentElement, Render, SharedString,
Styled, Window,
div, px, relative, App, AppContext, Context, Entity, IntoElement, ParentElement, Render,
SharedString, Styled, Window,
};
pub struct Tooltip {
@@ -21,13 +21,15 @@ impl Render for Tooltip {
div()
.font_family(".SystemUIFont")
.m_3()
.bg(cx.theme().base.step(cx, ColorScaleStep::TWELVE))
.text_color(cx.theme().base.step(cx, ColorScaleStep::ONE))
.border_1()
.border_color(cx.theme().base.step(cx, ColorScaleStep::FIVE))
.bg(cx.theme().base.step(cx, ColorScaleStep::THREE))
.shadow_md()
.rounded(px(6.))
.py_0p5()
.py_1()
.px_2()
.text_sm()
.text_xs()
.line_height(relative(1.))
.child(self.text.clone()),
)
}