Compare commits
2 Commits
030d6cdb86
...
79be6699ed
| Author | SHA1 | Date | |
|---|---|---|---|
| 79be6699ed | |||
| bc45a0feb7 |
@ -79,8 +79,7 @@ the terminal UI uses ANSI escape codes for colors and styling. ANSI codes are se
|
|||||||
|
|
||||||
```rust
|
```rust
|
||||||
// ANSI 256-color codes
|
// ANSI 256-color codes
|
||||||
pub const RED: &str = "\x1b[38;5;167m"; // #dd4132
|
pub const RED: &str = "\x1b[38;5;167m"; // #dd4132 accent
|
||||||
pub const CYAN: &str = "\x1b[38;5;87m"; // #22D3EE
|
|
||||||
pub const WHITE: &str = "\x1b[97m";
|
pub const WHITE: &str = "\x1b[97m";
|
||||||
pub const DIM: &str = "\x1b[2m";
|
pub const DIM: &str = "\x1b[2m";
|
||||||
pub const RESET: &str = "\x1b[0m";
|
pub const RESET: &str = "\x1b[0m";
|
||||||
|
|||||||
@ -25,7 +25,7 @@ pub fn box_top(width: usize, title: Option<&str>) -> String {
|
|||||||
|
|
||||||
match title {
|
match title {
|
||||||
Some(t) => {
|
Some(t) => {
|
||||||
let title_colored = color(&format!(" {} ", t), Colors::CYAN);
|
let title_colored = color(&format!(" {} ", t), Colors::RED);
|
||||||
let title_len = t.len() + 2; // account for spaces
|
let title_len = t.len() + 2; // account for spaces
|
||||||
let line_len = inner_width.saturating_sub(title_len);
|
let line_len = inner_width.saturating_sub(title_len);
|
||||||
dim(&format!(
|
dim(&format!(
|
||||||
|
|||||||
@ -52,7 +52,7 @@ fn render_header() -> String {
|
|||||||
&format!(
|
&format!(
|
||||||
"{} — {}",
|
"{} — {}",
|
||||||
bold_color(SiteContent::NAME, Colors::WHITE),
|
bold_color(SiteContent::NAME, Colors::WHITE),
|
||||||
color(SiteContent::TITLE, Colors::CYAN)
|
color(SiteContent::TITLE, Colors::RED)
|
||||||
),
|
),
|
||||||
WIDTH - 4,
|
WIDTH - 4,
|
||||||
),
|
),
|
||||||
@ -123,7 +123,7 @@ fn format_experience(exp: &Experience) -> String {
|
|||||||
dim(&format!("[{}]", exp.code)),
|
dim(&format!("[{}]", exp.code)),
|
||||||
color(exp.status, status_color),
|
color(exp.status, status_color),
|
||||||
bold_color(exp.title, Colors::WHITE),
|
bold_color(exp.title, Colors::WHITE),
|
||||||
color(exp.role, Colors::CYAN)
|
color(exp.role, Colors::RED)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -146,7 +146,7 @@ fn render_skills() -> String {
|
|||||||
fn format_skill(skill: &Skill) -> String {
|
fn format_skill(skill: &Skill) -> String {
|
||||||
format!(
|
format!(
|
||||||
"{} {}{}{}",
|
"{} {}{}{}",
|
||||||
color(skill.num, Colors::CYAN),
|
color(skill.num, Colors::RED),
|
||||||
bold_color(&format!("{:<18}", skill.name), Colors::WHITE),
|
bold_color(&format!("{:<18}", skill.name), Colors::WHITE),
|
||||||
" ",
|
" ",
|
||||||
dim(skill.tools)
|
dim(skill.tools)
|
||||||
@ -175,7 +175,7 @@ fn format_nav(nav: &NavItem) -> String {
|
|||||||
let padding = 35_usize.saturating_sub(nav.command.len());
|
let padding = 35_usize.saturating_sub(nav.command.len());
|
||||||
format!(
|
format!(
|
||||||
"{} {}{}{}",
|
"{} {}{}{}",
|
||||||
color("$", Colors::CYAN),
|
color("$", Colors::RED),
|
||||||
cmd,
|
cmd,
|
||||||
" ".repeat(padding),
|
" ".repeat(padding),
|
||||||
desc
|
desc
|
||||||
@ -185,7 +185,7 @@ fn format_nav(nav: &NavItem) -> String {
|
|||||||
fn render_footer() -> String {
|
fn render_footer() -> String {
|
||||||
format!(
|
format!(
|
||||||
" {} • {}",
|
" {} • {}",
|
||||||
color(SiteContent::WEBSITE, Colors::CYAN),
|
color(SiteContent::WEBSITE, Colors::RED),
|
||||||
color(SiteContent::EMAIL, Colors::LIGHT_GRAY)
|
color(SiteContent::EMAIL, Colors::LIGHT_GRAY)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user