migrate config form function to global variable

This commit is contained in:
asep komarudin 2023-03-05 17:34:12 +07:00
parent b6f0601d3d
commit 38d2c29a95
24 changed files with 248 additions and 245 deletions

View file

@ -4,14 +4,12 @@ if not status_ok then
end
local transp = false
local sidebar = "dark"
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 tras = custom_ui.transparent_mode
if tras ~= nil and tras == 1 then
transp = true
sidebar = "transparent"
end
local tras = config.transparent_mode
if tras == 1 then
transp = true
sidebar = "transparent"
end
end
tokyonight.setup({