feat(nvim/alpha): update dashboard to match lazyvim mostly

This commit is contained in:
Michael Thomas 2024-06-13 01:23:24 +02:00
parent 4281afe9cf
commit 7908f337e3

View File

@ -8,35 +8,37 @@
type = "padding";
inherit val;
};
shortcutOpts = {
position = "center";
cursor = 3;
width = 50;
align_shortcut = "right";
};
in [
(padding 4)
(padding 8)
{
opts = {
hl = "AlphaHeader";
hl = "Structure";
position = "center";
};
type = "text";
val = [
" "
" "
" "
" "
" "
" "
" "
" "
" "
" "
" git@github.com:redyf "
" "
" "
" "
" "
" "
" "
];
}
(padding 2)
(padding 3)
{
type = "button";
val = " Find File";
on_press.raw = "require('telescope.builtin').find_files";
opts = {
# hl = "comment";
opts =
shortcutOpts
// {
keymap = [
"n"
"f"
@ -48,12 +50,6 @@
}
];
shortcut = "f";
position = "center";
cursor = 3;
width = 38;
align_shortcut = "right";
hl_shortcut = "Keyword";
};
}
(padding 1)
@ -61,8 +57,9 @@
type = "button";
val = " New File";
on_press.__raw = "function() vim.cmd[[ene]] end";
opts = {
# hl = "comment";
opts =
shortcutOpts
// {
keymap = [
"n"
"n"
@ -74,12 +71,6 @@
}
];
shortcut = "n";
position = "center";
cursor = 3;
width = 38;
align_shortcut = "right";
hl_shortcut = "Keyword";
};
}
(padding 1)
@ -87,8 +78,9 @@
type = "button";
val = "󰈚 Recent Files";
on_press.raw = "require('telescope.builtin').oldfiles";
opts = {
# hl = "comment";
opts =
shortcutOpts
// {
keymap = [
"n"
"r"
@ -100,12 +92,6 @@
}
];
shortcut = "r";
position = "center";
cursor = 3;
width = 38;
align_shortcut = "right";
hl_shortcut = "Keyword";
};
}
(padding 1)
@ -113,8 +99,9 @@
type = "button";
val = "󰈭 Find Word";
on_press.raw = "require('telescope.builtin').live_grep";
opts = {
# hl = "comment";
opts =
shortcutOpts
// {
keymap = [
"n"
"g"
@ -126,12 +113,6 @@
}
];
shortcut = "g";
position = "center";
cursor = 3;
width = 38;
align_shortcut = "right";
hl_shortcut = "Keyword";
};
}
(padding 1)
@ -139,8 +120,9 @@
type = "button";
val = " Restore Session";
on_press.raw = "require('persistence').load()";
opts = {
# hl = "comment";
opts =
shortcutOpts
// {
keymap = [
"n"
"s"
@ -152,21 +134,16 @@
}
];
shortcut = "s";
position = "center";
cursor = 3;
width = 38;
align_shortcut = "right";
hl_shortcut = "Keyword";
};
}
(padding 1)
{
type = "button";
val = " Quit Neovim";
val = " Quit";
on_press.__raw = "function() vim.cmd[[qa]] end";
opts = {
# hl = "comment";
opts =
shortcutOpts
// {
keymap = [
"n"
"q"
@ -178,12 +155,6 @@
}
];
shortcut = "q";
position = "center";
cursor = 3;
width = 38;
align_shortcut = "right";
hl_shortcut = "Keyword";
};
}
];