use super::Theme;
use super::ThemePalette;
use ratatui::style::Color;
impl Theme {
pub(super) fn dracula() -> Self {
let purple = Color::Rgb(189, 147, 249);
let pink = Color::Rgb(255, 121, 198);
let cyan = Color::Rgb(139, 233, 253);
let green = Color::Rgb(80, 250, 123);
let red = Color::Rgb(255, 85, 85);
let yellow = Color::Rgb(241, 250, 140);
let orange = Color::Rgb(255, 184, 108);
let fg = Color::Rgb(248, 248, 242);
let comment = Color::Rgb(98, 114, 164);
let bg = Color::Rgb(40, 42, 54);
let surface = Color::Rgb(68, 71, 90);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(189, 193, 205),
fg_muted: comment,
accent: purple,
accent2: pink,
green,
red,
yellow,
blue: cyan,
orange,
is_dark: true,
};
Self {
md_code: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn catppuccin_mocha() -> Self {
let mauve = Color::Rgb(203, 166, 247);
let pink = Color::Rgb(245, 194, 231);
let blue = Color::Rgb(137, 180, 250);
let teal = Color::Rgb(148, 226, 213);
let green = Color::Rgb(166, 227, 161);
let red = Color::Rgb(243, 139, 168);
let yellow = Color::Rgb(249, 226, 175);
let peach = Color::Rgb(250, 179, 135);
let lavender = Color::Rgb(180, 190, 254);
let text = Color::Rgb(205, 214, 244);
let subtext = Color::Rgb(166, 173, 200);
let overlay = Color::Rgb(108, 112, 134);
let base = Color::Rgb(30, 30, 46);
let surface = Color::Rgb(49, 50, 68);
let p = ThemePalette {
bg: base,
surface,
fg: text,
fg_dim: subtext,
fg_muted: overlay,
accent: mauve,
accent2: lavender,
green,
red,
yellow,
blue,
orange: peach,
is_dark: true,
};
Self {
spinner: lavender,
md_header: pink,
md_code: teal,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn catppuccin_latte() -> Self {
let mauve = Color::Rgb(136, 57, 239);
let blue = Color::Rgb(30, 102, 245);
let teal = Color::Rgb(23, 146, 153);
let green = Color::Rgb(64, 160, 43);
let red = Color::Rgb(210, 15, 57);
let yellow = Color::Rgb(223, 142, 29);
let peach = Color::Rgb(254, 100, 11);
let lavender = Color::Rgb(114, 135, 253);
let text = Color::Rgb(76, 79, 105);
let subtext = Color::Rgb(108, 111, 133);
let overlay = Color::Rgb(140, 143, 161);
let base = Color::Rgb(239, 241, 245);
let surface = Color::Rgb(230, 233, 239);
let p = ThemePalette {
bg: base,
surface,
fg: text,
fg_dim: subtext,
fg_muted: overlay,
accent: mauve,
accent2: lavender,
green,
red,
yellow,
blue,
orange: peach,
is_dark: false,
};
Self {
spinner: lavender,
md_header: mauve,
md_code: teal,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn tokyo_night() -> Self {
let blue = Color::Rgb(122, 162, 247);
let cyan = Color::Rgb(125, 207, 255);
let green = Color::Rgb(158, 206, 106);
let red = Color::Rgb(247, 118, 142);
let yellow = Color::Rgb(224, 175, 104);
let magenta = Color::Rgb(187, 154, 247);
let fg = Color::Rgb(192, 202, 245);
let comment = Color::Rgb(86, 95, 137);
let bg = Color::Rgb(26, 27, 38);
let surface = Color::Rgb(52, 56, 85);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(169, 177, 214),
fg_muted: comment,
accent: blue,
accent2: magenta,
green,
red,
yellow,
blue: cyan,
orange: yellow,
is_dark: true,
};
Self {
md_code: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn tokyo_day() -> Self {
let blue = Color::Rgb(46, 125, 233);
let cyan = Color::Rgb(0, 113, 151);
let green = Color::Rgb(88, 117, 57);
let red = Color::Rgb(245, 42, 101);
let yellow = Color::Rgb(140, 108, 62);
let magenta = Color::Rgb(152, 84, 241);
let fg = Color::Rgb(55, 96, 191);
let comment = Color::Rgb(148, 155, 184);
let bg = Color::Rgb(225, 226, 231);
let surface = Color::Rgb(213, 214, 219);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(100, 111, 158),
fg_muted: comment,
accent: blue,
accent2: magenta,
green,
red,
yellow,
blue: cyan,
orange: yellow,
is_dark: false,
};
Self {
spinner: blue,
md_code: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn nord() -> Self {
let frost_blue = Color::Rgb(129, 161, 193);
let frost_cyan = Color::Rgb(136, 192, 208);
let frost_light = Color::Rgb(143, 188, 187);
let green = Color::Rgb(163, 190, 140);
let red = Color::Rgb(191, 97, 106);
let yellow = Color::Rgb(235, 203, 139);
let purple = Color::Rgb(180, 142, 173);
let fg = Color::Rgb(236, 239, 244);
let comment = Color::Rgb(76, 86, 106);
let bg = Color::Rgb(46, 52, 64);
let surface = Color::Rgb(59, 66, 82);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(216, 222, 233),
fg_muted: comment,
accent: frost_cyan,
accent2: frost_light,
green,
red,
yellow,
blue: frost_blue,
orange: yellow,
is_dark: true,
};
Self {
md_header: purple,
md_code: frost_light,
md_bullet: frost_blue,
..Self::from_palette(&p)
}
}
pub(super) fn gruvbox() -> Self {
let orange = Color::Rgb(254, 128, 25);
let aqua = Color::Rgb(142, 192, 124);
let green = Color::Rgb(184, 187, 38);
let red = Color::Rgb(251, 73, 52);
let yellow = Color::Rgb(250, 189, 47);
let blue = Color::Rgb(131, 165, 152);
let purple = Color::Rgb(211, 134, 155);
let fg = Color::Rgb(235, 219, 178);
let gray = Color::Rgb(146, 131, 116);
let bg = Color::Rgb(40, 40, 40);
let surface = Color::Rgb(60, 56, 54);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(189, 174, 147),
fg_muted: gray,
accent: aqua,
accent2: orange,
green,
red,
yellow,
blue,
orange,
is_dark: true,
};
Self {
md_header: purple,
md_code: yellow,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn gruvbox_light() -> Self {
let orange = Color::Rgb(214, 93, 14);
let aqua = Color::Rgb(66, 123, 88);
let green = Color::Rgb(121, 116, 14);
let red = Color::Rgb(157, 0, 6);
let yellow = Color::Rgb(181, 118, 20);
let blue = Color::Rgb(7, 102, 120);
let gray = Color::Rgb(146, 131, 116);
let fg = Color::Rgb(60, 56, 54);
let bg = Color::Rgb(251, 241, 199);
let surface = Color::Rgb(235, 219, 178);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(80, 73, 69),
fg_muted: gray,
accent: aqua,
accent2: orange,
green,
red,
yellow,
blue,
orange,
is_dark: false,
};
Self {
md_header: Color::Rgb(175, 58, 3),
md_code: yellow,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn solarized_dark() -> Self {
let yellow = Color::Rgb(181, 137, 0);
let orange = Color::Rgb(203, 75, 22);
let red = Color::Rgb(220, 50, 47);
let magenta = Color::Rgb(211, 54, 130);
let violet = Color::Rgb(108, 113, 196);
let blue = Color::Rgb(38, 139, 210);
let cyan = Color::Rgb(42, 161, 152);
let green = Color::Rgb(133, 153, 0);
let fg = Color::Rgb(131, 148, 150);
let comment = Color::Rgb(88, 110, 117);
let bg = Color::Rgb(0, 43, 54);
let surface = Color::Rgb(7, 54, 66);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(101, 123, 131),
fg_muted: comment,
accent: cyan,
accent2: cyan,
green,
red,
yellow,
blue,
orange,
is_dark: true,
};
Self {
md_header: magenta,
md_code: violet,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn solarized_light() -> Self {
let yellow = Color::Rgb(181, 137, 0);
let orange = Color::Rgb(203, 75, 22);
let red = Color::Rgb(220, 50, 47);
let magenta = Color::Rgb(211, 54, 130);
let violet = Color::Rgb(108, 113, 196);
let blue = Color::Rgb(38, 139, 210);
let cyan = Color::Rgb(42, 161, 152);
let green = Color::Rgb(133, 153, 0);
let fg = Color::Rgb(101, 123, 131);
let comment = Color::Rgb(147, 161, 161);
let bg = Color::Rgb(253, 246, 227);
let surface = Color::Rgb(238, 232, 213);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(88, 110, 117),
fg_muted: comment,
accent: blue,
accent2: blue,
green,
red,
yellow,
blue: cyan,
orange,
is_dark: false,
};
Self {
md_header: magenta,
md_code: violet,
md_bullet: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn monokai() -> Self {
let green = Color::Rgb(166, 226, 46);
let yellow = Color::Rgb(230, 219, 116);
let blue = Color::Rgb(102, 217, 232);
let red = Color::Rgb(249, 38, 114);
let orange = Color::Rgb(253, 151, 31);
let purple = Color::Rgb(174, 129, 255);
let fg = Color::Rgb(248, 248, 242);
let comment = Color::Rgb(117, 113, 94);
let bg = Color::Rgb(39, 40, 34);
let surface = Color::Rgb(62, 61, 50);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(204, 204, 204),
fg_muted: comment,
accent: green,
accent2: green,
green,
red,
yellow,
blue,
orange,
is_dark: true,
};
Self {
assistant: blue,
md_header: red,
md_code: yellow,
md_bullet: purple,
..Self::from_palette(&p)
}
}
pub(super) fn one_dark() -> Self {
let blue = Color::Rgb(97, 175, 239);
let green = Color::Rgb(152, 195, 121);
let red = Color::Rgb(224, 108, 117);
let yellow = Color::Rgb(229, 192, 123);
let cyan = Color::Rgb(86, 182, 194);
let purple = Color::Rgb(198, 120, 221);
let fg = Color::Rgb(171, 178, 191);
let comment = Color::Rgb(92, 99, 112);
let bg = Color::Rgb(40, 44, 52);
let surface = Color::Rgb(59, 64, 72);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(130, 137, 151),
fg_muted: comment,
accent: blue,
accent2: purple,
green,
red,
yellow,
blue: cyan,
orange: yellow,
is_dark: true,
};
Self {
md_header: purple,
md_code: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn one_light() -> Self {
let blue = Color::Rgb(64, 120, 242);
let green = Color::Rgb(80, 161, 79);
let red = Color::Rgb(228, 86, 73);
let yellow = Color::Rgb(152, 104, 1);
let cyan = Color::Rgb(1, 132, 188);
let purple = Color::Rgb(166, 38, 164);
let fg = Color::Rgb(56, 58, 66);
let comment = Color::Rgb(160, 161, 167);
let bg = Color::Rgb(250, 250, 250);
let surface = Color::Rgb(240, 240, 240);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(100, 102, 110),
fg_muted: comment,
accent: blue,
accent2: blue,
green,
red,
yellow,
blue: cyan,
orange: yellow,
is_dark: false,
};
Self {
md_header: purple,
md_code: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn everforest_dark() -> Self {
let green = Color::Rgb(167, 192, 128);
let yellow = Color::Rgb(219, 188, 127);
let red = Color::Rgb(230, 126, 128);
let blue = Color::Rgb(127, 187, 179);
let aqua = Color::Rgb(131, 192, 146);
let orange = Color::Rgb(230, 152, 117);
let fg = Color::Rgb(211, 198, 170);
let comment = Color::Rgb(131, 139, 129);
let bg = Color::Rgb(45, 53, 59);
let surface = Color::Rgb(52, 63, 68);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(157, 157, 150),
fg_muted: comment,
accent: green,
accent2: green,
green,
red,
yellow,
blue,
orange,
is_dark: true,
};
Self {
assistant: aqua,
md_header: red,
md_code: yellow,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn everforest_light() -> Self {
let green = Color::Rgb(141, 161, 1);
let yellow = Color::Rgb(223, 160, 0);
let red = Color::Rgb(248, 85, 82);
let blue = Color::Rgb(58, 148, 197);
let aqua = Color::Rgb(53, 167, 124);
let orange = Color::Rgb(245, 125, 38);
let fg = Color::Rgb(92, 106, 114);
let comment = Color::Rgb(157, 169, 160);
let bg = Color::Rgb(253, 246, 227);
let surface = Color::Rgb(244, 240, 217);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(116, 127, 123),
fg_muted: comment,
accent: green,
accent2: green,
green,
red,
yellow,
blue,
orange,
is_dark: false,
};
Self {
assistant: aqua,
md_header: red,
md_code: yellow,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn rose_pine() -> Self {
let love = Color::Rgb(235, 111, 146);
let gold = Color::Rgb(246, 193, 119);
let iris = Color::Rgb(196, 167, 231);
let pine = Color::Rgb(49, 116, 143);
let foam = Color::Rgb(156, 207, 216);
let rose = Color::Rgb(235, 188, 186);
let fg = Color::Rgb(224, 222, 244);
let muted = Color::Rgb(110, 106, 134);
let bg = Color::Rgb(25, 23, 36);
let surface = Color::Rgb(38, 35, 58);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(144, 140, 170),
fg_muted: muted,
accent: iris,
accent2: iris,
green: foam,
red: love,
yellow: gold,
blue: pine,
orange: gold,
is_dark: true,
};
Self {
success: foam,
error: love,
user: foam,
assistant: iris,
system: gold,
md_header: love,
md_code: rose,
md_bullet: pine,
..Self::from_palette(&p)
}
}
pub(super) fn rose_pine_dawn() -> Self {
let love = Color::Rgb(180, 99, 122);
let gold = Color::Rgb(234, 157, 52);
let iris = Color::Rgb(144, 122, 169);
let pine = Color::Rgb(40, 105, 131);
let foam = Color::Rgb(86, 148, 159);
let rose = Color::Rgb(215, 130, 126);
let fg = Color::Rgb(87, 82, 121);
let muted = Color::Rgb(152, 147, 165);
let bg = Color::Rgb(250, 244, 237);
let surface = Color::Rgb(255, 250, 243);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(121, 117, 147),
fg_muted: muted,
accent: iris,
accent2: iris,
green: foam,
red: love,
yellow: gold,
blue: pine,
orange: gold,
is_dark: false,
};
Self {
success: foam,
error: love,
user: foam,
assistant: iris,
system: gold,
md_header: love,
md_code: rose,
md_bullet: pine,
..Self::from_palette(&p)
}
}
pub(super) fn material_dark() -> Self {
let cyan = Color::Rgb(128, 203, 196);
let green = Color::Rgb(195, 232, 141);
let yellow = Color::Rgb(255, 203, 107);
let red = Color::Rgb(240, 113, 120);
let blue = Color::Rgb(130, 170, 255);
let purple = Color::Rgb(199, 146, 234);
let fg = Color::Rgb(238, 255, 255);
let comment = Color::Rgb(84, 110, 122);
let bg = Color::Rgb(33, 33, 33);
let surface = Color::Rgb(48, 48, 48);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(176, 190, 197),
fg_muted: comment,
accent: cyan,
accent2: cyan,
green,
red,
yellow,
blue,
orange: yellow,
is_dark: true,
};
Self {
md_header: purple,
md_code: green,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn material_light() -> Self {
let cyan = Color::Rgb(57, 173, 181);
let green = Color::Rgb(145, 184, 89);
let yellow = Color::Rgb(246, 164, 52);
let red = Color::Rgb(229, 57, 53);
let blue = Color::Rgb(97, 130, 184);
let purple = Color::Rgb(124, 77, 255);
let fg = Color::Rgb(84, 110, 122);
let comment = Color::Rgb(144, 164, 174);
let bg = Color::Rgb(250, 250, 250);
let surface = Color::Rgb(231, 234, 236);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(96, 125, 139),
fg_muted: comment,
accent: blue,
accent2: blue,
green,
red,
yellow,
blue: cyan,
orange: yellow,
is_dark: false,
};
Self {
md_header: purple,
md_code: cyan,
md_bullet: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn ayu_dark() -> Self {
let orange = Color::Rgb(255, 143, 64);
let green = Color::Rgb(170, 217, 76);
let blue = Color::Rgb(89, 194, 255);
let purple = Color::Rgb(210, 166, 255);
let red = Color::Rgb(240, 113, 120);
let yellow = Color::Rgb(230, 180, 80);
let fg = Color::Rgb(179, 177, 173);
let comment = Color::Rgb(66, 77, 103);
let bg = Color::Rgb(10, 14, 20);
let surface = Color::Rgb(26, 31, 41);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(120, 118, 114),
fg_muted: comment,
accent: blue,
accent2: orange,
green,
red,
yellow,
blue,
orange,
is_dark: true,
};
Self {
md_header: purple,
md_code: green,
md_bullet: orange,
..Self::from_palette(&p)
}
}
pub(super) fn ayu_light() -> Self {
let orange = Color::Rgb(250, 141, 62);
let green = Color::Rgb(134, 179, 0);
let blue = Color::Rgb(57, 158, 230);
let purple = Color::Rgb(163, 122, 204);
let red = Color::Rgb(240, 113, 113);
let yellow = Color::Rgb(242, 174, 73);
let fg = Color::Rgb(92, 97, 102);
let comment = Color::Rgb(173, 177, 184);
let bg = Color::Rgb(250, 250, 250);
let surface = Color::Rgb(243, 244, 245);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(120, 124, 130),
fg_muted: comment,
accent: blue,
accent2: orange,
green,
red,
yellow,
blue,
orange,
is_dark: false,
};
Self {
md_header: purple,
md_code: green,
md_bullet: orange,
..Self::from_palette(&p)
}
}
pub(super) fn palenight() -> Self {
let purple = Color::Rgb(199, 146, 234);
let blue = Color::Rgb(130, 170, 255);
let cyan = Color::Rgb(137, 221, 255);
let green = Color::Rgb(195, 232, 141);
let yellow = Color::Rgb(255, 203, 107);
let red = Color::Rgb(240, 113, 120);
let fg = Color::Rgb(166, 172, 205);
let comment = Color::Rgb(98, 104, 128);
let bg = Color::Rgb(41, 45, 62);
let surface = Color::Rgb(50, 55, 77);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(130, 136, 165),
fg_muted: comment,
accent: purple,
accent2: purple,
green,
red,
yellow,
blue,
orange: yellow,
is_dark: true,
};
Self {
assistant: blue,
md_code: cyan,
md_bullet: blue,
..Self::from_palette(&p)
}
}
pub(super) fn cobalt2() -> Self {
let blue = Color::Rgb(0, 136, 255);
let cyan = Color::Rgb(158, 255, 255);
let green = Color::Rgb(58, 217, 0);
let yellow = Color::Rgb(255, 198, 0);
let red = Color::Rgb(255, 0, 0);
let orange = Color::Rgb(255, 157, 0);
let fg = Color::Rgb(255, 255, 255);
let comment = Color::Rgb(95, 115, 135);
let bg = Color::Rgb(25, 53, 73);
let surface = Color::Rgb(30, 65, 99);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(200, 215, 225),
fg_muted: comment,
accent: blue,
accent2: cyan,
green,
red,
yellow,
blue: cyan,
orange,
is_dark: true,
};
Self {
assistant: cyan,
md_header: orange,
md_code: cyan,
..Self::from_palette(&p)
}
}
pub(super) fn horizon() -> Self {
let red = Color::Rgb(233, 86, 120);
let orange = Color::Rgb(250, 183, 149);
let yellow = Color::Rgb(250, 194, 154);
let green = Color::Rgb(41, 211, 152);
let cyan = Color::Rgb(89, 225, 227);
let blue = Color::Rgb(107, 223, 230);
let pink = Color::Rgb(238, 100, 174);
let fg = Color::Rgb(224, 224, 224);
let comment = Color::Rgb(99, 103, 115);
let bg = Color::Rgb(28, 30, 38);
let surface = Color::Rgb(35, 37, 48);
let p = ThemePalette {
bg,
surface,
fg,
fg_dim: Color::Rgb(176, 178, 185),
fg_muted: comment,
accent: red,
accent2: red,
green,
red,
yellow,
blue: cyan,
orange,
is_dark: true,
};
Self {
assistant: cyan,
md_header: pink,
md_code: orange,
md_bullet: blue,
..Self::from_palette(&p)
}
}
}