2023-11-01 03:15:26 +08:00
|
|
|
local config = require('flexoki.config')
|
|
|
|
|
2023-11-01 01:09:02 +08:00
|
|
|
local M = {}
|
|
|
|
|
2023-11-01 03:15:26 +08:00
|
|
|
---Load the Flexoki colorscheme
|
|
|
|
---@param opts FlexokiOptions
|
|
|
|
M.colorscheme = function(opts)
|
|
|
|
config.extend(opts)
|
|
|
|
|
|
|
|
vim.o.termguicolors = true
|
2023-11-01 01:09:02 +08:00
|
|
|
|
2023-11-01 03:15:26 +08:00
|
|
|
if vim.g.colors_name then
|
|
|
|
vim.cmd('hi clear')
|
2023-11-01 01:09:02 +08:00
|
|
|
vim.cmd('syntax reset')
|
|
|
|
end
|
|
|
|
|
|
|
|
vim.g.colors_name = 'flexoki'
|
|
|
|
|
2023-11-01 03:15:26 +08:00
|
|
|
require('flexoki.theme').set_highlights()
|
|
|
|
end
|
|
|
|
|
|
|
|
---Set up the Flexoki colorscheme
|
|
|
|
---@param opts FlexokiOptions
|
|
|
|
M.setup = function (opts)
|
|
|
|
config.extend(opts)
|
2023-11-01 01:09:02 +08:00
|
|
|
end
|
|
|
|
|
|
|
|
return M
|