mirror of
https://github.com/rose-pine/neovim.git
synced 2025-10-15 12:38:53 +02:00
Update palette (#58)
* chore: format * feat!: use new palette - color "inactive" has been renamed to "muted" - update subtle and muted colors
This commit is contained in:
parent
ed2dd129b6
commit
e0fd291fb0
7 changed files with 35 additions and 51 deletions
|
|
@ -23,16 +23,7 @@ function M.colorscheme()
|
|||
local bg = color.bg and 'guibg=' .. color.bg or 'guibg=NONE'
|
||||
local sp = color.sp and 'guisp=' .. color.sp or ''
|
||||
|
||||
local hl = 'highlight '
|
||||
.. group
|
||||
.. ' '
|
||||
.. style
|
||||
.. ' '
|
||||
.. fg
|
||||
.. ' '
|
||||
.. bg
|
||||
.. ' '
|
||||
.. sp
|
||||
local hl = 'highlight ' .. group .. ' ' .. style .. ' ' .. fg .. ' ' .. bg .. ' ' .. sp
|
||||
|
||||
vim.cmd(hl)
|
||||
if color.link then
|
||||
|
|
@ -49,7 +40,7 @@ end
|
|||
|
||||
function M.set(variant)
|
||||
vim.g.rose_pine_variant = variant
|
||||
vim.cmd([[colorscheme rose-pine]])
|
||||
vim.cmd('colorscheme rose-pine')
|
||||
end
|
||||
|
||||
function M.toggle(variants)
|
||||
|
|
@ -64,9 +55,7 @@ function M.toggle(variants)
|
|||
vim.g.rose_pine_current_variant = index[vim.g.rose_pine_variant] or 0
|
||||
end
|
||||
|
||||
vim.g.rose_pine_current_variant = (
|
||||
vim.g.rose_pine_current_variant % #variants
|
||||
) + 1
|
||||
vim.g.rose_pine_current_variant = (vim.g.rose_pine_current_variant % #variants) + 1
|
||||
|
||||
M.set(variants[vim.g.rose_pine_current_variant])
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue