Skip to content

Commit

Permalink
fix: correctly fallback to default scheme (#27)
Browse files Browse the repository at this point in the history
  • Loading branch information
adriankarlen authored Oct 3, 2024
1 parent 3b34467 commit 328cc37
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions plugin/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,10 @@ M.apply_to_config = function(c, opts)
options = config.extend_options(config.options, opts)

local scheme = wez.color.get_builtin_schemes()[c.color_scheme]
if scheme == nil then
scheme = wez.color.get_default_colors()
end

local default_colors = {
tab_bar = {
background = "transparent",
Expand All @@ -61,11 +65,7 @@ M.apply_to_config = function(c, opts)
},
}

if c.colors == nil then
c.colors = default_colors
else
c.colors = utilities._merge(default_colors, c.colors)
end
c.colors = utilities._merge(default_colors, scheme)

-- make the plugin own these settings
c.tab_bar_at_bottom = options.position == "bottom"
Expand Down

0 comments on commit 328cc37

Please sign in to comment.