From b4858e1108f263384677c4c5e54b42dff1b59bbc Mon Sep 17 00:00:00 2001 From: Liquid_system <80927666+Liquid-system@users.noreply.github.com> Date: Tue, 11 Oct 2022 03:16:57 +0900 Subject: [PATCH] fix: Make background transparent when nvim-notify is used (#242) --- lua/tokyonight/theme.lua | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/lua/tokyonight/theme.lua b/lua/tokyonight/theme.lua index 7800d0b..5f5acce 100644 --- a/lua/tokyonight/theme.lua +++ b/lua/tokyonight/theme.lua @@ -571,11 +571,11 @@ function M.setup() -- Notify --- Border - NotifyERRORBorder = { fg = util.darken(c.error, 0.3), bg = c.bg }, - NotifyWARNBorder = { fg = util.darken(c.warning, 0.3), bg = c.bg }, - NotifyINFOBorder = { fg = util.darken(c.info, 0.3), bg = c.bg }, - NotifyDEBUGBorder = { fg = util.darken(c.comment, 0.3), bg = c.bg }, - NotifyTRACEBorder = { fg = util.darken(c.purple, 0.3), bg = c.bg }, + NotifyERRORBorder = { fg = util.darken(c.error, 0.3), bg = options.transparent and c.none or c.bg }, + NotifyWARNBorder = { fg = util.darken(c.warning, 0.3), bg = options.transparent and c.none or c.bg }, + NotifyINFOBorder = { fg = util.darken(c.info, 0.3), bg = options.transparent and c.none or c.bg }, + NotifyDEBUGBorder = { fg = util.darken(c.comment, 0.3), bg = options.transparent and c.none or c.bg }, + NotifyTRACEBorder = { fg = util.darken(c.purple, 0.3), bg = options.transparent and c.none or c.bg }, --- Icons NotifyERRORIcon = { fg = c.error }, NotifyWARNIcon = { fg = c.warning }, @@ -589,11 +589,11 @@ function M.setup() NotifyDEBUGTitle = { fg = c.comment }, NotifyTRACETitle = { fg = c.purple }, --- Body - NotifyERRORBody = { fg = c.fg, bg = c.bg }, - NotifyWARNBody = { fg = c.fg, bg = c.bg }, - NotifyINFOBody = { fg = c.fg, bg = c.bg }, - NotifyDEBUGBody = { fg = c.fg, bg = c.bg }, - NotifyTRACEBody = { fg = c.fg, bg = c.bg }, + NotifyERRORBody = { fg = c.fg, bg = options.transparent and c.none or c.bg }, + NotifyWARNBody = { fg = c.fg, bg = options.transparent and c.none or c.bg }, + NotifyINFOBody = { fg = c.fg, bg = options.transparent and c.none or c.bg }, + NotifyDEBUGBody = { fg = c.fg, bg = options.transparent and c.none or c.bg }, + NotifyTRACEBody = { fg = c.fg, bg = options.transparent and c.none or c.bg }, -- Mini MiniCompletionActiveParameter = { underline = true },