feat: dashboard.nvim
Might switch to alpha tho
This commit is contained in:
parent
75a8915db4
commit
bb0181bd7a
4 changed files with 67 additions and 0 deletions
|
@ -35,6 +35,7 @@ with final.pkgs.lib; let
|
||||||
|
|
||||||
# UI
|
# UI
|
||||||
mini-icons
|
mini-icons
|
||||||
|
dashboard-nvim
|
||||||
bufferline-nvim
|
bufferline-nvim
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -5,4 +5,9 @@ return {
|
||||||
Hint = ' ',
|
Hint = ' ',
|
||||||
Info = ' ',
|
Info = ' ',
|
||||||
},
|
},
|
||||||
|
dashboard = {
|
||||||
|
quit = '',
|
||||||
|
mru = '',
|
||||||
|
project = '',
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
60
nvim/lua/plugins/ui/dashboard-nvim.lua
Normal file
60
nvim/lua/plugins/ui/dashboard-nvim.lua
Normal file
|
@ -0,0 +1,60 @@
|
||||||
|
return {
|
||||||
|
'dashboard-nvim',
|
||||||
|
event = 'VimEnter',
|
||||||
|
before = function()
|
||||||
|
require('lz.n').trigger_load('mini.icons')
|
||||||
|
end,
|
||||||
|
after = function()
|
||||||
|
local icons = require('icons').dashboard
|
||||||
|
|
||||||
|
local title = [[
|
||||||
|
███╗ ███╗ █████╗ ██████╗ ██╗ ███████╗██╗ ██╗██╗ ██╗██╗███╗ ███╗
|
||||||
|
████╗ ████║██╔══██╗██╔══██╗██║ ██╔════╝╚██╗ ██╔╝██║ ██║██║████╗ ████║
|
||||||
|
██╔████╔██║███████║██████╔╝██║ █████╗ ╚████╔╝ ██║ ██║██║██╔████╔██║
|
||||||
|
██║╚██╔╝██║██╔══██║██╔══██╗██║ ██╔══╝ ╚██╔╝ ╚██╗ ██╔╝██║██║╚██╔╝██║
|
||||||
|
██║ ╚═╝ ██║██║ ██║██║ ██║███████╗███████╗ ██║ ╚████╔╝ ██║██║ ╚═╝ ██║
|
||||||
|
╚═╝ ╚═╝╚═╝ ╚═╝╚═╝ ╚═╝╚══════╝╚══════╝ ╚═╝ ╚═══╝ ╚═╝╚═╝ ╚═╝
|
||||||
|
]]
|
||||||
|
|
||||||
|
title = string.rep('\n', 8) .. title .. '\n\n'
|
||||||
|
|
||||||
|
require('dashboard').setup({
|
||||||
|
theme = 'hyper',
|
||||||
|
shortcut_type = 'number',
|
||||||
|
change_to_vcs_root = true,
|
||||||
|
hide = {
|
||||||
|
-- This is taken care of by Lualine.
|
||||||
|
statusline = false,
|
||||||
|
tabline = true,
|
||||||
|
},
|
||||||
|
|
||||||
|
config = {
|
||||||
|
header = vim.split(title, '\n'),
|
||||||
|
|
||||||
|
shortcut = {
|
||||||
|
{
|
||||||
|
icon = icons.quit .. ' ',
|
||||||
|
desc = 'Quit',
|
||||||
|
key = 'q',
|
||||||
|
action = function()
|
||||||
|
vim.api.nvim_input('<CMD>qa<CR>')
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
mru = {
|
||||||
|
enable = true,
|
||||||
|
limit = 5,
|
||||||
|
icon = icons.mru .. ' ',
|
||||||
|
label = 'Files',
|
||||||
|
},
|
||||||
|
project = {
|
||||||
|
enable = true,
|
||||||
|
limit = 5,
|
||||||
|
icon = icons.project .. ' ',
|
||||||
|
label = 'Projects',
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
end,
|
||||||
|
}
|
|
@ -2,5 +2,6 @@ local req = require('lib.marleyvim').localRequire('plugins.ui')
|
||||||
|
|
||||||
return {
|
return {
|
||||||
req('bufferline-nvim'),
|
req('bufferline-nvim'),
|
||||||
|
req('dashboard-nvim'),
|
||||||
req('mini-icons'),
|
req('mini-icons'),
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue