Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ release versions follow [Semantic Versioning](https://semver.org/spec/v2.0.0.htm

## [Unreleased]

### Changed

- Highlight active tabs with the secondary accent and render LSP-tagged unnecessary code in subdued slate grey.

## [0.1.0] - 2026-07-19

### Added
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ Vulkanite automatically detects supported plugins installed through lazy.nvim or
- [nvim-cmp](https://github.com/hrsh7th/nvim-cmp) and [blink.cmp](https://github.com/saghen/blink.cmp)
- [which-key.nvim](https://github.com/folke/which-key.nvim)
- [lazy.nvim](https://github.com/folke/lazy.nvim)
- [bufferline.nvim](https://github.com/akinsho/bufferline.nvim)
- [neo-tree.nvim](https://github.com/nvim-neo-tree/neo-tree.nvim) and [nvim-tree.lua](https://github.com/nvim-tree/nvim-tree.lua)
- [noice.nvim](https://github.com/folke/noice.nvim) and [nvim-notify](https://github.com/rcarriga/nvim-notify)
- [snacks.nvim](https://github.com/folke/snacks.nvim)
Expand Down
3 changes: 2 additions & 1 deletion doc/vulkanite.txt
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ gitsigns gitsigns.nvim
blink blink.cmp
which_key which-key.nvim
lazy lazy.nvim
bufferline bufferline.nvim
neo_tree neo-tree.nvim
nvim_tree nvim-tree.lua
noice noice.nvim
Expand Down Expand Up @@ -195,7 +196,7 @@ UI bg, bg_alt, bg_float, fg, fg_bright, fg_dim, comment,
gutter, selection
Syntax and accents value, docstring, accent, sky_blue, teal, bright_teal,
purple, ok
Diagnostics error, warn, info, hint
Diagnostics error, warn, info, hint, unnecessary
Terminal terminal (a 16-entry ANSI color array)

`colors.roles` is internal. Override the public keys instead.
Expand Down
3 changes: 3 additions & 0 deletions lua/vulkanite/colors.lua
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ local function derive_roles(colors)
info = colors.info,
hint = colors.hint,
ok = colors.ok,
unnecessary = colors.unnecessary,
}
local diff = {
add = colors.ok,
Expand Down Expand Up @@ -74,6 +75,7 @@ local function derive_roles(colors)
info = diagnostic.info,
hint = diagnostic.hint,
ok = diagnostic.ok,
unnecessary = diagnostic.unnecessary,
accent = accent.primary,
accent_secondary = accent.secondary,
match = accent.match,
Expand Down Expand Up @@ -102,6 +104,7 @@ local function resolve(opts, apply_overrides)
hint = p.muted_blue,
selection = p.slate_grey,
ok = p.bright_green,
unnecessary = p.slate_grey,
accent = p.bright_blue,
sky_blue = p.sky_blue,
purple = p.purple,
Expand Down
1 change: 1 addition & 0 deletions lua/vulkanite/config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ M.integration_keys = {
"blink",
"which_key",
"lazy",
"bufferline",
"neo_tree",
"nvim_tree",
"noice",
Expand Down
4 changes: 3 additions & 1 deletion lua/vulkanite/groups/base.lua
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ function M.setup(colors, opts)
-- Background fill after tab-page labels.
TabLineFill = { fg = colors.ui.gutter, bg = colors.ui.bg_alt },
-- Active tab-page label.
TabLineSel = { fg = colors.diagnostic.ok, bg = colors.ui.bg_alt },
TabLineSel = { fg = colors.accent.secondary, bg = colors.ui.bg_alt },
-- Titles for buffers, quickfix lists, and plugin headings.
Title = { fg = colors.accent.primary },
-- Legacy vertical split separator.
Expand Down Expand Up @@ -201,6 +201,8 @@ function M.setup(colors, opts)
DiagnosticHint = { fg = colors.diagnostic.hint },
-- Diagnostic success text from Neovim diagnostics.
DiagnosticOk = { fg = colors.diagnostic.ok },
-- Code marked unnecessary or unused by a diagnostic source.
DiagnosticUnnecessary = { fg = colors.diagnostic.unnecessary },
-- Undercurl for ranges covered by error diagnostics.
DiagnosticUnderlineError = { undercurl = true, sp = colors.diagnostic.error },
-- Undercurl for ranges covered by warning diagnostics.
Expand Down
12 changes: 12 additions & 0 deletions lua/vulkanite/groups/integrations/bufferline.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
local M = {}

M.url = "https://github.com/akinsho/bufferline.nvim"

function M.get(colors, opts)
return {
-- Bufferline selected buffer name.
BufferLineBufferSelected = { fg = colors.accent_secondary, bold = true, italic = true },
}
end

return M
29 changes: 29 additions & 0 deletions test/vulkanite_spec.lua
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ local integration_probe_groups = {
"BlinkCmpLabelMatch",
"WhichKey",
"LazyH1",
"BufferLineBufferSelected",
"NeoTreeDirectoryName",
"NvimTreeFolderName",
"NoiceCmdlinePopup",
Expand Down Expand Up @@ -191,6 +192,11 @@ local function run()
0x8fe0fa,
"CursorLineNr marks the cursor line with the accent"
)
assert_eq(
vim.api.nvim_get_hl(0, { name = "TabLineSel" }).fg,
0x4fa3a6,
"TabLineSel marks the active tab with the secondary accent"
)
local search_highlight = vim.api.nvim_get_hl(0, { name = "Search", link = false })
assert_eq(search_highlight.fg, 0x151b1e, "Search uses dark text")
assert_eq(search_highlight.bg, 0x76c7e3, "Search uses one blue background")
Expand Down Expand Up @@ -344,13 +350,21 @@ local function run()
"#e03f32",
"diagnostic role is derived centrally"
)
assert_eq(
semantic_colors.roles.diagnostic.unnecessary,
"#5c6370",
"unnecessary diagnostic role is derived centrally"
)
assert_eq(semantic_colors.roles.accent.icon, "#9083B9", "icon role is derived centrally")
assert_eq(vim.api.nvim_get_hl(0, { name = "ErrorMsg" }).fg, 0xe03f32, "ErrorMsg uses vivid red")
assert_eq(
vim.api.nvim_get_hl(0, { name = "DiagnosticError" }).fg,
0xe03f32,
"DiagnosticError uses vivid red"
)
local unnecessary_highlight = vim.api.nvim_get_hl(0, { name = "DiagnosticUnnecessary" })
assert_eq(unnecessary_highlight.fg, 0x5c6370, "unnecessary code uses slate grey")
assert_eq(unnecessary_highlight.nocombine, nil, "unnecessary code preserves syntax styles")
assert_eq(vim.api.nvim_get_hl(0, { name = "WarningMsg" }).fg, 0xe0af68, "WarningMsg uses yellow")
assert_eq(
vim.api.nvim_get_hl(0, { name = "DiagnosticWarn" }).fg,
Expand Down Expand Up @@ -509,6 +523,7 @@ local function run()
require("vulkanite").load({
on_colors = function(colors)
colors.error = "#ff0000"
colors.unnecessary = "#808080"
end,
on_highlights = function(groups, colors)
groups.VulkaniteOverrideProbe = { fg = colors.error }
Expand All @@ -524,13 +539,23 @@ local function run()
0xff0000,
"on_highlights sees colors"
)
assert_eq(
vim.api.nvim_get_hl(0, { name = "DiagnosticUnnecessary" }).fg,
0x808080,
"on_colors mutates unnecessary diagnostics independently"
)
require("vulkanite").load({})
assert_unset("VulkaniteOverrideProbe", "reload clears callback-defined highlights")
assert_eq(
vim.api.nvim_get_hl(0, { name = "DiagnosticError" }).fg,
0xe03f32,
"reload restores default semantic colors"
)
assert_eq(
vim.api.nvim_get_hl(0, { name = "DiagnosticUnnecessary" }).fg,
0x5c6370,
"reload restores the default unnecessary color"
)

reset_vulkanite()
require("vulkanite").load({
Expand Down Expand Up @@ -602,6 +627,10 @@ local function run()
assert_unset("WhichKeyFloat", "obsolete which-key group is not defined")
assert_unset("SnacksPickerGitHubIssue", "obsolete Snacks GitHub issue group is not defined")
assert_eq(vim.api.nvim_get_hl(0, { name = "LazyValue" }).fg, 0xe05f64, "LazyValue uses value red")
local selected_buffer = vim.api.nvim_get_hl(0, { name = "BufferLineBufferSelected" })
assert_eq(selected_buffer.fg, 0x4fa3a6, "selected bufferline buffer uses the secondary accent")
assert_eq(selected_buffer.bold, true, "selected bufferline buffer remains bold")
assert_eq(selected_buffer.italic, true, "selected bufferline buffer remains italic")
assert_eq(
vim.api.nvim_get_hl(0, { name = "LspKindUnit" }).fg,
0xe05f64,
Expand Down