From 5fff1b370d9281ab213168bae921c820ed577c39 Mon Sep 17 00:00:00 2001 From: loctvl842 Date: Thu, 19 Sep 2024 00:00:05 +0700 Subject: [PATCH] feat: support fzf-lua --- lua/monokai-pro/theme/init.lua | 2 ++ lua/monokai-pro/theme/plugins/fzf-lua.lua | 32 +++++++++++++++++++++ lua/monokai-pro/theme/plugins/which-key.lua | 2 +- 3 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 lua/monokai-pro/theme/plugins/fzf-lua.lua diff --git a/lua/monokai-pro/theme/init.lua b/lua/monokai-pro/theme/init.lua index 3fe6b23..f60f423 100644 --- a/lua/monokai-pro/theme/init.lua +++ b/lua/monokai-pro/theme/init.lua @@ -25,6 +25,8 @@ local PLUGINS = { "cmp", "coc", "dashboard", + "fidget", + "fzf-lua", "gitsign", "illuminate", "indent_blankline", diff --git a/lua/monokai-pro/theme/plugins/fzf-lua.lua b/lua/monokai-pro/theme/plugins/fzf-lua.lua new file mode 100644 index 0000000..d2b74e2 --- /dev/null +++ b/lua/monokai-pro/theme/plugins/fzf-lua.lua @@ -0,0 +1,32 @@ +local M = {} + +--- @param c Colorscheme The color palette +--- @param config Config +--- @param hp Helper +function M.get(c, config, hp) + local transparent_bg = c.editor.background + + local common_fg = hp.lighten(c.sideBar.foreground, 30) + + return { + FzfLuaNormal = { bg = transparent_bg, fg = common_fg }, + FzfLuaBorder = { bg = transparent_bg, fg = c.tab.unfocusedActiveBorder }, + FzfLuaTitle = { bg = c.base.yellow, fg = c.base.black, bold = true }, + FzfLuaBackdrop = { bg = c.base.dark }, + FzfLuaPreviewNormal = { bg = transparent_bg }, + FzfLuaPreviewBorder = { link = "FzfLuaBorder" }, + FzfLuaPreviewTitle = { bg = hp.lighten(transparent_bg, 3), fg = c.base.blue, bold = true }, + FzfLuaCursorLine = { bg = hp.blend(c.editorSuggestWidget.selectedBackground, 0.3, transparent_bg), bold = true }, + FzfLuaScrollBorderEmpty = { link = "FzfLuaBorder" }, + FzfLuaScrollBorderFull = { link = "FzfLuaBorder" }, + FzfLuaHelpNormal = { bg = transparent_bg, fg = common_fg }, + FzfLuaHelpBorder = { bg = transparent_bg, fg = c.base.green }, + FzfLuaHeaderBind = { fg = c.base.cyan }, + FzfLuaHeaderText = { fg = c.base.green }, + FzfLuaFzfHeader = { fg = common_fg }, + FzfLuaFzfInfo = { fg = c.base.dimmed3 }, + FzfLuaFzfPointer = { fg = c.base.blue }, + } +end + +return M diff --git a/lua/monokai-pro/theme/plugins/which-key.lua b/lua/monokai-pro/theme/plugins/which-key.lua index 9f82511..066f638 100644 --- a/lua/monokai-pro/theme/plugins/which-key.lua +++ b/lua/monokai-pro/theme/plugins/which-key.lua @@ -12,7 +12,7 @@ function M.get(c, config, _) WhichKeySeperator = { fg = c.base.red }, WhichKeyGroup = { fg = c.base.magenta }, WhichKeyDesc = { fg = c.base.yellow }, - WhichKeyFloat = { bg = isBackgroundClear and transparent_bg or whichkey_bg }, + WhichKeyNormal = { bg = isBackgroundClear and transparent_bg or whichkey_bg }, WhichKeyBorder = isBackgroundClear and { bg = transparent_bg, fg = transparent_bg_border,