neovim custom invero light-theme #1

Merged
tomas.mirchev merged 15 commits from light-theme into main 2025-09-26 03:06:13 +00:00
9 changed files with 268 additions and 74 deletions
Showing only changes of commit 42e56f8320 - Show all commits

View File

@ -0,0 +1,97 @@
-- colors/inStatusLinevero.lua
local palette = require("utils.palette")
-- reset highlights
vim.cmd("hi clear")
if vim.fn.exists("syntax_on") == 1 then
vim.cmd("syntax reset")
end
vim.opt.background = "light"
vim.g.colors_name = "invero"
local colors = {
-- neutrals
base = palette[255], -- #eeeeee, white (bg)
surface = palette[253], -- #dadada, light gray (cursor line bg)
text = palette[238], -- #444444, dark gray (terminal fg)
muted = palette[247], -- #9e9e9e, gray (comments, line numbers, dividers)
accent = palette[27], -- #005fff, standard blue (cursor, dirs)
accent_light = palette[153], -- #afd7ff light sky blue (selection bg)
syntax = palette[60], -- #5f5f87, slate / gray-blue (syntax fg)
red = palette[196], -- #ff0000, red
orange = palette[166], -- #d75f00, orange
orange_light = palette[180], -- #ffd7af, orange light
yellow = palette[184], -- #ffd75f, yellow
green = palette[34], -- #00af5f, green
none = "NONE" -- no color / transparent
}
local theme = {
Normal = { fg = colors.text, bg = colors.none },
LineNr = { fg = colors.muted },
CursorLineNr = { fg = colors.accent, bold = true },
CursorLine = { bg = colors.surface },
Visual = { bg = colors.accent_light },
Search = { fg = colors.orange },
CurSearch = { fg = colors.base, bg = colors.orange, bold = true },
IncSearch = { fg = colors.base, bg = colors.orange, bold = true },
WinSeparator = { fg = colors.muted },
StatusLine = { fg = colors.text, bg = colors.none },
TabLine = { fg = colors.red },
TabLineSel = { fg = colors.red, bold = true },
TabLineFill = { bg = colors.red },
-- Telescope
TelescopeBorder = { fg = colors.muted },
TelescopePromptPrefix = { fg = colors.accent },
TelescopeSelection = { bg = colors.surface },
-- Neo-tree
NeoTreeDirectoryName = { fg = colors.accent },
NeoTreeFileName = { fg = colors.text },
-- NeoTreeNormal = { bg = colors.muted },
-- NeoTreeNormalNC = { bg = colors.muted },
}
-- apply theme groups
for group, opts in pairs(theme) do
vim.api.nvim_set_hl(0, group, opts)
end
-- apply Tree-sitter defaults: all base4, comments special-case
local highlights = vim.fn.getcompletion("@", "highlight")
for _, hl in ipairs(highlights) do
vim.api.nvim_set_hl(0, hl, { fg = colors.syntax })
end
vim.api.nvim_set_hl(0, "@comment", { fg = colors.muted, italic = true })
vim.api.nvim_create_autocmd({ "WinEnter" }, {
callback = function() vim.wo.cursorline = true end,
})
vim.api.nvim_create_autocmd({ "WinLeave" }, {
callback = function() vim.wo.cursorline = false end,
})
-- TEST >>
vim.opt.laststatus = 3
vim.opt.fillchars:append({ stl = '', stlnc = '' })
-- vim.o.statusline = " "
-- vim.api.nvim_set_hl(0, "WinSeparator", { bg = colors.surface }) -- vertical bg
-- vim.api.nvim_set_hl(0, "StatusLine", { bg = colors.surface }) -- horizontal bg
-- vim.api.nvim_set_hl(0, "StatusLineNC", { bg = colors.surface }) -- horizontal bg
-- vim.api.nvim_create_autocmd("FileType", {
-- pattern = "neo-tree",
-- callback = function(ev)
-- -- force your own winhighlight
-- vim.api.nvim_win_set_option(ev.win, "winhighlight", "WinSeparator:WinSeparator")
-- -- force fillchars
-- vim.wo[ev.win].fillchars = "vert:│,horiz:─,horizup:┴,horizdown:┬,vertleft:├,vertright:┤,verthoriz:┼"
-- end,
-- })

View File

@ -1,24 +1,22 @@
{
"cmp-nvim-lsp": { "branch": "main", "commit": "39e2eda76828d88b773cc27a3f61d2ad782c922d" },
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
"conform.nvim": { "branch": "master", "commit": "d28ccf945374edd9f1c34a82f6c22261dbd8ab98" },
"fidget.nvim": { "branch": "main", "commit": "e2a175c2abe2d4f65357da1c98c59a5cfb2b543f" },
"harpoon": { "branch": "harpoon2", "commit": "a84ab829eaf3678b586609888ef52f7779102263" },
"cmp-nvim-lsp": { "branch": "main", "commit": "bd5a7d6db125d4654b50eeae9f5217f24bb22fd3" },
"cmp-path": { "branch": "main", "commit": "c642487086dbd9a93160e1679a1327be111cbc25" },
"conform.nvim": { "branch": "master", "commit": "b4aab989db276993ea5dcb78872be494ce546521" },
"fidget.nvim": { "branch": "main", "commit": "4d5858bd4c471c895060e1b9f3575f1551184dc5" },
"harpoon": { "branch": "harpoon2", "commit": "ed1f853847ffd04b2b61c314865665e1dadf22c7" },
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "4d0e5b49363cac187326998b96aa6a2884e0e89b" },
"mason.nvim": { "branch": "main", "commit": "e2f7f9044ec30067bc11800a9e266664b88cda22" },
"neo-tree.nvim": { "branch": "main", "commit": "a77af2e764c5ed4038d27d1c463fa49cd4794e07" },
"nui.nvim": { "branch": "main", "commit": "b58e2bfda5cea347c9d58b7f11cf3012c7b3953f" },
"nvim-autopairs": { "branch": "master", "commit": "ee297f215e95a60b01fde33275cc3c820eddeebe" },
"nvim-cmp": { "branch": "main", "commit": "f17d9b4394027ff4442b298398dfcaab97e40c4f" },
"nvim-lspconfig": { "branch": "master", "commit": "bc6ada4b0892b7f10852c0b8ca7209fd39a6d754" },
"nvim-treesitter": { "branch": "master", "commit": "7dc8aabe86db8c2f23520e8334f7584f83e84342" },
"nvim-ts-autotag": { "branch": "main", "commit": "1cca23c9da708047922d3895a71032bc0449c52d" },
"nvim-web-devicons": { "branch": "master", "commit": "e87554285f581047b1bf236794b0eb812b444b87" },
"plenary.nvim": { "branch": "master", "commit": "2d9b06177a975543726ce5c73fca176cedbffe9d" },
"rose-pine": { "branch": "main", "commit": "91548dca53b36dbb9d36c10f114385f759731be1" },
"schemastore.nvim": { "branch": "main", "commit": "f8d6e9068861888651f68958521b1958314aac41" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "cf48d4dfce44e0b9a2e19a008d6ec6ea6f01a83b" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "25c11854aa25558ee6c03432edfa0df0217324be" },
"mason.nvim": { "branch": "main", "commit": "d66c60e17dd6fd8165194b1d14d21f7eb2c1697a" },
"nvim-autopairs": { "branch": "master", "commit": "23320e75953ac82e559c610bec5a90d9c6dfa743" },
"nvim-cmp": { "branch": "main", "commit": "b5311ab3ed9c846b585c0c15b7559be131ec4be9" },
"nvim-lspconfig": { "branch": "master", "commit": "d9879110d0422a566fa01d732556f4d5515e1738" },
"nvim-tree.lua": { "branch": "master", "commit": "321bc61580fd066b76861c32de3319c3a6d089e7" },
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },
"nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" },
"nvim-web-devicons": { "branch": "master", "commit": "6e51ca170563330e063720449c21f43e27ca0bc1" },
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
"schemastore.nvim": { "branch": "main", "commit": "0fccf9234acfd981867cbd42c4101829e6808790" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "1f08ed60cafc8f6168b72b80be2b2ea149813e55" },
"telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" },
"telescope.nvim": { "branch": "0.1.x", "commit": "a0bbec21143c7bc5f8bb02e0005fa0b982edc026" }
}

View File

@ -8,4 +8,11 @@ if not (vim.uv or vim.loop).fs_stat(lazypath) then
end ---@diagnostic disable-next-line: undefined-field
vim.opt.rtp:prepend(lazypath)
require('lazy').setup('plugins')
require("lazy").setup({
spec = { { import = "plugins" } },
ui = {
backdrop = 100,
border = "rounded"
},
})

View File

@ -8,14 +8,12 @@ vim.g.have_nerd_font = true
-- Add vertical line
-- vim.opt.colorcolumn = "100"
-- vim.opt.laststatus = 3
vim.opt.signcolumn = "no"
-- Enable TrueColor
vim.opt.termguicolors = true
-- Disable Neovim background
vim.api.nvim_set_hl(0, "Normal", { bg = "none" })
vim.api.nvim_set_hl(0, "NormalFloat", { bg = "none" })
-- Scroll lines/columns
vim.opt.mousescroll = "hor:1,ver:1"
@ -42,7 +40,7 @@ vim.opt.relativenumber = true
vim.opt.mouse = "a"
-- Full path on status line
vim.opt.statusline = "%F%m%r%h%w%=%l,%c %P"
vim.opt.statusline = "> %F%m%r%h%w %= %l,%c %P "
-- Sync clipboard between OS and Neovim
vim.schedule(function()
@ -94,3 +92,6 @@ vim.diagnostic.config({
[vim.diagnostic.severity.HINT] = 1,
}
})
-- Now load the colorscheme (this will trigger the autocmd)
vim.cmd.colorscheme("invero")

View File

@ -1,11 +0,0 @@
return {
"rose-pine/neovim",
name = "rose-pine",
config = function()
require("rose-pine").setup({
disable_background = true,
disable_float_background = true,
})
vim.cmd("colorscheme rose-pine")
end,
}

View File

@ -21,14 +21,20 @@ return {
"neovim/nvim-lspconfig",
dependencies = {
{ "williamboman/mason.nvim", config = true },
"williamboman/mason-lspconfig.nvim",
{ "williamboman/mason.nvim", version = "1.8.0", config = true },
{ "williamboman/mason-lspconfig.nvim", version = "1.31.0"},
{ "j-hui/fidget.nvim", opts = {} }, -- side fidget showing status
"hrsh7th/cmp-nvim-lsp", -- completion
"b0o/schemastore.nvim",
},
config = function()
require("mason").setup()
require("mason").setup({
ui = {
border = "rounded",
backdrop = 0
},
})
require("mason-lspconfig").setup()
local lspconfig = require("lspconfig")

View File

@ -1,33 +1,79 @@
return {
"nvim-neo-tree/neo-tree.nvim",
version = "*",
dependencies = {
"nvim-lua/plenary.nvim",
"nvim-tree/nvim-web-devicons",
"MunifTanjim/nui.nvim",
},
cmd = "Neotree",
keys = {
{ "<Leader>et", ":Neotree position=left toggle<CR>", desc = "Explorer Toggle", silent = true },
{ "<Leader>E", ":Neotree focus<CR>", desc = "Explorer Focus", silent = true },
{ "<Leader>ef", ":Neotree float<CR>", desc = "Explorer Float", silent = true },
{ "<Leader>eb", ":Neotree buffers<CR>", desc = "Explorer Buffers", silent = true },
{ "<Leader>eg", ":Neotree git_status<CR>", desc = "Explorer Git", silent = true },
},
opts = {
filesystem = {
follow_current_file = {
enabled = true, -- Enable this feature
leave_dirs_open = true, -- Leave directories open when following
},
filtered_items = {
visible = true,
},
window = {
mappings = {
["<Leader>e"] = "close_window",
},
},
},
},
"nvim-tree/nvim-tree.lua",
version = "*",
lazy = false,
keys = {
{ "<Leader>et", ":NvimTreeToggle<CR>", desc = "Explorer Toggle", silent = true },
},
config = function()
require("nvim-tree").setup {
renderer = {
icons = {
show = {
file = false,
folder = false,
folder_arrow = false,
git = false,
modified = false,
hidden = false,
diagnostics = false,
bookmarks = false,
},
},
},
}
end,
}
-- return {
-- "nvim-neo-tree/neo-tree.nvim",
-- version = "*",
-- dependencies = {
-- "nvim-lua/plenary.nvim",
-- "nvim-tree/nvim-web-devicons",
-- "MunifTanjim/nui.nvim",
-- },
-- cmd = "Neotree",
-- keys = {
-- { "<Leader>et", ":Neotree position=left toggle<CR>", desc = "Explorer Toggle", silent = true },
-- { "<Leader>E", ":Neotree focus<CR>", desc = "Explorer Focus", silent = true },
-- { "<Leader>ef", ":Neotree float<CR>", desc = "Explorer Float", silent = true },
-- { "<Leader>eb", ":Neotree buffers<CR>", desc = "Explorer Buffers", silent = true },
-- { "<Leader>eg", ":Neotree git_status<CR>", desc = "Explorer Git", silent = true },
-- },
-- opts = {
-- event_handlers = {
-- {
-- event = require("neo-tree.ui.events").NEO_TREE_WINDOW_AFTER_OPEN,
-- handler = function(args)
-- if args and args.winid and vim.api.nvim_win_is_valid(args.winid) then
-- vim.api.nvim_win_set_option(args.winid, "colorcolumn", "")
-- vim.api.nvim_win_set_option(args.winid, "signcolumn", "no")
-- end
-- end,
-- },
-- },
-- popup_border_style = "single",
-- window = {
-- mappings = {
-- ["<Leader>e"] = "close_window",
-- },
-- },
-- default_component_configs = {
-- icon = { enabled = false },
-- git_status = { symbols = {}, align = "none" },
-- name = { trailing_slash = true }
-- },
-- enable_git_status = false,
-- enable_diagnostics = false,
-- filesystem = {
-- follow_current_file = {
-- enabled = true, -- Enable this feature
-- leave_dirs_open = true, -- Leave directories open when following
-- },
-- filtered_items = {
-- visible = true,
-- }
-- },
-- },
-- }

View File

@ -59,11 +59,10 @@ return { -- Fuzzy Finder (files, lsp, etc)
defaults = {
layout_strategy = "vertical",
layout_config = {
-- vertical = { width = 0.5 }
-- horizontal = {
-- width = 0.9,
-- preview_width = 0.5,
-- },
width = { 0.95, max = 100 },
height = 0.95,
preview_cutoff = 1,
preview_height = 0.7
},
mappings = {
n = {

View File

@ -0,0 +1,51 @@
local function xterm256_palette()
local colors = {}
-- 015: system colors (manual)
local ansi = {
"#000000", -- 0 black
"#d70000", -- 1 red
"#5f8700", -- 2 green
"#af8700", -- 3 yellow/brown
"#005faf", -- 4 blue
"#5f5faf", -- 5 magenta/indigo
"#008787", -- 6 cyan
"#bcbcbc", -- 7 light gray
"#808080", -- 8 dark gray
"#ff5f5f", -- 9 bright red
"#87d75f", -- 10 bright green
"#ffd700", -- 11 bright yellow
"#5f87d7", -- 12 bright blue
"#8787ff", -- 13 bright magenta
"#5fd7d7", -- 14 bright cyan
"#ffffff", -- 15 white
}
for i, hex in ipairs(ansi) do
colors[i-1] = hex
end
-- 16231: 6x6x6 cube
local steps = {0, 95, 135, 175, 215, 255}
local idx = 16
for r = 1,6 do
for g = 1,6 do
for b = 1,6 do
colors[idx] = string.format("#%02x%02x%02x", steps[r], steps[g], steps[b])
idx = idx + 1
end
end
end
-- 232255: grayscale
for gray = 0,23 do
local level = 8 + gray * 10
colors[idx] = string.format("#%02x%02x%02x", level, level, level)
idx = idx + 1
end
return colors
end
return xterm256_palette()