mirror of
https://github.com/gabehf/base46.git
synced 2026-03-09 07:28:50 -07:00
restructure file module structure
This commit is contained in:
parent
6689ebc11e
commit
200e308561
56 changed files with 32 additions and 16 deletions
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
## Contribute for new themes
|
||||
|
||||
- go to hl_themes and add your file, ex: atheme.lua
|
||||
- go to base46/themes and add your file, ex: atheme.lua
|
||||
```lua
|
||||
-- atheme.lua file be like
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ local ui = require("core.utils").load_config().ui
|
|||
local merge_tb = require("base46").merge_tb
|
||||
|
||||
local highlights = {}
|
||||
local hl_dir = vim.fn.stdpath "data" .. "/site/pack/packer/opt/base46/lua/integrations"
|
||||
local hl_dir = vim.fn.stdpath "data" .. "/site/pack/packer/opt/base46/lua/base46/integrations"
|
||||
|
||||
-- push hl_dir file names to table
|
||||
local hl_files = require("plenary.scandir").scan_dir(hl_dir, {})
|
||||
|
|
@ -12,7 +12,7 @@ for _, file in ipairs(hl_files) do
|
|||
local a = vim.fn.fnamemodify(file, ":t")
|
||||
a = vim.fn.fnamemodify(a, ":r")
|
||||
|
||||
local integration = require("integrations." .. a)
|
||||
local integration = require("base46.integrations." .. a)
|
||||
highlights = merge_tb(highlights, integration)
|
||||
end
|
||||
|
||||
|
|
@ -48,7 +48,7 @@ end
|
|||
|
||||
-- local set_transparent = nvchad.load_config().ui.transparency
|
||||
if vim.g.transparency then
|
||||
highlights = merge_tb(highlights, require "nv_glassy")
|
||||
highlights = merge_tb(highlights, require "base46.glassy")
|
||||
end
|
||||
|
||||
-- finally set all highlights :D
|
||||
|
|
@ -3,7 +3,7 @@ local g = vim.g
|
|||
local config = require("core.utils").load_config()
|
||||
|
||||
M.get_theme_tb = function(name, type)
|
||||
local default_path = "hl_themes." .. name
|
||||
local default_path = "base46.themes." .. name
|
||||
local user_path = "custom.themes." .. name
|
||||
|
||||
local present1, default_theme = pcall(require, default_path)
|
||||
|
|
@ -46,15 +46,8 @@ M.load_theme = function()
|
|||
local theme_type = M.get_theme_tb(g.nvchad_theme, "type") -- dark/light
|
||||
vim.opt.bg = theme_type
|
||||
|
||||
M.clear_highlights "BufferLine"
|
||||
M.clear_highlights "TS"
|
||||
|
||||
-- reload highlights for theme switcher
|
||||
require("plenary.reload").reload_module "integrations"
|
||||
require("plenary.reload").reload_module "chadlights"
|
||||
require("plenary.reload").reload_module "custom"
|
||||
|
||||
require "chadlights"
|
||||
require "base46.term"
|
||||
require "base46.chadlights"
|
||||
end
|
||||
|
||||
M.override_theme = function(default_theme, theme_name)
|
||||
|
|
@ -7,6 +7,11 @@ return {
|
|||
bg = colors.black2,
|
||||
},
|
||||
|
||||
BufferlineIndicatorVisible = {
|
||||
fg = colors.black2,
|
||||
bg = colors.black2,
|
||||
},
|
||||
|
||||
-- buffers
|
||||
BufferLineBufferSelected = {
|
||||
fg = colors.white,
|
||||
|
|
@ -177,7 +177,7 @@ return {
|
|||
},
|
||||
|
||||
St_cwd_icon = {
|
||||
fg = colors.black,
|
||||
fg = colors.one_bg,
|
||||
bg = colors.red,
|
||||
},
|
||||
|
||||
18
lua/base46/term.lua
Normal file
18
lua/base46/term.lua
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
local colors = require("base46").get_colors "base_16"
|
||||
|
||||
vim.g.terminal_color_0 = colors.base00
|
||||
vim.g.terminal_color_1 = colors.base08
|
||||
vim.g.terminal_color_2 = colors.base0B
|
||||
vim.g.terminal_color_3 = colors.base0A
|
||||
vim.g.terminal_color_4 = colors.base0D
|
||||
vim.g.terminal_color_5 = colors.base0E
|
||||
vim.g.terminal_color_6 = colors.base0C
|
||||
vim.g.terminal_color_7 = colors.base05
|
||||
vim.g.terminal_color_8 = colors.base03
|
||||
vim.g.terminal_color_9 = colors.base08
|
||||
vim.g.terminal_color_10 = colors.base0B
|
||||
vim.g.terminal_color_11 = colors.base0A
|
||||
vim.g.terminal_color_12 = colors.base0D
|
||||
vim.g.terminal_color_13 = colors.base0E
|
||||
vim.g.terminal_color_14 = colors.base0C
|
||||
vim.g.terminal_color_15 = colors.base07
|
||||
|
|
@ -29,7 +29,7 @@ M.base_30 = {
|
|||
cyan = "#a3b8ef",
|
||||
statusline_bg = "#22262e",
|
||||
lightbg = "#2d3139",
|
||||
pmenu_bg = "#98c379",
|
||||
pmenu_bg = "#61afef",
|
||||
folder_bg = "#61afef",
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue