feat: support transitional seperators with transparent background

This commit is contained in:
shadmansaleh 2022-02-20 14:55:03 +06:00
parent 00020dc3fd
commit 605a30f2fe
1 changed files with 5 additions and 5 deletions

View File

@ -279,12 +279,12 @@ function M.get_transitional_highlights(left_hl, right_hl)
-- Get colors from highlights
local fg = modules.utils.extract_highlight_colors(left_hl, 'bg')
local bg = modules.utils.extract_highlight_colors(right_hl, 'bg')
if not fg or not bg then
return nil
end -- Color retrieval failed
if not fg and not bg then
return nil -- Color retrieval failed
end
if bg == fg then
return nil
end -- Separator won't be visible anyway
return nil -- Separator won't be visible anyway
end
M.highlight(highlight_name, fg, bg, nil)
end
return '%#' .. highlight_name .. '#'