mirror of
https://github.com/nyakang/nyaterm.git
synced 2026-11-23 00:02:28 +00:00
feat(ui): align the Dracula interface roles with the VS Code theme
Take four roles from dracula/visual-studio-code instead of deriving them: input background (#282a36), section header (#282a36), hover (#343746, the 75% alpha list.hoverBackground over the editor background) and the focus ring (#6272a4, focusBorder). Buttons stay purple and borders stay #44475a: the extension uses grey buttons and #191a21 borders, which read poorly in this interface.
This commit is contained in:
@@ -176,9 +176,9 @@
|
||||
"bg": "#282a36",
|
||||
"bgPanel": "#21222c",
|
||||
"bgTerminal": "#282a36",
|
||||
"bgHover": "#44475a",
|
||||
"bgInput": "#21222c",
|
||||
"bgSectionHeader": "#343746",
|
||||
"bgHover": "#343746",
|
||||
"bgInput": "#282a36",
|
||||
"bgSectionHeader": "#282a36",
|
||||
"border": "#44475a",
|
||||
"text": "#f8f8f2",
|
||||
"textMuted": "#bababa",
|
||||
@@ -186,7 +186,7 @@
|
||||
"primary": "#bd93f9",
|
||||
"primaryHover": "#a77bfa",
|
||||
"onPrimary": "#282a36",
|
||||
"focusRing": "#bd93f9",
|
||||
"focusRing": "#6272a4",
|
||||
"danger": "#ff5555",
|
||||
"dangerHover": "#ff3f3f",
|
||||
"success": "#50fa7b",
|
||||
|
||||
@@ -983,6 +983,17 @@ mod tests {
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn dracula_dark_interface_roles_follow_the_vscode_extension() {
|
||||
// Source: dracula/visual-studio-code, src/dracula.yml.
|
||||
let palette = theme_palette("dracula");
|
||||
assert_eq!(palette.input, 0x282a36, "input.background");
|
||||
assert_eq!(palette.section_header, 0x282a36, "sideBarSectionHeader");
|
||||
assert_eq!(palette.hover, 0x343746, "list.hoverBackground over #282a36");
|
||||
assert_eq!(palette.focus_ring, 0x6272a4, "focusBorder");
|
||||
assert_eq!(palette.text_dimmed, 0x6272a4, "tab.inactiveForeground");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn windterm_runtime_palettes_match_json_previews_and_original_ansi_colors() {
|
||||
let catalog = nyaterm_core::themes::ThemeCatalog::default();
|
||||
@@ -1053,7 +1064,7 @@ mod tests {
|
||||
0x6d28d9,
|
||||
),
|
||||
(
|
||||
"dracula", 0xbd93f9, 0xa77bfa, 0x282a36, 0xbd93f9, 0x8be9fd, 0xff79c6,
|
||||
"dracula", 0xbd93f9, 0xa77bfa, 0x282a36, 0x6272a4, 0x8be9fd, 0xff79c6,
|
||||
),
|
||||
(
|
||||
"nord", 0x88c0d0, 0x7bb8c9, 0x2e3440, 0x88c0d0, 0x81a1c1, 0x5e81ac,
|
||||
|
||||
Reference in New Issue
Block a user