mirror of
https://github.com/rose-pine/neovim.git
synced 2025-10-15 12:38:53 +02:00
Compare commits
122 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
72a04c4065 |
||
|
|
0e70556c8c |
||
|
|
72befaffea |
||
|
|
f93360149e |
||
|
|
83c66bcadb |
||
|
|
6b9840790c | ||
|
|
d195ed8673 | ||
|
|
a67f5ef34b | ||
|
|
39ec539f83 | ||
|
|
5ccc379822 | ||
|
|
d7dc9cd3f2 | ||
|
|
44739383b9 | ||
|
|
8b216f7252 | ||
|
|
0511701746 | ||
|
|
946de320f4 | ||
|
|
340cf5ed5e | ||
|
|
f01eac6eed | ||
|
|
3d71ab02f2 | ||
|
|
0ca4bfbc6f | ||
|
|
8db1217704 | ||
|
|
2b88dfb054 | ||
|
|
ffd5b69948 | ||
|
|
6b51153905 | ||
|
|
40f03c4df1 | ||
|
|
463742691b | ||
|
|
c306f13158 | ||
|
|
fc418a716f | ||
|
|
36526815ee | ||
|
|
a449bb2599 | ||
|
|
5e7bf83782 | ||
|
|
1ebe0a5171 | ||
|
|
8869e546d4 | ||
|
|
2f44ef189f | ||
|
|
22f873c7db | ||
|
|
33a1ba3126 | ||
|
|
fe9e661cda | ||
|
|
94ffdb7748 | ||
|
|
d97cc7fcd7 | ||
|
|
7f0b8c4c7f | ||
|
|
c14da532fa | ||
|
|
8b1a2e73d2 | ||
|
|
d6112a7c56 | ||
|
|
535240c846 | ||
|
|
f7c01f07ee | ||
|
|
656f360ded | ||
|
|
5929bc8683 | ||
|
|
bf7ceb32fa | ||
|
|
3bbd8a865c | ||
|
|
afb46f9b66 | ||
|
|
f2bf6e8d49 | ||
|
|
2f1733d36f | ||
|
|
c4b55e85fb | ||
|
|
fe5f4e11f7 | ||
|
|
69b3aa9500 | ||
|
|
71852123cc | ||
|
|
6d476a5c64 | ||
|
|
958dce3da9 | ||
|
|
511e82e272 | ||
|
|
f67828be44 | ||
|
|
cbc2064f4c | ||
|
|
c8477ee978 | ||
|
|
8d9c83d145 | ||
|
|
465b7dc623 | ||
|
|
e4c22a9163 | ||
|
|
01dc90af2f | ||
|
|
63f4613365 | ||
|
|
1f22d4e97e | ||
|
|
a959c73910 | ||
|
|
3dbb8a99bd | ||
|
|
e901a53e41 | ||
|
|
c8e97915d1 | ||
|
|
12ace889a0 | ||
|
|
e28cda232b | ||
|
|
ea3f15ca95 | ||
|
|
4372c4eb49 | ||
|
|
95e9767165 | ||
|
|
9d0e1b70d9 | ||
|
|
75d145fa08 | ||
|
|
4452ecd140 | ||
|
|
0b77ef0e7b | ||
|
|
8514c638bc | ||
|
|
e62a61166e | ||
|
|
7ed74e3f24 | ||
|
|
f4d51d67ee | ||
|
|
aa74893a06 | ||
|
|
1ffdf27819 | ||
|
|
e0674e5e5c | ||
|
|
79e0d756b9 | ||
|
|
46044020c6 | ||
|
|
1edcf47562 | ||
|
|
188190f285 | ||
|
|
bfa2d2b2fb | ||
|
|
2c892088f9 | ||
|
|
76b6d830f6 | ||
|
|
82285ba9f1 | ||
|
|
86fa83761e | ||
|
|
29477a109a | ||
|
|
84a88f68e1 | ||
|
|
c48de5d8f8 | ||
|
|
8f37719a51 | ||
|
|
bca840fc90 | ||
|
|
70c641a0b7 | ||
|
|
eb4c5591c7 | ||
|
|
805a183dde | ||
|
|
c552fcadac | ||
|
|
3b3ca9ebb9 | ||
|
|
4e0e82b3af | ||
|
|
838b33cdc4 | ||
|
|
9ecd30d749 | ||
|
|
ab6ab41da0 | ||
|
|
0fb313c3c5 | ||
|
|
eb057bd6dd | ||
|
|
75bb6e5a6d | ||
|
|
89bcc4b197 | ||
|
|
9cb8497413 | ||
|
|
15eeca1d44 | ||
|
|
adc339c315 | ||
|
|
196cb4cb06 | ||
|
|
8b63bcd142 | ||
|
|
3044a86a2c | ||
|
|
88dfcf9e8a | ||
|
|
3eb035f569 |
22 changed files with 1907 additions and 1086 deletions
61
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
61
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
|
|
@ -15,30 +15,14 @@ body:
|
|||
required: true
|
||||
- type: input
|
||||
attributes:
|
||||
label: "Terminal"
|
||||
placeholder: "Kitty"
|
||||
label: "Terminal / multiplexer"
|
||||
placeholder: "Kitty / tmux"
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Describe the bug
|
||||
description: A clear and concise description of what the bug is. Please include any related errors you see in Neovim.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Steps To Reproduce
|
||||
description: Steps to reproduce the behavior.
|
||||
placeholder: |
|
||||
1.
|
||||
2.
|
||||
3.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
attributes:
|
||||
label: Expected Behavior
|
||||
description: A concise description of what you expected to happen.
|
||||
description: A clear and concise description of what the bug is. Please include screenshots if possible and any related errors you see in Neovim.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
|
|
@ -46,36 +30,25 @@ body:
|
|||
label: Repro
|
||||
description: Minimal `init.lua` to reproduce this issue. Save as `repro.lua` and run with `nvim -u repro.lua`
|
||||
value: |
|
||||
-- DO NOT change the paths and do not remove the colorscheme
|
||||
local root = vim.fn.fnamemodify("./.repro", ":p")
|
||||
vim.o.packpath = "/tmp/nvim/site"
|
||||
|
||||
-- Set stdpaths to use .repro
|
||||
for _, name in ipairs({ "config", "data", "state", "cache" }) do
|
||||
vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
|
||||
end
|
||||
|
||||
-- Bootstrap lazy.nvim
|
||||
local lazypath = root .. "/plugins/lazy.nvim"
|
||||
if not vim.loop.fs_stat(lazypath) then
|
||||
vim.fn.system({ "git", "clone", "--filter=blob:none", "https://github.com/folke/lazy.nvim.git", lazypath, })
|
||||
end
|
||||
vim.opt.runtimepath:prepend(lazypath)
|
||||
|
||||
-- Install plugins
|
||||
local plugins = {
|
||||
"rose-pine/neovim",
|
||||
name = "rose-pine",
|
||||
config = function()
|
||||
-- Add relevant Rosé Pine config below
|
||||
require("rose-pine").setup({})
|
||||
end
|
||||
rose_pine = "https://github.com/rose-pine/neovim",
|
||||
-- ADD OTHER PLUGINS _NECESSARY_ TO REPRODUCE THE ISSUE
|
||||
}
|
||||
require("lazy").setup(plugins, {
|
||||
root = root .. "/plugins",
|
||||
|
||||
for name, url in pairs(plugins) do
|
||||
local install_path = "/tmp/nvim/site/pack/test/start/" .. name
|
||||
if vim.fn.isdirectory(install_path) == 0 then
|
||||
vim.fn.system({ "git", "clone", "--depth=1", url, install_path })
|
||||
end
|
||||
end
|
||||
|
||||
require("rose-pine").setup({
|
||||
-- ADD ROSÉ PINE CONFIG THAT IS _NECESSARY_ TO REPRODUCE THE ISSUE
|
||||
})
|
||||
|
||||
vim.cmd.colorscheme("rose-pine")
|
||||
-- Add anything else here
|
||||
vim.cmd("colorscheme rose-pine")
|
||||
render: Lua
|
||||
validations:
|
||||
required: false
|
||||
|
|
|
|||
12
.github/ISSUE_TEMPLATE/feature_request.yml
vendored
12
.github/ISSUE_TEMPLATE/feature_request.yml
vendored
|
|
@ -3,24 +3,12 @@ description: Suggest a new feature
|
|||
title: "feature: "
|
||||
labels: [enhancement]
|
||||
body:
|
||||
- type: textarea
|
||||
validations:
|
||||
required: true
|
||||
attributes:
|
||||
label: Is your feature request related to a problem? Please describe.
|
||||
description: A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||
- type: textarea
|
||||
validations:
|
||||
required: true
|
||||
attributes:
|
||||
label: Describe the solution you'd like
|
||||
description: A clear and concise description of what you want to happen.
|
||||
- type: textarea
|
||||
validations:
|
||||
required: true
|
||||
attributes:
|
||||
label: Describe alternatives you've considered
|
||||
description: A clear and concise description of any alternative solutions or features you've considered.
|
||||
- type: textarea
|
||||
validations:
|
||||
required: false
|
||||
|
|
|
|||
|
|
@ -1,4 +0,0 @@
|
|||
column_width = 80
|
||||
indent_type = "Tabs"
|
||||
line_endings = "Unix"
|
||||
quote_style = "AutoPreferSingle"
|
||||
82
changelog.md
Normal file
82
changelog.md
Normal file
|
|
@ -0,0 +1,82 @@
|
|||
# Changelog
|
||||
|
||||
## v2.0.0-next.1
|
||||
|
||||
### What's new
|
||||
|
||||
- Add proper support for `StatusLineTerm` & `StatusLineTermNC`, controlled via `enable.terminal`
|
||||
- Add background glow to diagnostic virtual text
|
||||
- Add `extend_background_behind_borders`
|
||||
- Add `styles.bold` and alternatively styling when disabled
|
||||
- Add `before_highlight` hook to allow changing palette values and behaviours
|
||||
- Increase contrast of search, visual selections, and more
|
||||
|
||||
### Features
|
||||
|
||||
**extend_background_behind_borders**
|
||||
|
||||
Extend float backgrounds behind borders. Results vary depending on your border characters.
|
||||
|
||||
```lua
|
||||
{
|
||||
extend_background_behind_borders = true
|
||||
}
|
||||
```
|
||||
|
||||
**styles.transparency**
|
||||
|
||||
Enable a unique experience focused around transparent terminals, avoiding large backgrounds and differentiating selections with foreground colours when possible.
|
||||
|
||||
```lua
|
||||
{
|
||||
styles = {
|
||||
transparency = true
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
**before_highlight**
|
||||
|
||||
```lua
|
||||
{
|
||||
before_highlight = function(group, highlight, palette)
|
||||
-- Disable all undercurls
|
||||
if highlight.undercurl then
|
||||
highlight.undercurl = false
|
||||
end
|
||||
|
||||
-- Change palette colour
|
||||
if highlight.fg == palette.pine then
|
||||
highlight.fg = palette.foam
|
||||
end
|
||||
end,
|
||||
}
|
||||
```
|
||||
|
||||
### Breaking changes
|
||||
|
||||
> [!WARNING]
|
||||
> Removed or renamed options should continue to work via internal migrations but backwards compatibility is not tested and may break at any time.
|
||||
|
||||
```diff
|
||||
- dim_nc_background = true,
|
||||
+ dim_inactive_windows = true,
|
||||
|
||||
- disable_background = true,
|
||||
- disable_float_background = true,
|
||||
+ styles.transparency = true
|
||||
|
||||
- disable_italics = true,
|
||||
+ styles.italic = false,
|
||||
|
||||
- groups = {
|
||||
- background = "...",
|
||||
- comment = "...",
|
||||
- punctuation = "...",
|
||||
- },
|
||||
+ highlight_groups = {
|
||||
+ Normal = { bg = "..." },
|
||||
+ Comment = { fg = "..." },
|
||||
+ ["@punctuation"] = { fg = "..." },
|
||||
+ }
|
||||
```
|
||||
|
|
@ -1 +1,2 @@
|
|||
require('rose-pine').colorscheme({ variant = 'dawn' })
|
||||
package.loaded["rose-pine.palette"] = nil
|
||||
require("rose-pine").colorscheme("dawn")
|
||||
|
|
|
|||
|
|
@ -1 +1,2 @@
|
|||
require('rose-pine').colorscheme({ variant = 'main' })
|
||||
package.loaded["rose-pine.palette"] = nil
|
||||
require("rose-pine").colorscheme("main")
|
||||
|
|
|
|||
|
|
@ -1 +1,2 @@
|
|||
require('rose-pine').colorscheme({ variant = 'moon' })
|
||||
package.loaded["rose-pine.palette"] = nil
|
||||
require("rose-pine").colorscheme("moon")
|
||||
|
|
|
|||
|
|
@ -1,3 +1,2 @@
|
|||
package.loaded['rose-pine.palette'] = nil
|
||||
|
||||
require('rose-pine').colorscheme()
|
||||
package.loaded["rose-pine.palette"] = nil
|
||||
require("rose-pine").colorscheme()
|
||||
|
|
|
|||
|
|
@ -1,26 +1,32 @@
|
|||
local p = require('rose-pine.palette')
|
||||
local p = require("rose-pine.palette")
|
||||
local config = require("rose-pine.config")
|
||||
|
||||
local bg_base = p.base
|
||||
if config.options.styles.transparency then
|
||||
bg_base = "NONE"
|
||||
end
|
||||
|
||||
return {
|
||||
normal = {
|
||||
a = { bg = p.surface, fg = p.rose, gui = 'bold' },
|
||||
a = { bg = p.surface, fg = p.rose, gui = "bold" },
|
||||
b = { bg = p.surface, fg = p.text },
|
||||
c = { bg = p.surface, fg = p.subtle, gui = 'italic' },
|
||||
c = { bg = p.surface, fg = p.subtle, gui = "italic" },
|
||||
},
|
||||
insert = {
|
||||
a = { bg = p.surface, fg = p.foam, gui = 'bold' },
|
||||
a = { bg = p.surface, fg = p.foam, gui = "bold" },
|
||||
},
|
||||
visual = {
|
||||
a = { bg = p.surface, fg = p.iris, gui = 'bold' },
|
||||
a = { bg = p.surface, fg = p.iris, gui = "bold" },
|
||||
},
|
||||
replace = {
|
||||
a = { bg = p.surface, fg = p.pine, gui = 'bold' },
|
||||
a = { bg = p.surface, fg = p.pine, gui = "bold" },
|
||||
},
|
||||
command = {
|
||||
a = { bg = p.surface, fg = p.love, gui = 'bold' },
|
||||
a = { bg = p.surface, fg = p.love, gui = "bold" },
|
||||
},
|
||||
inactive = {
|
||||
a = { bg = p.base, fg = p.subtle, gui = 'bold' },
|
||||
b = { bg = p.base, fg = p.subtle },
|
||||
c = { bg = p.base, fg = p.subtle, gui = 'italic' },
|
||||
a = { bg = bg_base, fg = p.subtle, gui = "bold" },
|
||||
b = { bg = bg_base, fg = p.subtle },
|
||||
c = { bg = bg_base, fg = p.subtle, gui = "italic" },
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,34 +1,40 @@
|
|||
local p = require('rose-pine.palette')
|
||||
local p = require("rose-pine.palette")
|
||||
local config = require("rose-pine.config")
|
||||
|
||||
local bg_base = p.surface
|
||||
if config.options.styles.transparency then
|
||||
bg_base = "NONE"
|
||||
end
|
||||
|
||||
return {
|
||||
normal = {
|
||||
a = { bg = p.rose, fg = p.base, gui = 'bold' },
|
||||
a = { bg = p.rose, fg = p.base, gui = "bold" },
|
||||
b = { bg = p.overlay, fg = p.rose },
|
||||
c = { bg = p.base, fg = p.text },
|
||||
c = { bg = bg_base, fg = p.text },
|
||||
},
|
||||
insert = {
|
||||
a = { bg = p.foam, fg = p.base, gui = 'bold' },
|
||||
a = { bg = p.foam, fg = p.base, gui = "bold" },
|
||||
b = { bg = p.overlay, fg = p.foam },
|
||||
c = { bg = p.base, fg = p.text },
|
||||
c = { bg = bg_base, fg = p.text },
|
||||
},
|
||||
visual = {
|
||||
a = { bg = p.iris, fg = p.base, gui = 'bold' },
|
||||
a = { bg = p.iris, fg = p.base, gui = "bold" },
|
||||
b = { bg = p.overlay, fg = p.iris },
|
||||
c = { bg = p.base, fg = p.text },
|
||||
c = { bg = bg_base, fg = p.text },
|
||||
},
|
||||
replace = {
|
||||
a = { bg = p.pine, fg = p.base, gui = 'bold' },
|
||||
a = { bg = p.pine, fg = p.base, gui = "bold" },
|
||||
b = { bg = p.overlay, fg = p.pine },
|
||||
c = { bg = p.base, fg = p.text },
|
||||
c = { bg = bg_base, fg = p.text },
|
||||
},
|
||||
command = {
|
||||
a = { bg = p.love, fg = p.base, gui = 'bold' },
|
||||
a = { bg = p.love, fg = p.base, gui = "bold" },
|
||||
b = { bg = p.overlay, fg = p.love },
|
||||
c = { bg = p.base, fg = p.text },
|
||||
c = { bg = bg_base, fg = p.text },
|
||||
},
|
||||
inactive = {
|
||||
a = { bg = p.base, fg = p.muted, gui = 'bold' },
|
||||
b = { bg = p.base, fg = p.muted },
|
||||
c = { bg = p.base, fg = p.muted },
|
||||
a = { bg = bg_base, fg = p.muted, gui = "bold" },
|
||||
b = { bg = bg_base, fg = p.muted },
|
||||
c = { bg = bg_base, fg = p.muted },
|
||||
},
|
||||
}
|
||||
|
|
|
|||
1242
lua/rose-pine.lua
1242
lua/rose-pine.lua
File diff suppressed because it is too large
Load diff
|
|
@ -1,104 +1,176 @@
|
|||
local M = {}
|
||||
---@alias Variant "main" | "moon" | "dawn"
|
||||
---@alias Palette { base: string, surface: string, overlay: string, muted: string, subtle: string, text: string, love: string, gold: string, rose: string, pine: string, foam: string, iris: string }
|
||||
---@alias PaletteColor "base" | "surface" | "overlay" | "muted" | "subtle" | "text" | "love" | "gold" | "rose" | "pine" | "foam" | "iris" | "highlight_low" | "highlight_med" | "highlight_high"
|
||||
---@alias Highlight { link: string, inherit: boolean } | { fg: string, bg: string, sp: string, bold: boolean, italic: boolean, undercurl: boolean, underline: boolean, underdouble: boolean, underdotted: boolean, underdashed: boolean, strikethrough: boolean, inherit: boolean }
|
||||
|
||||
---@class Groups
|
||||
---@field background string
|
||||
---@field background_nc string
|
||||
---@field panel string
|
||||
---@field panel_nc string
|
||||
---@field border string
|
||||
---@field comment string
|
||||
---@field link string
|
||||
---@field punctuation string
|
||||
---@field error string
|
||||
---@field hint string
|
||||
---@field info string
|
||||
---@field warn string
|
||||
---@field git_add string
|
||||
---@field git_change string
|
||||
---@field git_delete string
|
||||
---@field git_dirty string
|
||||
---@field git_ignore string
|
||||
---@field git_merge string
|
||||
---@field git_rename string
|
||||
---@field git_stage string
|
||||
---@field git_text string
|
||||
---@field headings Headings|string
|
||||
local config = {}
|
||||
|
||||
---@class Headings
|
||||
---@field h1 string
|
||||
---@field h2 string
|
||||
---@field h3 string
|
||||
---@field h4 string
|
||||
---@field h5 string
|
||||
---@field h6 string
|
||||
---@class Options
|
||||
config.options = {
|
||||
---Set the desired variant: "auto" will follow the vim background,
|
||||
---defaulting to `dark_variant` or "main" for dark and "dawn" for light.
|
||||
---@type "auto" | Variant
|
||||
variant = "auto",
|
||||
|
||||
---@class Config
|
||||
---@field variant 'auto'|'main'|'moon'|'dawn'
|
||||
---@field dark_variant 'main'|'moon'|'dawn'
|
||||
---@field bold_vert_split boolean
|
||||
---@field dim_nc_background boolean
|
||||
---@field disable_background boolean
|
||||
---@field disable_float_background boolean
|
||||
---@field disable_italics boolean
|
||||
---@field groups Groups
|
||||
---@field highlight_groups table<string, any>
|
||||
local defaults = {
|
||||
variant = 'auto',
|
||||
dark_variant = 'main',
|
||||
bold_vert_split = false,
|
||||
dim_nc_background = false,
|
||||
disable_background = false,
|
||||
disable_float_background = false,
|
||||
disable_italics = false,
|
||||
---Set the desired dark variant when `options.variant` is set to "auto".
|
||||
---@type Variant
|
||||
dark_variant = "main",
|
||||
|
||||
---Differentiate between active and inactive windows and panels.
|
||||
dim_inactive_windows = false,
|
||||
|
||||
---Extend background behind borders. Appearance differs based on which
|
||||
---border characters you are using.
|
||||
extend_background_behind_borders = true,
|
||||
|
||||
enable = {
|
||||
legacy_highlights = true,
|
||||
migrations = true,
|
||||
terminal = true,
|
||||
},
|
||||
|
||||
styles = {
|
||||
bold = true,
|
||||
italic = true,
|
||||
transparency = false,
|
||||
},
|
||||
|
||||
---@type table<string, table<string, string>>
|
||||
palette = {},
|
||||
|
||||
---@type table<string, string | PaletteColor>
|
||||
groups = {
|
||||
border = "muted",
|
||||
link = "iris",
|
||||
panel = "surface",
|
||||
|
||||
error = "love",
|
||||
hint = "iris",
|
||||
info = "foam",
|
||||
ok = "leaf",
|
||||
warn = "gold",
|
||||
note = "pine",
|
||||
todo = "rose",
|
||||
|
||||
git_add = "foam",
|
||||
git_change = "rose",
|
||||
git_delete = "love",
|
||||
git_dirty = "rose",
|
||||
git_ignore = "muted",
|
||||
git_merge = "iris",
|
||||
git_rename = "pine",
|
||||
git_stage = "iris",
|
||||
git_text = "rose",
|
||||
git_untracked = "subtle",
|
||||
|
||||
---@type string | PaletteColor
|
||||
h1 = "iris",
|
||||
h2 = "foam",
|
||||
h3 = "rose",
|
||||
h4 = "gold",
|
||||
h5 = "pine",
|
||||
h6 = "leaf",
|
||||
|
||||
---@deprecated Replaced by `options.highlight_groups["Normal"]`
|
||||
-- background = "base",
|
||||
---@deprecated Replaced by `options.highlight_groups["Comment"]`
|
||||
-- comment = "subtle",
|
||||
---@deprecated Replaced by `options.highlight_groups["@punctuation"]`
|
||||
-- punctuation = "muted",
|
||||
---@deprecated Expects a table with values h1...h6
|
||||
-- headings = "text",
|
||||
},
|
||||
|
||||
---@type table<string, Highlight>
|
||||
highlight_groups = {},
|
||||
|
||||
groups = {
|
||||
background = 'base',
|
||||
background_nc = '_experimental_nc',
|
||||
panel = 'surface',
|
||||
panel_nc = 'base',
|
||||
border = 'highlight_med',
|
||||
comment = 'muted',
|
||||
link = 'iris',
|
||||
punctuation = 'muted',
|
||||
error = 'love',
|
||||
hint = 'iris',
|
||||
info = 'foam',
|
||||
warn = 'gold',
|
||||
git_add = 'foam',
|
||||
git_change = 'rose',
|
||||
git_delete = 'love',
|
||||
git_dirty = 'rose',
|
||||
git_ignore = 'muted',
|
||||
git_merge = 'iris',
|
||||
git_rename = 'pine',
|
||||
git_stage = 'iris',
|
||||
git_text = 'rose',
|
||||
headings = {
|
||||
h1 = 'iris',
|
||||
h2 = 'foam',
|
||||
h3 = 'rose',
|
||||
h4 = 'gold',
|
||||
h5 = 'pine',
|
||||
h6 = 'foam',
|
||||
},
|
||||
},
|
||||
---Called before each highlight group, before setting the highlight.
|
||||
---@param group string
|
||||
---@param highlight Highlight
|
||||
---@param palette Palette
|
||||
---@diagnostic disable-next-line: unused-local
|
||||
before_highlight = function(group, highlight, palette) end,
|
||||
|
||||
---@deprecated Replaced by `options.dim_inactive_windows`
|
||||
-- dim_nc_background = false,
|
||||
---@deprecated Replaced by `options.enable.transparency`
|
||||
-- disable_background = false,
|
||||
---@deprecated Replaced by `options.highlight_groups["NormalFloat"]`
|
||||
-- disable_float_background = false,
|
||||
---@deprecated Replaced by `options.styles.italic`
|
||||
-- disable_italics = false,
|
||||
---@deprecated Replaced by `options.highlight_groups`
|
||||
-- bold_vert_split = false
|
||||
}
|
||||
|
||||
---@type Config
|
||||
M.options = {}
|
||||
local function migrate(options)
|
||||
if options.bold_vert_split then
|
||||
local border = options.groups.border or "muted"
|
||||
options.highlight_groups["VertSplit"] = { fg = border, bg = border }
|
||||
options.highlight_groups["WinSeparator"] = { fg = border, bg = border }
|
||||
end
|
||||
|
||||
---@param options Config|nil
|
||||
function M.setup(options)
|
||||
M.options = vim.tbl_deep_extend('force', {}, defaults, options or {})
|
||||
if options.disable_background then
|
||||
options.highlight_groups["Normal"] = { bg = "NONE" }
|
||||
end
|
||||
|
||||
if options.disable_float_background then
|
||||
options.highlight_groups["NormalFloat"] = { bg = "NONE" }
|
||||
end
|
||||
|
||||
options.dim_inactive_windows = options.dim_nc_background or options.dim_inactive_windows
|
||||
|
||||
if options.groups.background ~= nil then
|
||||
options.highlight_groups["Normal"] = { bg = options.groups.background }
|
||||
end
|
||||
|
||||
if options.groups.comment ~= nil then
|
||||
options.highlight_groups["Comment"] = { fg = options.groups.comment }
|
||||
end
|
||||
|
||||
if options.groups.punctuation ~= nil then
|
||||
options.highlight_groups["@punctuation"] = { fg = options.groups.punctuation }
|
||||
end
|
||||
|
||||
options.styles.transparency = (options.disable_background and options.disable_float_background)
|
||||
or options.styles.transparency
|
||||
|
||||
-- These never actually existed, but may be set intuitively by the user
|
||||
-- because of `disable_italics` existing.
|
||||
options.styles.bold = not (options.disable_bold or options.disable_bolds) and options.styles.bold or false
|
||||
|
||||
-- Similar to bold options, `disable_italic` never existed but could be a
|
||||
-- common typo of the actual `disable_italics`.
|
||||
options.styles.italic = not (options.disable_italic or options.disable_italics) and options.styles.italic or false
|
||||
|
||||
-- Set h1 through h6 to the same color if only one is specified
|
||||
if type(options.groups.headings) == "string" then
|
||||
options.groups.h1 = options.groups.headings
|
||||
options.groups.h2 = options.groups.headings
|
||||
options.groups.h3 = options.groups.headings
|
||||
options.groups.h4 = options.groups.headings
|
||||
options.groups.h5 = options.groups.headings
|
||||
options.groups.h6 = options.groups.headings
|
||||
elseif options.groups.headings == "table" then
|
||||
options.groups.h1 = options.groups.headings.h1 or options.groups.h1
|
||||
options.groups.h2 = options.groups.headings.h2 or options.groups.h2
|
||||
options.groups.h3 = options.groups.headings.h3 or options.groups.h3
|
||||
options.groups.h4 = options.groups.headings.h4 or options.groups.h4
|
||||
options.groups.h5 = options.groups.headings.h5 or options.groups.h5
|
||||
options.groups.h6 = options.groups.headings.h6 or options.groups.h6
|
||||
end
|
||||
options.groups.headings = nil
|
||||
|
||||
return options
|
||||
end
|
||||
|
||||
---@param options Config|nil
|
||||
function M.extend(options)
|
||||
M.options =
|
||||
vim.tbl_deep_extend('force', {}, M.options or defaults, options or {})
|
||||
---@param options Options | nil
|
||||
function config.extend_options(options)
|
||||
config.options = vim.tbl_deep_extend("force", config.options, options or {})
|
||||
|
||||
if config.options.enable.migrations then
|
||||
config.options = migrate(config.options)
|
||||
end
|
||||
end
|
||||
|
||||
M.setup()
|
||||
|
||||
return M
|
||||
return config
|
||||
|
|
|
|||
|
|
@ -1,80 +1,78 @@
|
|||
local options = require('rose-pine.config').options
|
||||
|
||||
local options = require("rose-pine.config").options
|
||||
local variants = {
|
||||
main = {
|
||||
---@deprecated for backwards compatibility
|
||||
_experimental_nc = '#16141f',
|
||||
nc = '#16141f',
|
||||
base = '#191724',
|
||||
surface = '#1f1d2e',
|
||||
overlay = '#26233a',
|
||||
muted = '#6e6a86',
|
||||
subtle = '#908caa',
|
||||
text = '#e0def4',
|
||||
love = '#eb6f92',
|
||||
gold = '#f6c177',
|
||||
rose = '#ebbcba',
|
||||
pine = '#31748f',
|
||||
foam = '#9ccfd8',
|
||||
iris = '#c4a7e7',
|
||||
highlight_low = '#21202e',
|
||||
highlight_med = '#403d52',
|
||||
highlight_high = '#524f67',
|
||||
none = 'NONE',
|
||||
_nc = "#16141f",
|
||||
base = "#191724",
|
||||
surface = "#1f1d2e",
|
||||
overlay = "#26233a",
|
||||
muted = "#6e6a86",
|
||||
subtle = "#908caa",
|
||||
text = "#e0def4",
|
||||
love = "#eb6f92",
|
||||
gold = "#f6c177",
|
||||
rose = "#ebbcba",
|
||||
pine = "#31748f",
|
||||
foam = "#9ccfd8",
|
||||
iris = "#c4a7e7",
|
||||
leaf = "#95b1ac",
|
||||
highlight_low = "#21202e",
|
||||
highlight_med = "#403d52",
|
||||
highlight_high = "#524f67",
|
||||
none = "NONE",
|
||||
},
|
||||
moon = {
|
||||
---@deprecated for backwards compatibility
|
||||
_experimental_nc = '#1f1d30',
|
||||
nc = '#1f1d30',
|
||||
base = '#232136',
|
||||
surface = '#2a273f',
|
||||
overlay = '#393552',
|
||||
muted = '#6e6a86',
|
||||
subtle = '#908caa',
|
||||
text = '#e0def4',
|
||||
love = '#eb6f92',
|
||||
gold = '#f6c177',
|
||||
rose = '#ea9a97',
|
||||
pine = '#3e8fb0',
|
||||
foam = '#9ccfd8',
|
||||
iris = '#c4a7e7',
|
||||
highlight_low = '#2a283e',
|
||||
highlight_med = '#44415a',
|
||||
highlight_high = '#56526e',
|
||||
none = 'NONE',
|
||||
_nc = "#1f1d30",
|
||||
base = "#232136",
|
||||
surface = "#2a273f",
|
||||
overlay = "#393552",
|
||||
muted = "#6e6a86",
|
||||
subtle = "#908caa",
|
||||
text = "#e0def4",
|
||||
love = "#eb6f92",
|
||||
gold = "#f6c177",
|
||||
rose = "#ea9a97",
|
||||
pine = "#3e8fb0",
|
||||
foam = "#9ccfd8",
|
||||
iris = "#c4a7e7",
|
||||
leaf = "#95b1ac",
|
||||
highlight_low = "#2a283e",
|
||||
highlight_med = "#44415a",
|
||||
highlight_high = "#56526e",
|
||||
none = "NONE",
|
||||
},
|
||||
dawn = {
|
||||
---@deprecated for backwards compatibility
|
||||
_experimental_nc = '#f8f0e7',
|
||||
nc = '#f8f0e7',
|
||||
base = '#faf4ed',
|
||||
surface = '#fffaf3',
|
||||
overlay = '#f2e9e1',
|
||||
muted = '#9893a5',
|
||||
subtle = '#797593',
|
||||
text = '#575279',
|
||||
love = '#b4637a',
|
||||
gold = '#ea9d34',
|
||||
rose = '#d7827e',
|
||||
pine = '#286983',
|
||||
foam = '#56949f',
|
||||
iris = '#907aa9',
|
||||
highlight_low = '#f4ede8',
|
||||
highlight_med = '#dfdad9',
|
||||
highlight_high = '#cecacd',
|
||||
none = 'NONE',
|
||||
_nc = "#f8f0e7",
|
||||
base = "#faf4ed",
|
||||
surface = "#fffaf3",
|
||||
overlay = "#f2e9e1",
|
||||
muted = "#9893a5",
|
||||
subtle = "#797593",
|
||||
text = "#464261",
|
||||
love = "#b4637a",
|
||||
gold = "#ea9d34",
|
||||
rose = "#d7827e",
|
||||
pine = "#286983",
|
||||
foam = "#56949f",
|
||||
iris = "#907aa9",
|
||||
leaf = "#6d8f89",
|
||||
highlight_low = "#f4ede8",
|
||||
highlight_med = "#dfdad9",
|
||||
highlight_high = "#cecacd",
|
||||
none = "NONE",
|
||||
},
|
||||
}
|
||||
|
||||
if options.variant == 'main' then
|
||||
return variants.main
|
||||
end
|
||||
if options.variant == 'moon' then
|
||||
return variants.moon
|
||||
end
|
||||
if options.variant == 'dawn' then
|
||||
return variants.dawn
|
||||
if options.palette ~= nil and next(options.palette) then
|
||||
-- handle variant specific overrides
|
||||
for variant_name, override_palette in pairs(options.palette) do
|
||||
if variants[variant_name] then
|
||||
variants[variant_name] = vim.tbl_extend("force", variants[variant_name], override_palette or {})
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
return vim.o.background == 'light' and variants.dawn
|
||||
or variants[options.dark_variant or 'main']
|
||||
if variants[options.variant] ~= nil then
|
||||
return variants[options.variant]
|
||||
end
|
||||
|
||||
return vim.o.background == "light" and variants.dawn or variants[options.dark_variant or "main"]
|
||||
|
|
|
|||
|
|
@ -2,43 +2,43 @@
|
|||
--- https://github.com/akinsho/bufferline.nvim
|
||||
---
|
||||
--- @usage
|
||||
--- local highlights = require('rose-pine.plugins.bufferline')
|
||||
--- require('bufferline').setup({ highlights = highlights })
|
||||
--- local highlights = require("rose-pine.plugins.bufferline")
|
||||
--- require("bufferline").setup({ highlights = highlights })
|
||||
|
||||
local p = require('rose-pine.palette')
|
||||
local p = require("rose-pine.palette")
|
||||
|
||||
return {
|
||||
-- fill = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- background = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- tab = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- },
|
||||
-- tab_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
tab_selected = {
|
||||
fg = p.text,
|
||||
bg = p.overlay,
|
||||
},
|
||||
-- tab_close = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- close_button = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- close_button_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- close_button_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
buffer_visible = {
|
||||
fg = p.subtle,
|
||||
|
|
@ -51,172 +51,172 @@ return {
|
|||
italic = true,
|
||||
},
|
||||
-- diagnostic = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- diagnostic_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- diagnostic_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- },
|
||||
-- info = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- sp = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- sp = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- info_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- info_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- sp = '<color-value-here>',
|
||||
-- sp = "<color-value-here>",
|
||||
-- },
|
||||
-- info_diagnostic = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- sp = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- sp = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- info_diagnostic_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- info_diagnostic_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- sp = '<color-value-here>',
|
||||
-- sp = "<color-value-here>",
|
||||
-- },
|
||||
-- warning = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- sp = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- sp = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- warning_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- warning_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- sp = '<color-value-here>',
|
||||
-- sp = "<color-value-here>",
|
||||
-- },
|
||||
-- warning_diagnostic = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- sp = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- sp = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- warning_diagnostic_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- warning_diagnostic_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- sp = warning_diagnostic_fg,
|
||||
-- },
|
||||
-- error = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- sp = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- sp = "<color-value-here>",
|
||||
-- },
|
||||
-- error_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- error_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- sp = '<color-value-here>',
|
||||
-- sp = "<color-value-here>",
|
||||
-- },
|
||||
-- error_diagnostic = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- sp = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- sp = "<color-value-here>",
|
||||
-- },
|
||||
-- error_diagnostic_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- error_diagnostic_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- sp = '<color-value-here>',
|
||||
-- sp = "<color-value-here>",
|
||||
-- },
|
||||
-- modified = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- modified_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- modified_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- duplicate_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- italic = true,
|
||||
-- bg = '<color-value-here>',
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- duplicate_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- italic = true,
|
||||
-- bg = '<color-value-here>',
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- duplicate = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- italic = true,
|
||||
-- bg = '<color-value-here>',
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- separator_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- separator_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- separator = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- indicator_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- },
|
||||
-- pick_selected = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- italic = true,
|
||||
-- },
|
||||
-- pick_visible = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- },
|
||||
-- pick = {
|
||||
-- fg = '<color-value-here>',
|
||||
-- bg = '<color-value-here>',
|
||||
-- fg = "<color-value-here>",
|
||||
-- bg = "<color-value-here>",
|
||||
-- bold = true,
|
||||
-- italic = true,
|
||||
-- },
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
--- https://github.com/NTBBloodbath/galaxyline.nvim
|
||||
---
|
||||
--- @usage
|
||||
--- local highlights = require('rose-pine.plugins.galaxyline')
|
||||
--- local highlights = require("rose-pine.plugins.galaxyline")
|
||||
|
||||
local p = require('rose-pine.palette')
|
||||
local p = require("rose-pine.palette")
|
||||
|
||||
return {
|
||||
bg = p.surface,
|
||||
|
|
|
|||
|
|
@ -2,9 +2,9 @@
|
|||
--- https://github.com/David-Kunz/markid
|
||||
---
|
||||
--- @usage
|
||||
--- local highlights = require('rose-pine.plugins.markid')
|
||||
--- local highlights = require("rose-pine.plugins.markid")
|
||||
--- require("nvim-treesitter.configs").setup({ markid = { enable = true, colors = highlights } })
|
||||
|
||||
local p = require('rose-pine.palette')
|
||||
local p = require("rose-pine.palette")
|
||||
|
||||
return { p.foam, p.rose, p.iris }
|
||||
|
|
|
|||
14
lua/rose-pine/plugins/obsidian.lua
Normal file
14
lua/rose-pine/plugins/obsidian.lua
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
--- Rosé Pine for Obsidian(epwalsh)
|
||||
--- https://github.com/epwalsh/obsidian.nvim
|
||||
---
|
||||
--- @usage
|
||||
--- local highlights = require("rose-pine.plugins.obsidian")
|
||||
--- require("obsidian").setup({ ui = {hl_groups = highlights} })
|
||||
|
||||
local p = require("rose-pine.palette")
|
||||
|
||||
return {
|
||||
ObsidianBullet = { fg = p.muted },
|
||||
ObsidianRefText = { underline = true, fg = p.iris },
|
||||
ObsidianDone = { bold = true, fg = p.foam }
|
||||
}
|
||||
|
|
@ -2,14 +2,14 @@
|
|||
--- https://github.com/akinsho/toggleterm.nvim
|
||||
---
|
||||
--- @usage
|
||||
--- local highlights = require('rose-pine.plugins.toggleterm')
|
||||
--- require('toggleterm').setup({ highlights = highlights })
|
||||
--- local highlights = require("rose-pine.plugins.toggleterm")
|
||||
--- require("toggleterm").setup({ highlights = highlights })
|
||||
|
||||
return {
|
||||
Normal = { link = 'Normal' },
|
||||
NormalFloat = { link = 'Normal' },
|
||||
FloatBorder = { link = 'FloatBorder' },
|
||||
SignColumn = { link = 'SignColumn' },
|
||||
StatusLine = { link = 'StatusLine' },
|
||||
StatusLineNC = { link = 'StatusLineNC' },
|
||||
Normal = { link = "Normal" },
|
||||
NormalFloat = { link = "Normal" },
|
||||
FloatBorder = { link = "FloatBorder" },
|
||||
SignColumn = { link = "SignColumn" },
|
||||
StatusLine = { link = "StatusLine" },
|
||||
StatusLineNC = { link = "StatusLineNC" },
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,574 +0,0 @@
|
|||
local M = {}
|
||||
|
||||
---@param options Config
|
||||
function M._load(options)
|
||||
local h = require('rose-pine.util').highlight
|
||||
local p = require('rose-pine.palette')
|
||||
|
||||
local groups = options.groups or {}
|
||||
local maybe = {
|
||||
base = (options.disable_background and p.none) or groups.background,
|
||||
surface = (options.disable_float_background and p.none) or groups.panel,
|
||||
italic = not options.disable_italics,
|
||||
}
|
||||
maybe.bold_vert_split = (options.bold_vert_split and groups.border)
|
||||
or p.none
|
||||
maybe.dim_nc_background = (
|
||||
options.dim_nc_background and groups.background_nc
|
||||
) or maybe.base
|
||||
|
||||
h('ColorColumn', { bg = p.overlay })
|
||||
h('Conceal', { bg = p.none })
|
||||
h('CurSearch', { link = 'IncSearch' })
|
||||
h('Cursor', { fg = p.text, bg = p.highlight_high })
|
||||
h('CursorColumn', { bg = p.highlight_low })
|
||||
-- CursorIM = {},
|
||||
h('CursorLine', { bg = p.highlight_low })
|
||||
h('CursorLineNr', { fg = p.text })
|
||||
h('DarkenedPanel', { bg = maybe.surface })
|
||||
h('DarkenedStatusline', { bg = maybe.surface })
|
||||
h('DiffAdd', { bg = groups.git_add, blend = 20 })
|
||||
|
||||
h('DiffChange', { bg = p.overlay })
|
||||
h('DiffDelete', { bg = groups.git_delete, blend = 20 })
|
||||
h('DiffText', { bg = groups.git_text, blend = 20 })
|
||||
h('diffAdded', { link = 'DiffAdd' })
|
||||
h('diffChanged', { link = 'DiffChange' })
|
||||
h('diffRemoved', { link = 'DiffDelete' })
|
||||
h('Directory', { fg = p.foam, bg = p.none })
|
||||
-- EndOfBuffer = {},
|
||||
h('ErrorMsg', { fg = p.love, bold = true })
|
||||
h('FloatBorder', { fg = groups.border, bg = maybe.surface })
|
||||
h('FloatTitle', { fg = p.muted })
|
||||
h('FoldColumn', { fg = p.muted })
|
||||
h('Folded', { fg = p.text, bg = maybe.surface })
|
||||
h('IncSearch', { fg = groups.background, bg = p.rose })
|
||||
h('LineNr', { fg = p.muted })
|
||||
h('MatchParen', { fg = p.text, bg = p.highlight_med })
|
||||
h('ModeMsg', { fg = p.subtle })
|
||||
h('MoreMsg', { fg = p.iris })
|
||||
h('NonText', { fg = p.muted })
|
||||
h('Normal', { fg = p.text, bg = maybe.base })
|
||||
h('NormalFloat', { fg = p.text, bg = maybe.surface })
|
||||
h('NormalNC', { fg = p.text, bg = maybe.dim_nc_background })
|
||||
h('NvimInternalError', { fg = '#ffffff', bg = p.love })
|
||||
h('Pmenu', { fg = p.subtle, bg = maybe.surface })
|
||||
h('PmenuSbar', { bg = p.highlight_low })
|
||||
h('PmenuSel', { fg = p.text, bg = p.overlay })
|
||||
h('PmenuThumb', { bg = p.highlight_med })
|
||||
h('Question', { fg = p.gold })
|
||||
-- QuickFixLine = {},
|
||||
-- RedrawDebugNormal = {}
|
||||
h('RedrawDebugClear', { fg = '#ffffff', bg = p.gold })
|
||||
h('RedrawDebugComposed', { fg = '#ffffff', bg = p.pine })
|
||||
h('RedrawDebugRecompose', { fg = '#ffffff', bg = p.love })
|
||||
h('Search', { bg = p.highlight_med })
|
||||
h('SpecialKey', { fg = p.foam })
|
||||
h('SpellBad', { sp = p.subtle, undercurl = true })
|
||||
h('SpellCap', { sp = p.subtle, undercurl = true })
|
||||
h('SpellLocal', { sp = p.subtle, undercurl = true })
|
||||
h('SpellRare', { sp = p.subtle, undercurl = true })
|
||||
h('SignColumn', {
|
||||
fg = p.text,
|
||||
bg = (options.dim_nc_background and p.none) or maybe.base,
|
||||
})
|
||||
h('StatusLine', { fg = p.subtle, bg = groups.panel })
|
||||
h('StatusLineNC', { fg = p.muted, bg = groups.panel_nc })
|
||||
h('StatusLineTerm', { link = 'StatusLine' })
|
||||
h('StatusLineTermNC', { link = 'StatusLineNC' })
|
||||
h('TabLine', { fg = p.subtle, bg = groups.panel })
|
||||
h('TabLineFill', { bg = groups.panel })
|
||||
h('TabLineSel', { fg = p.text, bg = p.overlay })
|
||||
h('Title', { fg = p.text })
|
||||
h('VertSplit', { fg = groups.border, bg = maybe.bold_vert_split })
|
||||
h('Visual', { bg = p.highlight_med })
|
||||
-- VisualNOS = {},
|
||||
h('WarningMsg', { fg = p.gold })
|
||||
-- Whitespace = {},
|
||||
h('WildMenu', { link = 'IncSearch' })
|
||||
|
||||
h('Boolean', { fg = p.rose })
|
||||
h('Character', { fg = p.gold })
|
||||
h('Comment', { fg = groups.comment, italic = maybe.italic })
|
||||
h('Conditional', { fg = p.pine })
|
||||
h('Constant', { fg = p.gold })
|
||||
h('Debug', { fg = p.rose })
|
||||
h('Define', { fg = p.iris })
|
||||
h('Delimiter', { fg = p.subtle })
|
||||
h('Error', { fg = p.love })
|
||||
h('Exception', { fg = p.pine })
|
||||
h('Float', { fg = p.gold })
|
||||
h('Function', { fg = p.rose })
|
||||
h('Identifier', { fg = p.rose })
|
||||
-- Ignore = {},
|
||||
h('Include', { fg = p.iris })
|
||||
h('Keyword', { fg = p.pine })
|
||||
h('Label', { fg = p.foam })
|
||||
h('Macro', { fg = p.iris })
|
||||
h('Number', { fg = p.gold })
|
||||
h('Operator', { fg = p.subtle })
|
||||
h('PreCondit', { fg = p.iris })
|
||||
h('PreProc', { fg = p.iris })
|
||||
h('Repeat', { fg = p.pine })
|
||||
h('Special', { fg = p.rose })
|
||||
h('SpecialChar', { fg = p.rose })
|
||||
h('SpecialComment', { fg = p.iris })
|
||||
h('Statement', { fg = p.pine })
|
||||
h('StorageClass', { fg = p.foam })
|
||||
h('String', { fg = p.gold })
|
||||
h('Structure', { fg = p.foam })
|
||||
h('Tag', { fg = p.rose })
|
||||
h('Todo', { fg = p.iris })
|
||||
h('Type', { fg = p.foam })
|
||||
h('Typedef', { link = 'Type' })
|
||||
h('Underlined', { underline = true })
|
||||
|
||||
h('htmlArg', { fg = p.iris })
|
||||
h('htmlBold', { bold = true })
|
||||
h('htmlEndTag', { fg = p.subtle })
|
||||
h('htmlH1', { fg = groups.headings.h1, bold = true })
|
||||
h('htmlH2', { fg = groups.headings.h2, bold = true })
|
||||
h('htmlH3', { fg = groups.headings.h3, bold = true })
|
||||
h('htmlH4', { fg = groups.headings.h4, bold = true })
|
||||
h('htmlH5', { fg = groups.headings.h5, bold = true })
|
||||
h('htmlItalic', { italic = maybe.italic })
|
||||
h('htmlLink', { fg = groups.link })
|
||||
h('htmlTag', { fg = p.subtle })
|
||||
h('htmlTagN', { fg = p.text })
|
||||
h('htmlTagName', { fg = p.foam })
|
||||
|
||||
h('markdownDelimiter', { fg = p.subtle })
|
||||
h('markdownH1', { fg = groups.headings.h1, bold = true })
|
||||
h('markdownH1Delimiter', { link = 'markdownH1' })
|
||||
h('markdownH2', { fg = groups.headings.h2, bold = true })
|
||||
h('markdownH2Delimiter', { link = 'markdownH2' })
|
||||
h('markdownH3', { fg = groups.headings.h3, bold = true })
|
||||
h('markdownH3Delimiter', { link = 'markdownH3' })
|
||||
h('markdownH4', { fg = groups.headings.h4, bold = true })
|
||||
h('markdownH4Delimiter', { link = 'markdownH4' })
|
||||
h('markdownH5', { fg = groups.headings.h5, bold = true })
|
||||
h('markdownH5Delimiter', { link = 'markdownH5' })
|
||||
h('markdownH6', { fg = groups.headings.h6, bold = true })
|
||||
h('markdownH6Delimiter', { link = 'markdownH6' })
|
||||
h(
|
||||
'markdownLinkText',
|
||||
{ fg = groups.link, sp = groups.link, underline = true }
|
||||
)
|
||||
h('markdownUrl', { link = 'markdownLinkText' })
|
||||
|
||||
h('mkdCode', { fg = p.foam, italic = maybe.italic })
|
||||
h('mkdCodeDelimiter', { fg = p.rose })
|
||||
h('mkdCodeEnd', { fg = p.foam })
|
||||
h('mkdCodeStart', { fg = p.foam })
|
||||
h('mkdFootnotes', { fg = p.foam })
|
||||
h('mkdID', { fg = p.foam, underline = true })
|
||||
h('mkdInlineURL', { fg = groups.link, underline = true })
|
||||
h('mkdLink', { link = 'mkdInlineURL' })
|
||||
h('mkdLinkDef', { link = 'mkdInlineURL' })
|
||||
h('mkdListItemLine', { fg = p.text })
|
||||
h('mkdRule', { fg = p.subtle })
|
||||
h('mkdURL', { link = 'mkdInlineURL' })
|
||||
|
||||
h('DiagnosticError', { fg = groups.error })
|
||||
h('DiagnosticHint', { fg = groups.hint })
|
||||
h('DiagnosticInfo', { fg = groups.info })
|
||||
h('DiagnosticWarn', { fg = groups.warn })
|
||||
h('DiagnosticDefaultError', { fg = groups.error })
|
||||
h('DiagnosticDefaultHint', { fg = groups.hint })
|
||||
h('DiagnosticDefaultInfo', { fg = groups.info })
|
||||
h('DiagnosticDefaultWarn', { fg = groups.warn })
|
||||
h('DiagnosticFloatingError', { fg = groups.error })
|
||||
h('DiagnosticFloatingHint', { fg = groups.hint })
|
||||
h('DiagnosticFloatingInfo', { fg = groups.info })
|
||||
h('DiagnosticFloatingWarn', { fg = groups.warn })
|
||||
h('DiagnosticSignError', { fg = groups.error })
|
||||
h('DiagnosticSignHint', { fg = groups.hint })
|
||||
h('DiagnosticSignInfo', { fg = groups.info })
|
||||
h('DiagnosticSignWarn', { fg = groups.warn })
|
||||
h('DiagnosticStatusLineError', { fg = groups.error, bg = groups.panel })
|
||||
h('DiagnosticStatusLineHint', { fg = groups.hint, bg = groups.panel })
|
||||
h('DiagnosticStatusLineInfo', { fg = groups.info, bg = groups.panel })
|
||||
h('DiagnosticStatusLineWarn', { fg = groups.warn, bg = groups.panel })
|
||||
h('DiagnosticUnderlineError', { sp = groups.error, undercurl = true })
|
||||
h('DiagnosticUnderlineHint', { sp = groups.hint, undercurl = true })
|
||||
h('DiagnosticUnderlineInfo', { sp = groups.info, undercurl = true })
|
||||
h('DiagnosticUnderlineWarn', { sp = groups.warn, undercurl = true })
|
||||
h('DiagnosticVirtualTextError', { fg = groups.error })
|
||||
h('DiagnosticVirtualTextHint', { fg = groups.hint })
|
||||
h('DiagnosticVirtualTextInfo', { fg = groups.info })
|
||||
h('DiagnosticVirtualTextWarn', { fg = groups.warn })
|
||||
|
||||
-- healthcheck
|
||||
h('healthError', { fg = groups.error })
|
||||
h('healthSuccess', { fg = groups.info })
|
||||
h('healthWarning', { fg = groups.warn })
|
||||
|
||||
-- Treesitter
|
||||
h('@boolean', { link = 'Boolean' })
|
||||
h('@character', { link = 'Character' })
|
||||
h('@character.special', { link = '@character' })
|
||||
h('@class', { fg = p.foam })
|
||||
h('@comment', { link = 'Comment' })
|
||||
h('@conditional', { link = 'Conditional' })
|
||||
h('@constant', { link = 'Constant' })
|
||||
h('@constant.builtin', { fg = p.love })
|
||||
h('@constant.macro', { link = '@constant' })
|
||||
h('@constructor', { fg = p.foam })
|
||||
h('@field', { fg = p.foam })
|
||||
h('@function', { link = 'Function' })
|
||||
h('@function.builtin', { fg = p.love })
|
||||
h('@function.macro', { link = '@function' })
|
||||
h('@include', { link = 'Include' })
|
||||
h('@interface', { fg = p.foam })
|
||||
h('@keyword', { link = 'Keyword' })
|
||||
h('@keyword.operator', { fg = p.subtle })
|
||||
h('@label', { link = 'Label' })
|
||||
h('@macro', { link = 'Macro' })
|
||||
h('@method', { fg = p.iris })
|
||||
h('@number', { link = 'Number' })
|
||||
h('@operator', { link = 'Operator' })
|
||||
h('@parameter', { fg = p.iris, italic = maybe.italic })
|
||||
h('@preproc', { link = 'PreProc' })
|
||||
h('@property', { fg = p.foam, italic = maybe.italic })
|
||||
h('@punctuation', { fg = groups.punctuation })
|
||||
h('@punctuation.bracket', { link = '@punctuation' })
|
||||
h('@punctuation.delimiter', { link = '@punctuation' })
|
||||
h('@punctuation.special', { link = '@punctuation' })
|
||||
h('@regexp', { link = 'String' })
|
||||
h('@repeat', { link = 'Repeat' })
|
||||
h('@storageclass', { link = 'StorageClass' })
|
||||
h('@string', { link = 'String' })
|
||||
h('@string.escape', { fg = p.pine })
|
||||
h('@string.special', { link = '@string' })
|
||||
h('@symbol', { link = 'Identifier' })
|
||||
h('@tag', { link = 'Tag' })
|
||||
h('@tag.attribute', { fg = p.iris })
|
||||
h('@tag.delimiter', { fg = p.subtle })
|
||||
h('@text', { fg = p.text })
|
||||
h('@text.strong', { bold = true })
|
||||
h('@text.emphasis', { italic = true })
|
||||
h('@text.underline', { underline = true })
|
||||
h('@text.strike', { strikethrough = true })
|
||||
h('@text.math', { link = 'Special' })
|
||||
h('@text.environment', { link = 'Macro' })
|
||||
h('@text.environment.name', { link = 'Type' })
|
||||
h('@text.title', { link = 'Title' })
|
||||
h('@text.uri', { fg = groups.link })
|
||||
h('@text.note', { link = 'SpecialComment' })
|
||||
h('@text.warning', { fg = groups.warn })
|
||||
h('@text.danger', { fg = groups.error })
|
||||
h('@todo', { link = 'Todo' })
|
||||
h('@type', { link = 'Type' })
|
||||
h('@variable', { fg = p.text, italic = maybe.italic })
|
||||
h('@variable.builtin', { fg = p.love })
|
||||
h('@namespace', { link = '@include' })
|
||||
|
||||
-- LSP Semantic Token Groups
|
||||
h('@lsp.type.enum', { link = '@type' })
|
||||
h('@lsp.type.keyword', { link = '@keyword' })
|
||||
h('@lsp.type.interface', { link = '@interface' })
|
||||
h('@lsp.type.namespace', { link = '@namespace' })
|
||||
h('@lsp.type.parameter', { link = '@parameter' })
|
||||
h('@lsp.type.property', { link = '@property' })
|
||||
h('@lsp.type.variable', {}) -- use treesitter styles for regular variables
|
||||
h('@lsp.typemod.function.defaultLibrary', { link = 'Special' })
|
||||
h('@lsp.typemod.variable.defaultLibrary', { link = '@variable.builtin' })
|
||||
|
||||
-- vim.lsp.buf.document_highlight()
|
||||
h('LspReferenceText', { bg = p.highlight_med })
|
||||
h('LspReferenceRead', { bg = p.highlight_med })
|
||||
h('LspReferenceWrite', { bg = p.highlight_med })
|
||||
|
||||
-- lsp-highlight-codelens
|
||||
h('LspCodeLens', { fg = p.subtle }) -- virtual text of code len
|
||||
h('LspCodeLensSeparator', { fg = p.highlight_high }) -- separator between two or more code len
|
||||
|
||||
-- romgrk/barbar.nvim
|
||||
h('BufferCurrent', { fg = p.text, bg = p.overlay })
|
||||
h('BufferCurrentIndex', { fg = p.text, bg = p.overlay })
|
||||
h('BufferCurrentMod', { fg = p.foam, bg = p.overlay })
|
||||
h('BufferCurrentSign', { fg = p.subtle, bg = p.overlay })
|
||||
h('BufferCurrentTarget', { fg = p.gold, bg = p.overlay })
|
||||
h('BufferInactive', { fg = p.subtle })
|
||||
h('BufferInactiveIndex', { fg = p.subtle })
|
||||
h('BufferInactiveMod', { fg = p.foam })
|
||||
h('BufferInactiveSign', { fg = p.muted })
|
||||
h('BufferInactiveTarget', { fg = p.gold })
|
||||
h('BufferTabpageFill', { fg = groups.background, bg = groups.background })
|
||||
h('BufferVisible', { fg = p.subtle })
|
||||
h('BufferVisibleIndex', { fg = p.subtle })
|
||||
h('BufferVisibleMod', { fg = p.foam })
|
||||
h('BufferVisibleSign', { fg = p.muted })
|
||||
h('BufferVisibleTarget', { fg = p.gold })
|
||||
|
||||
-- lewis6991/gitsigns.nvim
|
||||
h('GitSignsAdd', { fg = groups.git_add })
|
||||
h('GitSignsChange', { fg = groups.git_change })
|
||||
h('GitSignsDelete', { fg = groups.git_delete })
|
||||
h('SignAdd', { link = 'GitSignsAdd' })
|
||||
h('SignChange', { link = 'GitSignsChange' })
|
||||
h('SignDelete', { link = 'GitSignsDelete' })
|
||||
|
||||
-- mvllow/modes.nvim
|
||||
h('ModesCopy', { bg = p.gold })
|
||||
h('ModesDelete', { bg = p.love })
|
||||
h('ModesInsert', { bg = p.foam })
|
||||
h('ModesVisual', { bg = p.iris })
|
||||
|
||||
-- kyazdani42/nvim-tree.lua
|
||||
h('NvimTreeEmptyFolderName', { fg = p.muted })
|
||||
h('NvimTreeFileDeleted', { fg = p.love })
|
||||
h('NvimTreeFileDirty', { fg = p.rose })
|
||||
h('NvimTreeFileMerge', { fg = p.iris })
|
||||
h('NvimTreeFileNew', { fg = p.foam })
|
||||
h('NvimTreeFileRenamed', { fg = p.pine })
|
||||
h('NvimTreeFileStaged', { fg = p.iris })
|
||||
h('NvimTreeFolderIcon', { fg = p.subtle })
|
||||
h('NvimTreeFolderName', { fg = p.foam })
|
||||
h('NvimTreeGitDeleted', { fg = groups.git_delete })
|
||||
h('NvimTreeGitDirty', { fg = groups.git_dirty })
|
||||
h('NvimTreeGitIgnored', { fg = groups.git_ignore })
|
||||
h('NvimTreeGitMerge', { fg = groups.git_merge })
|
||||
h('NvimTreeGitNew', { fg = groups.git_add })
|
||||
h('NvimTreeGitRenamed', { fg = groups.git_rename })
|
||||
h('NvimTreeGitStaged', { fg = groups.git_stage })
|
||||
h('NvimTreeImageFile', { fg = p.text })
|
||||
h('NvimTreeNormal', { fg = p.text })
|
||||
h('NvimTreeOpenedFile', { fg = p.text, bg = p.highlight_med })
|
||||
h('NvimTreeOpenedFolderName', { link = 'NvimTreeFolderName' })
|
||||
h('NvimTreeRootFolder', { fg = p.iris })
|
||||
h('NvimTreeSpecialFile', { link = 'NvimTreeNormal' })
|
||||
h('NvimTreeWindowPicker', { fg = p.love, bg = p.love, blend = 10 })
|
||||
|
||||
-- nvim-neo-tree/neo-tree.nvim
|
||||
h('NeoTreeTitleBar', { fg = p.surface, bg = p.pine })
|
||||
|
||||
-- folke/which-key.nvim
|
||||
h('WhichKey', { fg = p.iris })
|
||||
h('WhichKeyGroup', { fg = p.foam })
|
||||
h('WhichKeySeparator', { fg = p.subtle })
|
||||
h('WhichKeyDesc', { fg = p.gold })
|
||||
h('WhichKeyFloat', { bg = maybe.surface })
|
||||
h('WhichKeyValue', { fg = p.rose })
|
||||
|
||||
-- luka-reineke/indent-blankline.nvim
|
||||
h('IndentBlanklineChar', { fg = p.muted })
|
||||
h('IndentBlanklineSpaceChar', { fg = p.muted })
|
||||
h('IndentBlanklineSpaceCharBlankline', { fg = p.muted })
|
||||
|
||||
-- hrsh7th/nvim-cmp
|
||||
h('CmpItemAbbr', { fg = p.subtle })
|
||||
h('CmpItemAbbrDeprecated', { fg = p.subtle, strikethrough = true })
|
||||
h('CmpItemAbbrMatch', { fg = p.text, bold = true })
|
||||
h('CmpItemAbbrMatchFuzzy', { fg = p.text, bold = true })
|
||||
h('CmpItemKind', { fg = p.subtle })
|
||||
h('CmpItemKindClass', { fg = p.pine })
|
||||
h('CmpItemKindFunction', { fg = p.rose })
|
||||
h('CmpItemKindInterface', { fg = p.foam })
|
||||
h('CmpItemKindMethod', { fg = p.iris })
|
||||
h('CmpItemKindSnippet', { fg = p.gold })
|
||||
h('CmpItemKindVariable', { fg = p.text })
|
||||
|
||||
-- TimUntersberger/neogit
|
||||
h('NeogitDiffAddHighlight', { fg = p.foam, bg = p.highlight_med })
|
||||
h('NeogitDiffContextHighlight', { bg = p.highlight_low })
|
||||
h('NeogitDiffDeleteHighlight', { fg = p.love, bg = p.highlight_med })
|
||||
h('NeogitHunkHeader', { bg = p.highlight_low })
|
||||
h('NeogitHunkHeaderHighlight', { bg = p.highlight_low })
|
||||
|
||||
-- vimwiki/vimwiki
|
||||
h('VimwikiHR', { fg = p.subtle })
|
||||
h('VimwikiHeader1', { fg = groups.headings.h1, bold = true })
|
||||
h('VimwikiHeader2', { fg = groups.headings.h2, bold = true })
|
||||
h('VimwikiHeader3', { fg = groups.headings.h3, bold = true })
|
||||
h('VimwikiHeader4', { fg = groups.headings.h4, bold = true })
|
||||
h('VimwikiHeader5', { fg = groups.headings.h5, bold = true })
|
||||
h('VimwikiHeader6', { fg = groups.headings.h6, bold = true })
|
||||
h('VimwikiHeaderChar', { fg = p.pine })
|
||||
h('VimwikiLink', { fg = groups.link, underline = true })
|
||||
h('VimwikiList', { fg = p.iris })
|
||||
h('VimwikiNoExistsLink', { fg = p.love })
|
||||
|
||||
-- nvim-neorg/neorg
|
||||
h('NeorgHeading1Prefix', { fg = groups.headings.h1, bold = true })
|
||||
h('NeorgHeading1Title', { link = 'NeorgHeading1Prefix' })
|
||||
h('NeorgHeading2Prefix', { fg = groups.headings.h2, bold = true })
|
||||
h('NeorgHeading2Title', { link = 'NeorgHeading2Prefix' })
|
||||
h('NeorgHeading3Prefix', { fg = groups.headings.h3, bold = true })
|
||||
h('NeorgHeading3Title', { link = 'NeorgHeading3Prefix' })
|
||||
h('NeorgHeading4Prefix', { fg = groups.headings.h4, bold = true })
|
||||
h('NeorgHeading4Title', { link = 'NeorgHeading4Prefix' })
|
||||
h('NeorgHeading5Prefix', { fg = groups.headings.h5, bold = true })
|
||||
h('NeorgHeading5Title', { link = 'NeorgHeading5Prefix' })
|
||||
h('NeorgHeading6Prefix', { fg = groups.headings.h6, bold = true })
|
||||
h('NeorgHeading6Title', { link = 'NeorgHeading6Prefix' })
|
||||
h('NeorgMarkerTitle', { fg = p.text, bold = true })
|
||||
|
||||
-- tami5/lspsaga.nvim (fork of glepnir/lspsaga.nvim)
|
||||
h('DefinitionCount', { fg = p.rose })
|
||||
h('DefinitionIcon', { fg = p.rose })
|
||||
h('DefintionPreviewTitle', { fg = p.rose, bold = true })
|
||||
h('LspFloatWinBorder', { fg = groups.border })
|
||||
h('LspFloatWinNormal', { bg = maybe.surface })
|
||||
h('LspSagaAutoPreview', { fg = p.subtle })
|
||||
h('LspSagaCodeActionBorder', { fg = groups.border })
|
||||
h('LspSagaCodeActionContent', { fg = p.foam })
|
||||
h('LspSagaCodeActionTitle', { fg = p.gold, bold = true })
|
||||
h('LspSagaCodeActionTruncateLine', { link = 'LspSagaCodeActionBorder' })
|
||||
h('LspSagaDefPreviewBorder', { fg = groups.border })
|
||||
h('LspSagaDiagnosticBorder', { fg = groups.border })
|
||||
h('LspSagaDiagnosticHeader', { fg = p.gold, bold = true })
|
||||
h('LspSagaDiagnosticTruncateLine', { link = 'LspSagaDiagnosticBorder' })
|
||||
h('LspSagaDocTruncateLine', { link = 'LspSagaHoverBorder' })
|
||||
h('LspSagaFinderSelection', { fg = p.gold })
|
||||
h('LspSagaHoverBorder', { fg = groups.border })
|
||||
h('LspSagaLspFinderBorder', { fg = groups.border })
|
||||
h('LspSagaRenameBorder', { fg = p.pine })
|
||||
h('LspSagaRenamePromptPrefix', { fg = p.love })
|
||||
h('LspSagaShTruncateLine', { link = 'LspSagaSignatureHelpBorder' })
|
||||
h('LspSagaSignatureHelpBorder', { fg = p.pine })
|
||||
h('ReferencesCount', { fg = p.rose })
|
||||
h('ReferencesIcon', { fg = p.rose })
|
||||
h('SagaShadow', { bg = p.overlay })
|
||||
h('TargetWord', { fg = p.iris })
|
||||
|
||||
-- ray-x/lsp_signature.nvim
|
||||
h('LspSignatureActiveParameter', { bg = p.overlay })
|
||||
|
||||
-- rlane/pounce.nvim
|
||||
h('PounceAccept', { fg = p.love, bg = p.highlight_high })
|
||||
h('PounceAcceptBest', { fg = p.base, bg = p.gold })
|
||||
h('PounceGap', { link = 'Search' })
|
||||
h('PounceMatch', { link = 'Search' })
|
||||
|
||||
local float_background = options.dim_nc_background
|
||||
and (options.disable_float_background and groups.panel_nc or groups.panel)
|
||||
or maybe.surface
|
||||
|
||||
-- ggandor/leap.nvim
|
||||
h('LeapMatch', { link = 'MatchParen' })
|
||||
h('LeapLabelPrimary', { link = 'IncSearch' })
|
||||
h('LeapLabelSecondary', { fg = p.base, bg = p.pine })
|
||||
|
||||
-- nvim-telescope/telescope.nvim
|
||||
h('TelescopeBorder', { fg = groups.border, bg = float_background })
|
||||
h('TelescopeMatching', { fg = p.rose })
|
||||
h('TelescopeNormal', { fg = p.subtle, bg = float_background })
|
||||
h('TelescopePromptNormal', { fg = p.text, bg = float_background })
|
||||
h('TelescopePromptPrefix', { fg = p.subtle })
|
||||
h('TelescopeSelection', { fg = p.text, bg = p.overlay })
|
||||
h('TelescopeSelectionCaret', { fg = p.rose, bg = p.overlay })
|
||||
h('TelescopeTitle', { fg = p.subtle })
|
||||
|
||||
-- rcarriga/nvim-notify
|
||||
h('NotifyINFOBorder', { fg = p.foam })
|
||||
h('NotifyINFOTitle', { link = 'NotifyINFOBorder' })
|
||||
h('NotifyINFOIcon', { link = 'NotifyINFOBorder' })
|
||||
h('NotifyWARNBorder', { fg = p.gold })
|
||||
h('NotifyWARNTitle', { link = 'NotifyWARNBorder' })
|
||||
h('NotifyWARNIcon', { link = 'NotifyWARNBorder' })
|
||||
h('NotifyDEBUGBorder', { fg = p.muted })
|
||||
h('NotifyDEBUGTitle', { link = 'NotifyDEBUGBorder' })
|
||||
h('NotifyDEBUGIcon', { link = 'NotifyDEBUGBorder' })
|
||||
h('NotifyTRACEBorder', { fg = p.iris })
|
||||
h('NotifyTRACETitle', { link = 'NotifyTRACEBorder' })
|
||||
h('NotifyTRACEIcon', { link = 'NotifyTRACEBorder' })
|
||||
h('NotifyERRORBorder', { fg = p.love })
|
||||
h('NotifyERRORTitle', { link = 'NotifyERRORBorder' })
|
||||
h('NotifyERRORIcon', { link = 'NotifyERRORBorder' })
|
||||
|
||||
-- rcarriga/nvim-dap-ui
|
||||
h('DapUIVariable', { link = 'Normal' })
|
||||
h('DapUIValue', { link = 'Normal' })
|
||||
h('DapUIFrameName', { link = 'Normal' })
|
||||
h('DapUIThread', { fg = p.gold })
|
||||
h('DapUIWatchesValue', { link = 'DapUIThread' })
|
||||
h('DapUIBreakpointsInfo', { link = 'DapUIThread' })
|
||||
h('DapUIBreakpointsCurrentLine', { fg = p.gold, bold = true })
|
||||
h('DapUIWatchesEmpty', { fg = p.love })
|
||||
h('DapUIWatchesError', { link = 'DapUIWatchesEmpty' })
|
||||
h('DapUIBreakpointsDisabledLine', { fg = p.muted })
|
||||
h('DapUISource', { fg = p.iris })
|
||||
h('DapUIBreakpointsPath', { fg = p.foam })
|
||||
h('DapUIScope', { link = 'DapUIBreakpointsPath' })
|
||||
h('DapUILineNumber', { link = 'DapUIBreakpointsPath' })
|
||||
h('DapUIBreakpointsLine', { link = 'DapUIBreakpointsPath' })
|
||||
h('DapUIFloatBorder', { link = 'DapUIBreakpointsPath' })
|
||||
h('DapUIStoppedThread', { link = 'DapUIBreakpointsPath' })
|
||||
h('DapUIDecoration', { link = 'DapUIBreakpointsPath' })
|
||||
h('DapUIModifiedValue', { fg = p.foam, bold = true })
|
||||
|
||||
-- glepnir/dashboard-nvim
|
||||
h('DashboardShortcut', { fg = p.love })
|
||||
h('DashboardHeader', { fg = p.pine })
|
||||
h('DashboardCenter', { fg = p.gold })
|
||||
h('DashboardFooter', { fg = p.iris })
|
||||
|
||||
-- SmiteshP/nvim-navic
|
||||
h('NavicIconsFile', { fg = p.base })
|
||||
h('NavicIconsModule', { fg = p.rose })
|
||||
h('NavicIconsNamespace', { fg = p.base })
|
||||
h('NavicIconsPackage', { fg = p.base })
|
||||
h('NavicIconsClass', { fg = p.foam })
|
||||
h('NavicIconsMethod', { fg = p.iris })
|
||||
h('NavicIconsProperty', { fg = p.foam })
|
||||
h('NavicIconsField', { fg = p.foam })
|
||||
h('NavicIconsConstructor', { fg = p.gold })
|
||||
h('NavicIconsEnum', { fg = p.gold })
|
||||
h('NavicIconsInterface', { fg = p.foam })
|
||||
h('NavicIconsFunction', { fg = p.pine })
|
||||
h('NavicIconsVariable', { fg = p.text })
|
||||
h('NavicIconsConstant', { fg = p.gold })
|
||||
h('NavicIconsString', { fg = p.gold })
|
||||
h('NavicIconsNumber', { fg = p.gold })
|
||||
h('NavicIconsBoolean', { fg = p.rose })
|
||||
h('NavicIconsArray', { fg = p.gold })
|
||||
h('NavicIconsObject', { fg = p.gold })
|
||||
h('NavicIconsKey', { fg = p.iris })
|
||||
h('NavicIconsKeyword', { fg = p.pine })
|
||||
h('NavicIconsNull', { fg = p.love })
|
||||
h('NavicIconsEnumMember', { fg = p.foam })
|
||||
h('NavicIconsStruct', { fg = p.foam })
|
||||
h('NavicIconsEvent', { fg = p.gold })
|
||||
h('NavicIconsOperator', { fg = p.subtle })
|
||||
h('NavicIconsTypeParameter', { fg = p.foam })
|
||||
h('NavicText', { fg = p.subtle })
|
||||
h('NavicSeparator', { fg = p.subtle })
|
||||
|
||||
-- folke/noice.nvim
|
||||
h('NoiceCursor', { fg = p.highlight_high, bg = p.text })
|
||||
|
||||
-- echasnovski/mini.indentscope
|
||||
h('MiniIndentscopeSymbol', { fg = p.highlight_med })
|
||||
h('MiniIndentscopeSymbolOff', { fg = p.highlight_med })
|
||||
|
||||
-- goolord/alpha-nvim
|
||||
h('AlphaHeader', { fg = p.pine })
|
||||
h('AlphaButtons', { fg = p.foam })
|
||||
h('AlphaShortcut', { fg = p.rose })
|
||||
h('AlphaFooter', { fg = p.gold })
|
||||
|
||||
vim.g.terminal_color_0 = p.overlay -- black
|
||||
vim.g.terminal_color_8 = p.subtle -- bright black
|
||||
vim.g.terminal_color_1 = p.love -- red
|
||||
vim.g.terminal_color_9 = p.love -- bright red
|
||||
vim.g.terminal_color_2 = p.pine -- green
|
||||
vim.g.terminal_color_10 = p.pine -- bright green
|
||||
vim.g.terminal_color_3 = p.gold -- yellow
|
||||
vim.g.terminal_color_11 = p.gold -- bright yellow
|
||||
vim.g.terminal_color_4 = p.foam -- blue
|
||||
vim.g.terminal_color_12 = p.foam -- bright blue
|
||||
vim.g.terminal_color_5 = p.iris -- magenta
|
||||
vim.g.terminal_color_13 = p.iris -- bright magenta
|
||||
vim.g.terminal_color_6 = p.rose -- cyan
|
||||
vim.g.terminal_color_14 = p.rose -- bright cyan
|
||||
vim.g.terminal_color_7 = p.text -- white
|
||||
vim.g.terminal_color_15 = p.text -- bright white
|
||||
|
||||
-- Set user highlights
|
||||
for group, color in pairs(options.highlight_groups) do
|
||||
h(group, color)
|
||||
end
|
||||
end
|
||||
|
||||
return M
|
||||
|
|
@ -1,71 +0,0 @@
|
|||
local util = {}
|
||||
|
||||
local function byte(value, offset)
|
||||
return bit.band(bit.rshift(value, offset), 0xFF)
|
||||
end
|
||||
|
||||
local function rgb(color)
|
||||
color = vim.api.nvim_get_color_by_name(color)
|
||||
|
||||
if color == -1 then
|
||||
color = vim.opt.background:get() == 'dark' and 000 or 255255255
|
||||
end
|
||||
|
||||
return { byte(color, 16), byte(color, 8), byte(color, 0) }
|
||||
end
|
||||
|
||||
local function parse_color(color)
|
||||
if color == nil then
|
||||
return print('invalid color')
|
||||
end
|
||||
|
||||
color = color:lower()
|
||||
|
||||
if not color:find('#') and color ~= 'none' then
|
||||
color = require('rose-pine.palette')[color]
|
||||
or vim.api.nvim_get_color_by_name(color)
|
||||
end
|
||||
|
||||
return color
|
||||
end
|
||||
|
||||
---@param fg string foreground color
|
||||
---@param bg string background color
|
||||
---@param alpha number number between 0 (background) and 1 (foreground)
|
||||
util.blend = function(fg, bg, alpha)
|
||||
local fg_rgb = rgb(parse_color(fg))
|
||||
local bg_rgb = rgb(parse_color(bg))
|
||||
|
||||
local function blend_channel(i)
|
||||
local ret = (alpha * fg_rgb[i] + ((1 - alpha) * bg_rgb[i]))
|
||||
return math.floor(math.min(math.max(0, ret), 255) + 0.5)
|
||||
end
|
||||
|
||||
return string.format(
|
||||
'#%02X%02X%02X',
|
||||
blend_channel(1),
|
||||
blend_channel(2),
|
||||
blend_channel(3)
|
||||
)
|
||||
end
|
||||
|
||||
---@param group string
|
||||
---@param color table<string, any>
|
||||
util.highlight = function(group, color)
|
||||
local fg = color.fg and parse_color(color.fg) or 'none'
|
||||
local bg = color.bg and parse_color(color.bg) or 'none'
|
||||
local sp = color.sp and parse_color(color.sp) or ''
|
||||
|
||||
if
|
||||
color.blend ~= nil
|
||||
and (color.blend >= 0 or color.blend <= 100)
|
||||
and bg ~= nil
|
||||
then
|
||||
bg = util.blend(bg, parse_color('base') or '', color.blend / 100)
|
||||
end
|
||||
|
||||
color = vim.tbl_extend('force', color, { fg = fg, bg = bg, sp = sp })
|
||||
vim.api.nvim_set_hl(0, group, color)
|
||||
end
|
||||
|
||||
return util
|
||||
65
lua/rose-pine/utilities.lua
Normal file
65
lua/rose-pine/utilities.lua
Normal file
|
|
@ -0,0 +1,65 @@
|
|||
local utilities = {}
|
||||
|
||||
---@param color string
|
||||
local function color_to_rgb(color)
|
||||
local function byte(value, offset)
|
||||
return bit.band(bit.rshift(value, offset), 0xFF)
|
||||
end
|
||||
|
||||
local new_color = vim.api.nvim_get_color_by_name(color)
|
||||
if new_color == -1 then
|
||||
new_color = vim.opt.background:get() == "dark" and 000 or 255255255
|
||||
end
|
||||
|
||||
return { byte(new_color, 16), byte(new_color, 8), byte(new_color, 0) }
|
||||
end
|
||||
|
||||
local color_cache = {}
|
||||
|
||||
---@param color string Palette key or hex value
|
||||
function utilities.parse_color(color)
|
||||
if color_cache[color] then
|
||||
return color_cache[color]
|
||||
end
|
||||
|
||||
if color == nil then
|
||||
print("Invalid color: " .. color)
|
||||
return nil
|
||||
end
|
||||
|
||||
color = color:lower()
|
||||
|
||||
if not color:find("#") and color ~= "NONE" then
|
||||
color = require("rose-pine.palette")[color] or vim.api.nvim_get_color_by_name(color)
|
||||
end
|
||||
|
||||
color_cache[color] = color
|
||||
return color
|
||||
end
|
||||
|
||||
local blend_cache = {}
|
||||
|
||||
---@param fg string Foreground color
|
||||
---@param bg string Background color
|
||||
---@param alpha number Between 0 (background) and 1 (foreground)
|
||||
function utilities.blend(fg, bg, alpha)
|
||||
local cache_key = fg .. bg .. alpha
|
||||
if blend_cache[cache_key] then
|
||||
return blend_cache[cache_key]
|
||||
end
|
||||
|
||||
local fg_rgb = color_to_rgb(fg)
|
||||
local bg_rgb = color_to_rgb(bg)
|
||||
|
||||
local function blend_channel(i)
|
||||
local ret = (alpha * fg_rgb[i] + ((1 - alpha) * bg_rgb[i]))
|
||||
return math.floor(math.min(math.max(0, ret), 255) + 0.5)
|
||||
end
|
||||
|
||||
local result = string.format("#%02X%02X%02X", blend_channel(1), blend_channel(2), blend_channel(3))
|
||||
|
||||
blend_cache[cache_key] = result
|
||||
return result
|
||||
end
|
||||
|
||||
return utilities
|
||||
170
readme.md
170
readme.md
|
|
@ -11,27 +11,36 @@
|
|||
</a>
|
||||
</p>
|
||||
|
||||
## Usage
|
||||
## Getting started
|
||||
|
||||
> With [lazy.nvim](https://github.com/folke/lazy.nvim)
|
||||
Install `rose-pine/neovim` using your favourite package manager:
|
||||
|
||||
### [pam.nvim](https://github.com/mvllow/pam.nvim)
|
||||
|
||||
```lua
|
||||
require("lazy").setup({
|
||||
{ 'rose-pine/neovim', name = 'rose-pine' }
|
||||
})
|
||||
|
||||
vim.cmd('colorscheme rose-pine')
|
||||
{ source = "rose-pine/neovim", as = "rose-pine" }
|
||||
```
|
||||
|
||||
> With [packer.nvim](https://github.com/wbthomason/packer.nvim)
|
||||
### [lazy.nvim](https://lazy.folke.io/installation)
|
||||
|
||||
**Structured Setup**
|
||||
|
||||
```lua
|
||||
use({ 'rose-pine/neovim', as = 'rose-pine' })
|
||||
|
||||
vim.cmd('colorscheme rose-pine')
|
||||
-- lua/plugins/rose-pine.lua
|
||||
return {
|
||||
"rose-pine/neovim",
|
||||
name = "rose-pine",
|
||||
config = function()
|
||||
vim.cmd("colorscheme rose-pine")
|
||||
end
|
||||
}
|
||||
```
|
||||
|
||||
_Supported plugins are listed in the [wiki](https://github.com/rose-pine/neovim/wiki#supported-plugins)_
|
||||
**Single file**
|
||||
|
||||
```lua
|
||||
{ "rose-pine/neovim", name = "rose-pine" }
|
||||
```
|
||||
|
||||
## Gallery
|
||||
|
||||
|
|
@ -49,69 +58,104 @@ _Supported plugins are listed in the [wiki](https://github.com/rose-pine/neovim/
|
|||
|
||||
## Options
|
||||
|
||||
> Options should be set **before** colorscheme
|
||||
> [!IMPORTANT]
|
||||
> Configure options _before_ setting colorscheme.
|
||||
|
||||
Variant respects `vim.o.background`, using dawn when light and `dark_variant` when dark
|
||||
Rosé Pine has three variants: main, moon, and dawn. By default, `vim.o.background` is followed, using dawn when light and `dark_variant` when dark.
|
||||
|
||||
Colour values accept named colours from the [Rosé Pine palette](https://rosepinetheme.com/palette/ingredients/), e.g. "foam", or valid hex, e.g. "#fa8072".
|
||||
|
||||
```lua
|
||||
require('rose-pine').setup({
|
||||
--- @usage 'auto'|'main'|'moon'|'dawn'
|
||||
variant = 'auto',
|
||||
--- @usage 'main'|'moon'|'dawn'
|
||||
dark_variant = 'main',
|
||||
bold_vert_split = false,
|
||||
dim_nc_background = false,
|
||||
disable_background = false,
|
||||
disable_float_background = false,
|
||||
disable_italics = false,
|
||||
require("rose-pine").setup({
|
||||
variant = "auto", -- auto, main, moon, or dawn
|
||||
dark_variant = "main", -- main, moon, or dawn
|
||||
dim_inactive_windows = false,
|
||||
extend_background_behind_borders = true,
|
||||
|
||||
--- @usage string hex value or named color from rosepinetheme.com/palette
|
||||
groups = {
|
||||
background = 'base',
|
||||
background_nc = '_experimental_nc',
|
||||
panel = 'surface',
|
||||
panel_nc = 'base',
|
||||
border = 'highlight_med',
|
||||
comment = 'muted',
|
||||
link = 'iris',
|
||||
punctuation = 'subtle',
|
||||
enable = {
|
||||
terminal = true,
|
||||
legacy_highlights = true, -- Improve compatibility for previous versions of Neovim
|
||||
migrations = true, -- Handle deprecated options automatically
|
||||
},
|
||||
|
||||
error = 'love',
|
||||
hint = 'iris',
|
||||
info = 'foam',
|
||||
warn = 'gold',
|
||||
styles = {
|
||||
bold = true,
|
||||
italic = true,
|
||||
transparency = false,
|
||||
},
|
||||
|
||||
headings = {
|
||||
h1 = 'iris',
|
||||
h2 = 'foam',
|
||||
h3 = 'rose',
|
||||
h4 = 'gold',
|
||||
h5 = 'pine',
|
||||
h6 = 'foam',
|
||||
}
|
||||
-- or set all headings at once
|
||||
-- headings = 'subtle'
|
||||
},
|
||||
groups = {
|
||||
border = "muted",
|
||||
link = "iris",
|
||||
panel = "surface",
|
||||
|
||||
-- Change specific vim highlight groups
|
||||
-- https://github.com/rose-pine/neovim/wiki/Recipes
|
||||
highlight_groups = {
|
||||
ColorColumn = { bg = 'rose' },
|
||||
error = "love",
|
||||
hint = "iris",
|
||||
info = "foam",
|
||||
note = "pine",
|
||||
todo = "rose",
|
||||
warn = "gold",
|
||||
|
||||
-- Blend colours against the "base" background
|
||||
CursorLine = { bg = 'foam', blend = 10 },
|
||||
StatusLine = { fg = 'love', bg = 'love', blend = 10 },
|
||||
}
|
||||
git_add = "foam",
|
||||
git_change = "rose",
|
||||
git_delete = "love",
|
||||
git_dirty = "rose",
|
||||
git_ignore = "muted",
|
||||
git_merge = "iris",
|
||||
git_rename = "pine",
|
||||
git_stage = "iris",
|
||||
git_text = "rose",
|
||||
git_untracked = "subtle",
|
||||
|
||||
h1 = "iris",
|
||||
h2 = "foam",
|
||||
h3 = "rose",
|
||||
h4 = "gold",
|
||||
h5 = "pine",
|
||||
h6 = "foam",
|
||||
},
|
||||
|
||||
palette = {
|
||||
-- Override the builtin palette per variant
|
||||
-- moon = {
|
||||
-- base = '#18191a',
|
||||
-- overlay = '#363738',
|
||||
-- },
|
||||
},
|
||||
|
||||
-- NOTE: Highlight groups are extended (merged) by default. Disable this
|
||||
-- per group via `inherit = false`
|
||||
highlight_groups = {
|
||||
-- Comment = { fg = "foam" },
|
||||
-- StatusLine = { fg = "love", bg = "love", blend = 15 },
|
||||
-- VertSplit = { fg = "muted", bg = "muted" },
|
||||
-- Visual = { fg = "base", bg = "text", inherit = false },
|
||||
},
|
||||
|
||||
before_highlight = function(group, highlight, palette)
|
||||
-- Disable all undercurls
|
||||
-- if highlight.undercurl then
|
||||
-- highlight.undercurl = false
|
||||
-- end
|
||||
--
|
||||
-- Change palette colour
|
||||
-- if highlight.fg == palette.pine then
|
||||
-- highlight.fg = palette.foam
|
||||
-- end
|
||||
end,
|
||||
})
|
||||
|
||||
-- Set colorscheme after options
|
||||
vim.cmd('colorscheme rose-pine')
|
||||
vim.cmd("colorscheme rose-pine")
|
||||
-- vim.cmd("colorscheme rose-pine-main")
|
||||
-- vim.cmd("colorscheme rose-pine-moon")
|
||||
-- vim.cmd("colorscheme rose-pine-dawn")
|
||||
```
|
||||
|
||||
> [!NOTE]
|
||||
> Visit the [wiki](https://github.com/rose-pine/neovim/wiki) for [plugin configurations](https://github.com/rose-pine/neovim/wiki/Plugin-configurations) and [recipes](https://github.com/rose-pine/neovim/wiki/Recipes).
|
||||
|
||||
## Contributing
|
||||
|
||||
We welcome and appreciate any help in creating a lovely experience for all.
|
||||
We welcome and appreciate contributions of any kind. Create an issue or start a discussion for any proposed changes. Pull requests are encouraged for supporting additional plugins or [treesitter improvements](https://github.com/nvim-treesitter/nvim-treesitter/blob/master/CONTRIBUTING.md#highlights).
|
||||
|
||||
- Get highlight groups under cursor via `:Inspect` in Neovim 0.9 or [nvim-treesitter/playground](https://github.com/nvim-treesitter/playground#show-treesitter-and-syntax-highlight-groups-under-the-cursor)
|
||||
- [Adding new highlight groups](https://github.com/rose-pine/neovim/issues/6#issuecomment-962466323)
|
||||
- [Palette reference by name](https://rosepinetheme.com/palette)
|
||||
Feel free to update the [wiki](https://github.com/rose-pine/neovim/wiki/) with any [recipes](https://github.com/rose-pine/neovim/wiki/Recipes).
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue