|
|
|
@ -1,4 +1,5 @@
|
|
|
|
|
local util = require("catppuccino.utils.util")
|
|
|
|
|
local colors_util = require("catppuccino.utils.colors")
|
|
|
|
|
|
|
|
|
|
local M = {}
|
|
|
|
|
|
|
|
|
@ -13,7 +14,6 @@ local function set_cs(val)
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
local function get_base()
|
|
|
|
|
|
|
|
|
|
local cpt = get_cs()
|
|
|
|
|
|
|
|
|
|
return {
|
|
|
|
@ -134,11 +134,9 @@ local function get_base()
|
|
|
|
|
-- debugging
|
|
|
|
|
debugPC = {bg = cpt.bg_sidebar}, -- used for highlighting the current line in terminal-debug
|
|
|
|
|
debugBreakpoint = {bg = util.darken(cpt.info, 0.1), fg = cpt.info}, -- used for breakpoint colors in terminal-debug
|
|
|
|
|
|
|
|
|
|
-- illuminate
|
|
|
|
|
illuminatedWord = {bg = cpt.fg_gutter},
|
|
|
|
|
illuminatedCurWord = {bg = cpt.fg_gutter},
|
|
|
|
|
|
|
|
|
|
-- diff
|
|
|
|
|
diffAdded = {fg = cpt.git.add},
|
|
|
|
|
diffRemoved = {fg = cpt.git.delete},
|
|
|
|
@ -148,18 +146,15 @@ local function get_base()
|
|
|
|
|
diffFile = {fg = cpt.blue},
|
|
|
|
|
diffLine = {fg = cpt.comment},
|
|
|
|
|
diffIndexLine = {fg = cpt.magenta},
|
|
|
|
|
|
|
|
|
|
-- git diff
|
|
|
|
|
DiffAdd = {fg = cpt.diff.add, bg = cpt.bg}, -- diff mode: Added line |diff.txt|
|
|
|
|
|
DiffChange = {fg = cpt.diff.change, bg = cpt.bg}, -- diff mode: Changed line |diff.txt|
|
|
|
|
|
DiffDelete = {fg = cpt.diff.delete, bg = cpt.bg}, -- diff mode: Deleted line |diff.txt|
|
|
|
|
|
DiffText = {fg = cpt.diff.text, bg = cpt.bg}, -- diff mode: Changed text within a changed line |diff.txt|
|
|
|
|
|
|
|
|
|
|
-- NeoVim
|
|
|
|
|
healthError = {fg = cpt.error},
|
|
|
|
|
healthSuccess = {fg = cpt.green_br},
|
|
|
|
|
healthWarning = {fg = cpt.warning},
|
|
|
|
|
|
|
|
|
|
-- misc
|
|
|
|
|
|
|
|
|
|
-- glyphs
|
|
|
|
@ -169,7 +164,7 @@ local function get_base()
|
|
|
|
|
GlyphPalette4 = {fg = cpt.blue},
|
|
|
|
|
GlyphPalette6 = {fg = cpt.green_br},
|
|
|
|
|
GlyphPalette7 = {fg = cpt.fg},
|
|
|
|
|
GlyphPalette9 = {fg = cpt.red},
|
|
|
|
|
GlyphPalette9 = {fg = cpt.red}
|
|
|
|
|
}
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
@ -198,6 +193,19 @@ local function get_integrations()
|
|
|
|
|
return final_integrations
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
local function get_properties()
|
|
|
|
|
local cpt = get_cs()
|
|
|
|
|
local props = {
|
|
|
|
|
termguicolors = true,
|
|
|
|
|
background = "light"
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (colors_util.assert_brightness(cpt.bg)) then
|
|
|
|
|
props["background"] = "dark"
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
return props
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
function M.apply(cs)
|
|
|
|
|
_G.cpc = require("catppuccino.config").options
|
|
|
|
@ -212,7 +220,8 @@ function M.apply(cs)
|
|
|
|
|
|
|
|
|
|
local theme = {}
|
|
|
|
|
theme.base = get_base()
|
|
|
|
|
theme.plugins = get_integrations()
|
|
|
|
|
theme.integrations = get_integrations()
|
|
|
|
|
theme.properties = get_properties()
|
|
|
|
|
|
|
|
|
|
-- uninstantiate to avoid poluting global scope and because they are not needed anymore
|
|
|
|
|
_G.cpc = nil
|
|
|
|
|