add lualine indicator while recording macros

This commit is contained in:
2024-12-02 14:51:46 -05:00
parent e06507ba2d
commit 7988a28512
+18 -9
View File
@@ -107,18 +107,15 @@ return {
}, },
}, },
lualine_x = { lualine_x = {
-- TODO: macro indicator
{ {
-- spell status -- show status when recording a macro
function() function()
local icon = '󰓆' local reg = vim.fn.reg_recording()
return icon .. ' ' .. vim.fn.toupper(string.sub(vim.bo.spelllang, 1, 2)) if reg == '' then return '' end
return '󰻃 recording to @' .. reg
end, end,
cond = function() cond = custom_components.min_window_width(180),
return vim.wo.spell color = { fg = '#d08770' },
end,
color = { fg = '#ff6a71' },
padding = 1,
}, },
-- TODO: LSP -- TODO: LSP
{ {
@@ -140,6 +137,18 @@ return {
-- return require("auto-session.lib").current_session_name(true) -- return require("auto-session.lib").current_session_name(true)
-- end, -- end,
-- }, -- },
{
-- spell status
function()
local icon = '󰓆'
return icon .. ' ' .. vim.fn.toupper(string.sub(vim.bo.spelllang, 1, 2))
end,
cond = custom_components.min_window_width(120) and function()
return vim.wo.spell
end,
color = { fg = '#81a1c1' },
padding = 1,
},
{ custom_components.encoding, cond = custom_components.min_window_width(190) }, { custom_components.encoding, cond = custom_components.min_window_width(190) },
{ custom_components.fileformat, cond = custom_components.min_window_width(180) }, { custom_components.fileformat, cond = custom_components.min_window_width(180) },
{ 'filetype', cond = custom_components.min_window_width(120) }, { 'filetype', cond = custom_components.min_window_width(120) },