This commit is contained in:
Nathan Sobo 2023-08-01 20:53:15 -06:00
parent 6f6096238d
commit 1dfde8eab5
15 changed files with 647 additions and 106 deletions

View file

@ -1,4 +1,13 @@
pub mod color {}
pub mod color {
use crate::color::{scale, ColorScale, Hsla};
pub fn ramp(color: impl Into<Hsla>) -> ColorScale {
let color = color.into();
let end_color = color.desaturate(0.1).brighten(0.5);
let start_color = color.desaturate(0.1).darken(0.4);
scale([start_color, color, end_color])
}
}
pub mod text {
use crate::node::length::{rems, Rems};