Make chat prettier (to my eyes at least)
This commit is contained in:
parent
c2ff9fe2da
commit
f6ef07e716
4 changed files with 101 additions and 30 deletions
|
@ -1,7 +1,7 @@
|
|||
use crate::{
|
||||
self as gpui, hsla, point, px, relative, rems, AbsoluteLength, AlignItems, CursorStyle,
|
||||
DefiniteLength, Display, Fill, FlexDirection, Hsla, JustifyContent, Length, Position,
|
||||
SharedString, StyleRefinement, Visibility, WhiteSpace,
|
||||
DefiniteLength, Display, Fill, FlexDirection, FontWeight, Hsla, JustifyContent, Length,
|
||||
Position, SharedString, StyleRefinement, Visibility, WhiteSpace,
|
||||
};
|
||||
use crate::{BoxShadow, TextStyleRefinement};
|
||||
use smallvec::{smallvec, SmallVec};
|
||||
|
@ -494,6 +494,13 @@ pub trait Styled: Sized {
|
|||
self
|
||||
}
|
||||
|
||||
fn font_weight(mut self, weight: FontWeight) -> Self {
|
||||
self.text_style()
|
||||
.get_or_insert_with(Default::default)
|
||||
.font_weight = Some(weight);
|
||||
self
|
||||
}
|
||||
|
||||
fn text_bg(mut self, bg: impl Into<Hsla>) -> Self {
|
||||
self.text_style()
|
||||
.get_or_insert_with(Default::default)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue