refactor config using lush.merge
This commit is contained in:
@@ -166,7 +166,6 @@ highlight CursorLineNr guifg=#2C363C guibg=NONE guisp=NONE gui=bold
|
|||||||
highlight MoreMsg guifg=#617437 guibg=NONE guisp=NONE gui=bold
|
highlight MoreMsg guifg=#617437 guibg=NONE guisp=NONE gui=bold
|
||||||
highlight NormalFloat guifg=NONE guibg=#E1DCD9 guisp=NONE gui=NONE
|
highlight NormalFloat guifg=NONE guibg=#E1DCD9 guisp=NONE gui=NONE
|
||||||
highlight FloatBorder guifg=#786D68 guibg=NONE guisp=NONE gui=NONE
|
highlight FloatBorder guifg=#786D68 guibg=NONE guisp=NONE gui=NONE
|
||||||
highlight! link NormalNC Normal
|
|
||||||
highlight Pmenu guifg=NONE guibg=#DAD3CF guisp=NONE gui=NONE
|
highlight Pmenu guifg=NONE guibg=#DAD3CF guisp=NONE gui=NONE
|
||||||
highlight PmenuSel guifg=NONE guibg=#C4B6AF guisp=NONE gui=NONE
|
highlight PmenuSel guifg=NONE guibg=#C4B6AF guisp=NONE gui=NONE
|
||||||
highlight PmenuSbar guifg=NONE guibg=#B2A39B guisp=NONE gui=NONE
|
highlight PmenuSbar guifg=NONE guibg=#B2A39B guisp=NONE gui=NONE
|
||||||
|
|||||||
@@ -16,11 +16,8 @@ elseif lightness ~= nil then
|
|||||||
vim.api.nvim_echo({ { error_msg, "WarningMsg" } }, true, {})
|
vim.api.nvim_echo({ { error_msg, "WarningMsg" } }, true, {})
|
||||||
end
|
end
|
||||||
|
|
||||||
local solid_vert_split = vim.g.zenbones_solid_vert_split
|
|
||||||
local dim_noncurrent_window = vim.g.zenbones_dim_noncurrent_window
|
|
||||||
|
|
||||||
-- stylua: ignore start
|
-- stylua: ignore start
|
||||||
return lush(function()
|
local theme = lush(function()
|
||||||
return {
|
return {
|
||||||
-- The following are all the Neovim default highlight groups from the docs
|
-- The following are all the Neovim default highlight groups from the docs
|
||||||
-- as of 0.5.0-nightly-446, to aid your theme creation. Your themes should
|
-- as of 0.5.0-nightly-446, to aid your theme creation. Your themes should
|
||||||
@@ -74,7 +71,6 @@ return lush(function()
|
|||||||
MoreMsg { fg = c.leaf, gui = "bold" }, -- |more-prompt|
|
MoreMsg { fg = c.leaf, gui = "bold" }, -- |more-prompt|
|
||||||
NormalFloat { bg = Normal.bg.da(6) }, -- Normal text in floating windows.
|
NormalFloat { bg = Normal.bg.da(6) }, -- Normal text in floating windows.
|
||||||
FloatBorder { fg = Normal.bg.da(50) }, -- Normal text in floating windows.
|
FloatBorder { fg = Normal.bg.da(50) }, -- Normal text in floating windows.
|
||||||
NormalNC (dim_noncurrent_window and { Normal, bg = Normal.bg.abs_da(2) } or { Normal }), -- normal text in non-current windows
|
|
||||||
|
|
||||||
Pmenu { bg = Normal.bg.da(10) }, -- Popup menu: normal item.
|
Pmenu { bg = Normal.bg.da(10) }, -- Popup menu: normal item.
|
||||||
PmenuSel { bg = Normal.bg.da(20) }, -- Popup menu: selected item.
|
PmenuSel { bg = Normal.bg.da(20) }, -- Popup menu: selected item.
|
||||||
@@ -97,7 +93,7 @@ return lush(function()
|
|||||||
TabLine { StatusLine, gui = "italic" }, -- tab pages line, not active tab page label
|
TabLine { StatusLine, gui = "italic" }, -- tab pages line, not active tab page label
|
||||||
TabLineFill { StatusLineNC }, -- tab pages line, where there are no labels
|
TabLineFill { StatusLineNC }, -- tab pages line, where there are no labels
|
||||||
TabLineSel { gui = "bold" }, -- tab pages line, active tab page label
|
TabLineSel { gui = "bold" }, -- tab pages line, active tab page label
|
||||||
VertSplit (solid_vert_split and { bg = StatusLineNC.bg, fg = LineNr.fg } or { fg = PmenuThumb.bg }), -- the column separating vertically split windows
|
VertSplit { fg = PmenuThumb.bg }, -- the column separating vertically split windows
|
||||||
|
|
||||||
Visual { bg = c.stone.li(84) }, -- Visual mode selection
|
Visual { bg = c.stone.li(84) }, -- Visual mode selection
|
||||||
-- VisualNOS { }, -- Visual mode selection when vim is "Not Owning the Selection".
|
-- VisualNOS { }, -- Visual mode selection when vim is "Not Owning the Selection".
|
||||||
@@ -310,4 +306,33 @@ return lush(function()
|
|||||||
}
|
}
|
||||||
end)
|
end)
|
||||||
-- stylua: ignore end
|
-- stylua: ignore end
|
||||||
|
|
||||||
|
local specs = {
|
||||||
|
theme,
|
||||||
|
}
|
||||||
|
|
||||||
|
if vim.g.zenbones_dim_noncurrent_window then
|
||||||
|
table.insert(
|
||||||
|
specs,
|
||||||
|
lush(function()
|
||||||
|
return {
|
||||||
|
NormalNC { theme.Normal, bg = theme.Normal.bg.abs_da(2) }, -- normal text in non-current windows
|
||||||
|
}
|
||||||
|
end)
|
||||||
|
)
|
||||||
|
end
|
||||||
|
|
||||||
|
if vim.g.zenbones_solid_vert_split then
|
||||||
|
table.insert(
|
||||||
|
specs,
|
||||||
|
lush(function()
|
||||||
|
return {
|
||||||
|
VertSplit { bg = theme.StatusLineNC.bg, fg = theme.LineNr.fg }, -- the column separating vertically split windows
|
||||||
|
}
|
||||||
|
end)
|
||||||
|
)
|
||||||
|
end
|
||||||
|
|
||||||
|
return lush.merge(specs)
|
||||||
|
|
||||||
-- vi:nowrap
|
-- vi:nowrap
|
||||||
|
|||||||
Reference in New Issue
Block a user