migrate ui crate to new theme tokens
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
use gpui::prelude::FluentBuilder;
|
||||
use gpui::{
|
||||
App, AppContext, Context, Entity, IntoElement, ParentElement, Render, SharedString, Styled,
|
||||
Window, relative,
|
||||
Window, px, relative,
|
||||
};
|
||||
use gpui_base::Tooltip as BaseTooltip;
|
||||
use theme::ActiveTheme;
|
||||
use theme::{ActiveTheme, control_radius};
|
||||
|
||||
pub struct Tooltip {
|
||||
text: SharedString,
|
||||
@@ -24,9 +24,9 @@ impl Render for Tooltip {
|
||||
.p_1p5()
|
||||
.border_1()
|
||||
.border_color(cx.theme().border)
|
||||
.bg(cx.theme().surface_background)
|
||||
.bg(cx.theme().surface_overlay)
|
||||
.when(cx.theme().shadow, |this| this.shadow_sm())
|
||||
.rounded(cx.theme().radius)
|
||||
.rounded(px(control_radius()))
|
||||
.text_xs()
|
||||
.text_color(cx.theme().text)
|
||||
.line_height(relative(1.25))
|
||||
|
||||
Reference in New Issue
Block a user