VS-Dark theme for nvim

This commit is contained in:
alejo committed 2026-11-04 16:33:50 -03:00
1 parent 416e87fa8a
commit d6b10c0584
5 files changed
+41 -31

No files matched your search

+2 -2
View File
@@ -122,7 +122,7 @@ The installer asks which Neovim frontend(s) to set up:
There's only one config either way (`config/nvim/`) — Neovide reads the exact same `init.lua`, so keymaps, plugins, and the LSP setup are all identical between the two. Two things differ between them — cursor animation and background transparency — and the config detects which frontend it's running under (`vim.g.neovide`) and picks the right mechanism for each automatically: There's only one config either way (`config/nvim/`) — Neovide reads the exact same `init.lua`, so keymaps, plugins, and the LSP setup are all identical between the two. Two things differ between them — cursor animation and background transparency — and the config detects which frontend it's running under (`vim.g.neovide`) and picks the right mechanism for each automatically:
- **Terminal**: [`smear-cursor.nvim`](https://github.com/sphamba/smear-cursor.nvim) draws the animated cursor trail — a terminal has no native equivalent, so this fills that gap. `koda.nvim`'s `transparent` option is on, clearing highlight-group backgrounds so whatever the *terminal emulator* draws behind Neovim shows through — including a background image, if your terminal supports one (e.g. kitty's own `background_image` setting). That's a terminal-level feature this config has no reach into; without it configured on the terminal side, transparency here just shows the terminal's normal background color, which is a harmless no-op look. - **Terminal**: [`smear-cursor.nvim`](https://github.com/sphamba/smear-cursor.nvim) draws the animated cursor trail — a terminal has no native equivalent, so this fills that gap. `vscode.nvim`'s `transparent` option is on, clearing highlight-group backgrounds so whatever the *terminal emulator* draws behind Neovim shows through — including a background image, if your terminal supports one (e.g. kitty's own `background_image` setting). That's a terminal-level feature this config has no reach into; without it configured on the terminal side, transparency here just shows the terminal's normal background color, which is a harmless no-op look.
- **Neovide**: uses Neovide's own built-in, GPU-accelerated cursor VFX (`railgun` mode) instead of smear-cursor.nvim — running both at once would be two different animation systems fighting over the same cursor, so smear-cursor.nvim doesn't even load when `vim.g.neovide` is set. For background: Neovide has no background-image setting at all — two attempts to add one ([neovide/neovide#2419](https://github.com/neovide/neovide/pull/2419), [#3067](https://github.com/neovide/neovide/pull/3067)) were both closed as abandoned, most recently in October 2025; the feature request itself ([neovide/neovide#342](https://github.com/neovide/neovide/issues/342)) is still open. `vim.g.neovide_opacity` (set to `0.9`) is the closest real substitute — it makes the whole window translucent, so on a compositing window manager, whatever's behind it (your desktop wallpaper, if Neovide isn't covering the whole screen) blends through. Adjust or remove it in `init.lua` to taste. - **Neovide**: uses Neovide's own built-in, GPU-accelerated cursor VFX (`railgun` mode) instead of smear-cursor.nvim — running both at once would be two different animation systems fighting over the same cursor, so smear-cursor.nvim doesn't even load when `vim.g.neovide` is set. For background: Neovide has no background-image setting at all — two attempts to add one ([neovide/neovide#2419](https://github.com/neovide/neovide/pull/2419), [#3067](https://github.com/neovide/neovide/pull/3067)) were both closed as abandoned, most recently in October 2025; the feature request itself ([neovide/neovide#342](https://github.com/neovide/neovide/issues/342)) is still open. `vim.g.neovide_opacity` (set to `0.9`) is the closest real substitute — it makes the whole window translucent, so on a compositing window manager, whatever's behind it (your desktop wallpaper, if Neovide isn't covering the whole screen) blends through. Adjust or remove it in `init.lua` to taste.
Once installed, launch the desktop app with `neovide` from a terminal — if that command isn't found right after setup, open a new shell first (a fresh `rustup` install updates `PATH` via shell startup files, which the setup script's own shell won't have re-read). Once installed, launch the desktop app with `neovide` from a terminal — if that command isn't found right after setup, open a new shell first (a fresh `rustup` install updates `PATH` via shell startup files, which the setup script's own shell won't have re-read).
@@ -158,7 +158,7 @@ Once installed, launch the desktop app with `neovide` from a terminal — if tha
## Look & feel ## Look & feel
- **Theme**: [`koda.nvim`](https://github.com/oskarnurm/koda.nvim) (dark variant), nudged to a near-black background, with custom colors for error/warn/info/hint diagnostic virtual lines. - **Theme**: [`vscode.nvim`](https://github.com/Mofiqul/vscode.nvim) (dark variant, VS Code Dark+ palette), on a near-black `#090909` background, with custom tinted backgrounds for error/warn/info/hint diagnostic virtual lines. lualine uses the plugin's own `vscode` theme.
- **Cursor animation**: an animated cursor trail in both frontends, via different mechanisms — see [Terminal vs. desktop (Neovide)](#terminal-vs-desktop-neovide) for which plugin does what and why. - **Cursor animation**: an animated cursor trail in both frontends, via different mechanisms — see [Terminal vs. desktop (Neovide)](#terminal-vs-desktop-neovide) for which plugin does what and why.
- **Dashboard**: `alpha-nvim` start screen with quick actions — find file, recent files, live grep, new file, edit config, quit. - **Dashboard**: `alpha-nvim` start screen with quick actions — find file, recent files, live grep, new file, edit config, quit.
- **Statusline**: `lualine`, styled with true Powerline arrow separators (the seamless, edge-to-edge kind — between sections, a thinner version between components within a section). Left to right: - **Statusline**: `lualine`, styled with true Powerline arrow separators (the seamless, edge-to-edge kind — between sections, a thinner version between components within a section). Left to right:
+1 -1
View File
@@ -45,7 +45,7 @@ vim.opt.fillchars = {
} }
vim.api.nvim_create_autocmd("ColorScheme", { vim.api.nvim_create_autocmd("ColorScheme", {
callback = function() callback = function()
vim.api.nvim_set_hl(0, "WinSeparator", { fg = "#3b4261" }) vim.api.nvim_set_hl(0, "WinSeparator", { fg = "#444444" })
end, end,
}) })
+33 -21
View File
@@ -1,5 +1,6 @@
return { return {
-- REALLY Dark Theme (near-black koda) -- Visual Studio-style dark theme (VS Code "Dark+", via vscode.nvim),
-- on a near-black #090909 background
-- --
-- Terminal Neovim and Neovide (the desktop GUI app) render the same -- Terminal Neovim and Neovide (the desktop GUI app) render the same
-- highlight groups, so the theme itself needs nothing -- highlight groups, so the theme itself needs nothing
@@ -7,10 +8,16 @@ return {
-- in two (see smear-cursor.lua and init.lua), since a terminal and a GPU-rendered GUI window have -- in two (see smear-cursor.lua and init.lua), since a terminal and a GPU-rendered GUI window have
-- different ways of drawing one. -- different ways of drawing one.
{ {
"oskarnurm/koda.nvim", "Mofiqul/vscode.nvim",
priority = 1000, priority = 1000,
config = function() config = function()
require("koda").setup({ -- vscode.nvim picks its dark or light palette from 'background',
-- so pin it before asking for colors below.
vim.o.background = "dark"
local c = require("vscode.colors").get_colors()
require("vscode").setup({
style = "dark",
-- Terminal only (see the "not Neovide" comment on the setting -- Terminal only (see the "not Neovide" comment on the setting
-- above): clears highlight-group backgrounds to NONE so -- above): clears highlight-group backgrounds to NONE so
-- whatever the *terminal emulator* draws behind Neovim shows -- whatever the *terminal emulator* draws behind Neovim shows
@@ -23,27 +30,32 @@ return {
-- Neovide doesn't use this option at all -- see -- Neovide doesn't use this option at all -- see
-- vim.g.neovide_opacity in init.lua for its equivalent. -- vim.g.neovide_opacity in init.lua for its equivalent.
transparent = not vim.g.neovide, transparent = not vim.g.neovide,
colors = { -- Near-black background instead of VS Code's #1F1F1F. (With
-- koda's own "dark" variant defaults to #101010 -- nudged a -- `transparent` on, vscode.nvim forces vscBack to NONE, so this
-- touch further down to match the old pure-black background. -- shows in Neovide; in a terminal the terminal's own background
bg = "#090909", -- shows instead -- set that to #090909 to match.) The cursor-line
line = "#1a1a1a", -- shade and active-tab background are nudged to fit it.
color_overrides = {
vscBack = "#090909",
vscCursorDarkDark = "#1a1a1a",
vscTabCurrent = vim.g.neovide and "#090909" or "NONE",
}, },
on_highlights = function(hl, c) group_overrides = {
-- koda has no dedicated "hint" color; c.cyan is the closest -- Tinted backgrounds behind diagnostic virtual text/lines.
-- hue match to the dark-teal hint background below. -- vscode.nvim's own Hint color is the same blue as Info, so
hl.DiagnosticVirtualTextError = { bg = "#351010", fg = c.danger } -- hints use the palette's teal to match the dark-teal tint.
hl.DiagnosticVirtualTextWarn = { bg = "#35280b", fg = c.warning } DiagnosticVirtualTextError = { bg = "#351010", fg = c.vscRed },
hl.DiagnosticVirtualTextInfo = { bg = "#0b2035", fg = c.info } DiagnosticVirtualTextWarn = { bg = "#35280b", fg = c.vscYellow },
hl.DiagnosticVirtualTextHint = { bg = "#0b3528", fg = c.cyan } DiagnosticVirtualTextInfo = { bg = "#0b2035", fg = c.vscBlue },
DiagnosticVirtualTextHint = { bg = "#0b3528", fg = c.vscBlueGreen },
hl.DiagnosticVirtualLinesError = { bg = "#351010", fg = c.danger } DiagnosticVirtualLinesError = { bg = "#351010", fg = c.vscRed },
hl.DiagnosticVirtualLinesWarn = { bg = "#35280b", fg = c.warning } DiagnosticVirtualLinesWarn = { bg = "#35280b", fg = c.vscYellow },
hl.DiagnosticVirtualLinesInfo = { bg = "#0b2035", fg = c.info } DiagnosticVirtualLinesInfo = { bg = "#0b2035", fg = c.vscBlue },
hl.DiagnosticVirtualLinesHint = { bg = "#0b3528", fg = c.cyan } DiagnosticVirtualLinesHint = { bg = "#0b3528", fg = c.vscBlueGreen },
end, },
}) })
vim.cmd.colorscheme("koda-dark") vim.cmd.colorscheme("vscode")
end, end,
}, },
} }
+4 -6
View File
@@ -6,12 +6,10 @@ return {
config = function() config = function()
require("lualine").setup({ require("lualine").setup({
options = { options = {
-- "auto" derives lualine's colors from the active colorscheme's -- vscode.nvim ships a hand-built lualine theme, so use it
-- own highlight groups -- koda doesn't ship a hand-built lualine -- instead of "auto" (which would derive colors from the
-- theme the way some more established colorschemes do, so this -- active colorscheme's highlight groups).
-- is what keeps the statusline actually matching it instead of theme = "vscode",
-- falling back to lualine's generic default palette.
theme = "auto",
-- Powerline private-use-area glyphs (E0B0-E0B3). This needs -- Powerline private-use-area glyphs (E0B0-E0B3). This needs
-- the terminal's font actually set to the PATCHED family -- the terminal's font actually set to the PATCHED family
-- (e.g. "JetBrainsMono Nerd Font" / "CaskaydiaCove Nerd -- (e.g. "JetBrainsMono Nerd Font" / "CaskaydiaCove Nerd
+1 -1
View File
@@ -4,7 +4,7 @@ return {
"rcarriga/nvim-notify", "rcarriga/nvim-notify",
config = function() config = function()
require("notify").setup({ require("notify").setup({
background_colour = "#000000", background_colour = "#090909",
timeout = 3000, timeout = 3000,
-- Stack upward from the bottom instead of down from the top -- Stack upward from the bottom instead of down from the top
-- (nvim-notify anchors to the right by default either way), -- (nvim-notify anchors to the right by default either way),