colorscheme: use borderless telescope

This commit is contained in:
Guanran Wang 2024-02-27 14:34:15 +08:00
parent d31fe5a044
commit ce9dffb286
Signed by: nyancat
SSH key fingerprint: SHA256:8oWGKciPALWut/6WA27oFKofX+6Wtc0gQnsefXLQx/8

View file

@ -2,7 +2,41 @@ return {
"folke/tokyonight.nvim", "folke/tokyonight.nvim",
lazy = false, lazy = false,
priority = 1000, priority = 1000,
opts = {}, opts = {
-- Borderless telescope
-- see: https://github.com/folke/tokyonight.nvim?tab=readme-ov-file#borderless-telescope-example
on_highlights = function(hl, c)
-- local prompt = "#2d3149"
local prompt = c.bg_highlight
hl.TelescopeNormal = {
bg = c.bg_dark,
fg = c.fg_dark,
}
hl.TelescopeBorder = {
bg = c.bg_dark,
fg = c.bg_dark,
}
hl.TelescopePromptNormal = {
bg = prompt,
}
hl.TelescopePromptBorder = {
bg = prompt,
fg = prompt,
}
hl.TelescopePromptTitle = {
bg = prompt,
fg = prompt,
}
hl.TelescopePreviewTitle = {
bg = c.bg_dark,
fg = c.bg_dark,
}
hl.TelescopeResultsTitle = {
bg = c.bg_dark,
fg = c.bg_dark,
}
end,
},
init = function() init = function()
vim.cmd([[ colorscheme tokyonight-night ]]) vim.cmd([[ colorscheme tokyonight-night ]])
end, end,