BROKEN: Checkpoint

This commit is contained in:
Nate Butler 2023-11-08 14:29:38 -05:00
parent e4ca2cb20b
commit 6ecf629c63
4 changed files with 69 additions and 19 deletions

View file

@ -0,0 +1,30 @@
use gpui::Styled;
use crate::UITextSize;
pub trait StyledExt: Styled {
fn text_ui_size(self, size: UITextSize) -> Self
where
Self: Sized,
{
let size = size.rems();
self.text_size(size)
}
fn text_ui(self) -> Self
where
Self: Sized,
{
let size = UITextSize::default().rems();
self.text_size(size)
}
fn text_ui_sm(self) -> Self
where
Self: Sized,
{
let size = UITextSize::Small.rems();
self.text_size(size)
}
}