From 5e024e8294e744cdb8ce95bb41e8b85b5ac5c10a Mon Sep 17 00:00:00 2001 From: Webhooked <9132742+webhooked@users.noreply.github.com> Date: Sat, 31 Jan 2026 15:39:34 +0100 Subject: [PATCH] fix: preserve explicit theme when background option changes Fixes #48 --- lua/kanso/init.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lua/kanso/init.lua b/lua/kanso/init.lua index 138e901..ed8a54c 100644 --- a/lua/kanso/init.lua +++ b/lua/kanso/init.lua @@ -103,7 +103,8 @@ function M.load(theme) -- Clear cached modules to force reload package.loaded["kanso.colors"] = nil package.loaded["kanso.themes"] = nil - M.load() + -- Pass explicit theme to preserve it; if nil, respects vim.o.background + M.load(M._EXPLICIT_THEME) end end, })