marleyvim/nvim/lua/plugins/ui/dashboard-nvim.lua

61 lines
2.3 KiB
Lua
Raw Normal View History

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,
}