fix(themes): fix gruvbox and statusline hi

This commit is contained in:
Matt Leong 2021-11-15 09:09:52 -08:00
parent 8e4c45a213
commit 2b290d5dda
4 changed files with 7 additions and 15 deletions

View file

@ -13,10 +13,4 @@ if vim.tbl_isempty(colors) then
return false return false
end end
-- @TODO: move elsewhere
colors.notify_bg = 'Normal'
if config.theme == 'gruvbox' then
colors.notify_bg = colors.bg
end
return colors return colors

View file

@ -56,11 +56,6 @@ highlight('NotifyTRACEIcon', nil, colors.trace)
highlight('TelescopeBorder', 'None', colors.floatBorder) highlight('TelescopeBorder', 'None', colors.floatBorder)
highlight('FloatermBorder', 'None', colors.floatBorder) highlight('FloatermBorder', 'None', colors.floatBorder)
highlight('StatusLine', colors.statusline_bg, 'StatusLine') highlight('StatusLine', colors.statusline_bg, colors.statusline_bg)
highlight('FloatBorder', 'None', colors.floatBorder) highlight('FloatBorder', 'None', colors.floatBorder)
highlight('NormalFloat', 'Normal', 'Normal') highlight('NormalFloat', 'Normal', 'Normal')
local config = require('cosmic.config')
if config.theme == 'gruvbox.nvim' then
vim.o.background = 'dark'
end

View file

@ -46,9 +46,8 @@ function M.init(use, config)
as = 'gruvbox', as = 'gruvbox',
requires = { 'rktjmp/lush.nvim' }, requires = { 'rktjmp/lush.nvim' },
config = function() config = function()
-- todo: does nothing
vim.o.background = 'dark' vim.o.background = 'dark'
vim.cmd('colorscheme gruvbox') vim.cmd('color gruvbox')
end, end,
disable = config.theme ~= 'gruvbox', disable = config.theme ~= 'gruvbox',
}) })

View file

@ -10,7 +10,11 @@ local cosmic_modules = {
for _, mod in ipairs(cosmic_modules) do for _, mod in ipairs(cosmic_modules) do
local ok, err = pcall(require, mod) local ok, err = pcall(require, mod)
if not ok then if mod == 'cosmic.compiled' and not ok then
vim.notify('Run :PackerCompile!', vim.log.levels.WARN, {
title = 'CosmicNvim',
})
elseif not ok then
error(('Error loading %s...\n\n%s'):format(mod, err)) error(('Error loading %s...\n\n%s'):format(mod, err))
end end
end end