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
|
|
@ -27,8 +27,8 @@ return {
|
|||
c = { bg = p.base, fg = p.text },
|
||||
},
|
||||
inactive = {
|
||||
a = { bg = p.base, fg = p.inactive, gui = 'bold' },
|
||||
b = { bg = p.base, fg = p.inactive },
|
||||
c = { bg = p.base, fg = p.inactive },
|
||||
a = { bg = p.base, fg = p.muted, gui = 'bold' },
|
||||
b = { bg = p.base, fg = p.muted },
|
||||
c = { bg = p.base, fg = p.muted },
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,19 +1,19 @@
|
|||
local present, galaxyline_colors = pcall(require, "galaxyline.themes.colors")
|
||||
local present, galaxyline_colors = pcall(require, 'galaxyline.themes.colors')
|
||||
if not present then
|
||||
return
|
||||
return
|
||||
end
|
||||
|
||||
local palette = require("rose-pine.palette")
|
||||
local palette = require('rose-pine.palette')
|
||||
|
||||
galaxyline_colors["rose-pine"] = {
|
||||
bg = palette.overlay,
|
||||
fg = palette.text,
|
||||
fg_alt = palette.subtle,
|
||||
yellow = palette.gold,
|
||||
cyan = palette.foam,
|
||||
green = palette.inactive,
|
||||
orange = palette.rose,
|
||||
magenta = palette.iris,
|
||||
blue = palette.foam,
|
||||
red = palette.love,
|
||||
galaxyline_colors['rose-pine'] = {
|
||||
bg = palette.overlay,
|
||||
fg = palette.text,
|
||||
fg_alt = palette.subtle,
|
||||
blue = palette.foam,
|
||||
cyan = palette.foam,
|
||||
green = palette.muted,
|
||||
magenta = palette.iris,
|
||||
orange = palette.rose,
|
||||
red = palette.love,
|
||||
yellow = palette.gold,
|
||||
}
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -3,8 +3,8 @@ local variants = {
|
|||
base = '#191724',
|
||||
surface = '#1f1d2e',
|
||||
overlay = '#26233a',
|
||||
inactive = '#555169',
|
||||
subtle = '#6e6a86',
|
||||
muted = '#6e6a86',
|
||||
subtle = '#908caa',
|
||||
text = '#e0def4',
|
||||
love = '#eb6f92',
|
||||
gold = '#f6c177',
|
||||
|
|
@ -20,8 +20,8 @@ local variants = {
|
|||
base = '#232136',
|
||||
surface = '#2a273f',
|
||||
overlay = '#393552',
|
||||
inactive = '#59546d',
|
||||
subtle = '#817c9c',
|
||||
muted = '#6e6a86',
|
||||
subtle = '#908caa',
|
||||
text = '#e0def4',
|
||||
love = '#eb6f92',
|
||||
gold = '#f6c177',
|
||||
|
|
@ -37,8 +37,8 @@ local variants = {
|
|||
base = '#faf4ed',
|
||||
surface = '#fffaf3',
|
||||
overlay = '#f2e9de',
|
||||
inactive = '#9893a5',
|
||||
subtle = '#6e6a86',
|
||||
muted = '#9893a5',
|
||||
subtle = '#797593',
|
||||
text = '#575279',
|
||||
love = '#b4637a',
|
||||
gold = '#ea9d34',
|
||||
|
|
|
|||
|
|
@ -54,18 +54,18 @@ local theme = {
|
|||
FoldColumn = {},
|
||||
Folded = { fg = p.text, bg = p.surface },
|
||||
IncSearch = { bg = p.highlight_med },
|
||||
LineNr = { fg = p.inactive },
|
||||
LineNr = { fg = p.muted },
|
||||
MatchParen = { fg = p.text, bg = p.highlight_med },
|
||||
ModeMsg = { fg = p.subtle },
|
||||
MoreMsg = { fg = p.iris },
|
||||
NonText = { fg = p.inactive },
|
||||
NonText = { fg = p.muted },
|
||||
Normal = { fg = p.text, bg = maybe_background },
|
||||
NormalNC = { fg = p.text, bg = maybe_inactive_background },
|
||||
NormalFloat = { fg = p.text, bg = maybe_float_background },
|
||||
Pmenu = { fg = p.subtle, bg = maybe_float_background },
|
||||
PmenuSbar = { bg = p.overlay },
|
||||
PmenuSel = { fg = p.text, bg = p.overlay },
|
||||
PmenuThumb = { bg = p.inactive },
|
||||
PmenuThumb = { bg = p.muted },
|
||||
Question = { fg = p.gold },
|
||||
-- QuickFixLine = {},
|
||||
Search = { fg = p.iris, bg = p.highlight_high },
|
||||
|
|
@ -81,7 +81,7 @@ local theme = {
|
|||
-- StatusLineTermNC = {},
|
||||
TabLine = { fg = p.subtle, bg = p.overlay },
|
||||
TabLineFill = { bg = p.surface },
|
||||
TabLineSel = { fg = p.text, bg = p.inactive },
|
||||
TabLineSel = { fg = p.text, bg = p.muted },
|
||||
Title = { fg = p.text },
|
||||
VertSplit = maybe_bold_vert_split,
|
||||
Visual = { bg = p.highlight_med },
|
||||
|
|
@ -317,12 +317,12 @@ local theme = {
|
|||
BufferInactive = { fg = p.subtle },
|
||||
BufferInactiveIndex = { fg = p.subtle },
|
||||
BufferInactiveMod = { fg = p.foam },
|
||||
BufferInactiveSign = { fg = p.inactive },
|
||||
BufferInactiveSign = { fg = p.muted },
|
||||
BufferInactiveTarget = { fg = p.gold },
|
||||
BufferVisible = { fg = p.subtle },
|
||||
BufferVisibleIndex = { fg = p.subtle },
|
||||
BufferVisibleMod = { fg = p.foam },
|
||||
BufferVisibleSign = { fg = p.inactive },
|
||||
BufferVisibleSign = { fg = p.muted },
|
||||
BufferVisibleTarget = { fg = p.gold },
|
||||
|
||||
-- gitsigns.nvim
|
||||
|
|
@ -350,7 +350,7 @@ local theme = {
|
|||
NvimTreeFileNew = { fg = p.foam },
|
||||
NvimTreeFileRenamed = { fg = p.pine },
|
||||
NvimTreeFileStaged = { fg = p.iris },
|
||||
NvimTreeEmptyFolderName = { fg = p.inactive },
|
||||
NvimTreeEmptyFolderName = { fg = p.muted },
|
||||
NvimTreeFolderIcon = { fg = p.subtle },
|
||||
NvimTreeFolderName = { fg = p.foam },
|
||||
NvimTreeImageFile = { fg = p.text },
|
||||
|
|
|
|||
|
|
@ -26,12 +26,7 @@ function util.blend(fg, bg, alpha)
|
|||
return math.floor(math.min(math.max(0, ret), 255) + 0.5)
|
||||
end
|
||||
|
||||
return string.format(
|
||||
'#%02X%02X%02X',
|
||||
blendChannel(1),
|
||||
blendChannel(2),
|
||||
blendChannel(3)
|
||||
)
|
||||
return string.format('#%02X%02X%02X', blendChannel(1), blendChannel(2), blendChannel(3))
|
||||
end
|
||||
|
||||
return util
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue