mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-22 08:53:31 +02:00
migrate config form function to global variable
This commit is contained in:
parent
b6f0601d3d
commit
38d2c29a95
24 changed files with 248 additions and 245 deletions
|
@ -22,10 +22,10 @@ _G.switch = function(param, case_table)
|
|||
return def and def() or nil
|
||||
end
|
||||
|
||||
local data_exists, custom_ui = pcall(require, "custom.ui")
|
||||
local data_exists, config = pcall(require, "core.config")
|
||||
if data_exists then
|
||||
if type(custom_ui) == "table" then
|
||||
local color = custom_ui.colorscheme
|
||||
if config.colorscheme ~= nil then
|
||||
local color = config.colorscheme
|
||||
switch(color, {
|
||||
["tokyonight"] = function()
|
||||
gruvbox = false
|
||||
|
@ -206,7 +206,7 @@ if data_exists then
|
|||
end
|
||||
|
||||
local transparent = false
|
||||
local transparent_mode = custom_ui.transparent_mode
|
||||
local transparent_mode = config.transparent_mode
|
||||
if transparent_mode ~= nil then
|
||||
if transparent_mode == 1 then
|
||||
transparent = true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue