feat: lualine UI improvements

This commit is contained in:
NotAShelf 2023-06-06 01:49:48 +03:00
parent 6e21655c3f
commit 8845d7a54d
No known key found for this signature in database
GPG key ID: F0D14CCB5ED5AA22
2 changed files with 30 additions and 16 deletions

View file

@ -179,6 +179,7 @@ inputs: let
vim.ui = { vim.ui = {
noice.enable = true; noice.enable = true;
colorizer.enable = true; colorizer.enable = true;
modes-nvim.enable = true;
smartcolumn = { smartcolumn = {
enable = true; enable = true;
columnAt.languages = { columnAt.languages = {

View file

@ -6,6 +6,10 @@
with lib; with lib;
with builtins; let with builtins; let
supported_themes = import ./supported_themes.nix; supported_themes = import ./supported_themes.nix;
colorPuccin =
if config.vim.statusline.lualine.theme == "catppuccin"
then "#181825"
else "none";
in { in {
options.vim.statusline.lualine = { options.vim.statusline.lualine = {
enable = mkEnableOption "lualine statusline plugin"; enable = mkEnableOption "lualine statusline plugin";
@ -119,6 +123,7 @@ in {
{ {
{ {
"mode", "mode",
icons_enabled = true,
separator = { separator = {
left = '', left = '',
right = '' right = ''
@ -138,11 +143,11 @@ in {
colored = true, colored = true,
icon_only = true, icon_only = true,
icon = { align = 'left' }, icon = { align = 'left' },
color = {bg='none', fg='lavender'}, color = {bg='${colorPuccin}', fg='lavender'},
}, },
{ {
"filename", "filename",
color = {bg='none'}, color = {bg='${colorPuccin}'},
symbols = {modified = '', readonly = ''}, symbols = {modified = '', readonly = ''},
}, },
} }
@ -165,7 +170,7 @@ in {
}, },
symbols = {added = '+', modified = '~', removed = '-'}, -- Changes the diff symbols symbols = {added = '+', modified = '~', removed = '-'}, -- Changes the diff symbols
color = { color = {
bg='none', bg='${colorPuccin}',
fg='lavender' fg='lavender'
}, },
}, },
@ -181,7 +186,7 @@ in {
{ {
"diagnostics", "diagnostics",
sources = {'nvim_lsp', 'nvim_diagnostic', 'coc'}, sources = {'nvim_lsp', 'nvim_diagnostic', 'coc'},
symbols = {error = '󰅙 ', warn = ' ', info = ' ', hint = '󰌵 '}, symbols = {error = '󰅙 ', warn = ' ', info = ' ', hint = '󰌵 '},
diagnostics_color = { diagnostics_color = {
color_error = { fg = 'red' }, color_error = { fg = 'red' },
color_warn = { fg = 'yellow' }, color_warn = { fg = 'yellow' },
@ -198,13 +203,15 @@ in {
default = '' default = ''
{ {
{ {
"fileformat", 'searchcount',
color = {bg='none', fg='lavender'}, maxcount = 999,
symbols = { timeout = 120,
unix = '', -- e712
dos = '', -- e70f },
mac = '', -- e711 {
}, "branch",
icon = ' ',
color = {bg='${colorPuccin}', fg='lavender'},
}, },
} }
''; '';
@ -217,16 +224,22 @@ in {
{ {
{ {
"progress", "progress",
color = {bg='none', fg='lavender'}, separator = {
left = '',
},
}, },
{ {
"location", "location",
color = {bg='none', fg='lavender'},
}, },
{ {
"branch", "fileformat",
icon = ' ', color = {fg='black'},
color = {bg='none', fg='lavender'}, symbols = {
unix = '', -- e712
dos = '', -- e70f
mac = '', -- e711
},
}, },
} }
''; '';