use crate::utils::StringObjTraits;
pub struct UiGlyphs {
pub round_left: char,
pub round_right: char,
pub swatch_block: char,
pub theme_section_rule: &'static str,
pub markdown_link: char,
pub markdown_attachment: char,
pub markdown_image: char,
pub arrow_up: char,
pub arrow_down: char,
pub github_mark: char,
pub settings_row_active: &'static str,
pub settings_note_asterisk: &'static str,
pub settings_note_arrow: &'static str,
pub indent_two_spaces: &'static str,
}
impl Default for UiGlyphs {
fn default() -> Self {
Self::new()
}
}
impl StringObjTraits for UiGlyphs {
fn new() -> Self {
UiGlyphs::new()
}
}
impl UiGlyphs {
#[must_use]
pub const fn new() -> Self {
Self {
round_left: '\u{e0b6}',
round_right: '\u{e0b4}',
swatch_block: '\u{2588}',
theme_section_rule: "\u{2500}\u{2500}\u{2500}",
markdown_link: '\u{2197}', markdown_attachment: '\u{1f4ce}', markdown_image: '\u{1f5bc}', arrow_up: '\u{2191}', arrow_down: '\u{2193}', github_mark: '\u{f09b}',
settings_row_active: "\u{203a} ", settings_note_asterisk: "* ", settings_note_arrow: "\u{2023} ", indent_two_spaces: " ",
}
}
}
pub const UI_GLYPHS: UiGlyphs = UiGlyphs::new();
pub struct TreeChars {
pub branch: &'static str,
pub last_branch: &'static str,
pub vertical: &'static str,
pub space: &'static str,
}
impl Default for TreeChars {
fn default() -> Self {
Self::new()
}
}
impl TreeChars {
#[must_use]
pub const fn new() -> Self {
Self {
branch: "├─ ",
last_branch: "└─ ",
vertical: "│ ",
space: " ",
}
}
}
pub const TREE_CHARS: TreeChars = TreeChars::new();