1
Fork 0
satellite/home/features/neovim/config/lua/my/helpers/theme.lua
2023-12-21 16:21:14 +01:00

16 lines
327 B
Lua

local theme = vim.g.nix_theme
local M = {}
M.theme = theme
function M.theme_contains(name)
return string.find(theme.name, name) ~= nil
end
function M.variant(name)
-- +1 for 1-indexed strings and +1 for the space between name and variant
return string.lower(string.sub(theme.name, string.len(name) + 2))
end
return M