From 8f4d72c8472102e4aaeff35d92bcf86af841f862 Mon Sep 17 00:00:00 2001 From: Price Hiller Date: Fri, 19 Jul 2024 09:00:24 -0500 Subject: [PATCH] refactor(nvim): remove close button for bufferline --- .../nvim/lua/plugins/configs/heirline.lua | 32 ------------------- 1 file changed, 32 deletions(-) diff --git a/users/price/dots/.config/nvim/lua/plugins/configs/heirline.lua b/users/price/dots/.config/nvim/lua/plugins/configs/heirline.lua index 033bb87c..dc6e5cf2 100644 --- a/users/price/dots/.config/nvim/lua/plugins/configs/heirline.lua +++ b/users/price/dots/.config/nvim/lua/plugins/configs/heirline.lua @@ -396,37 +396,6 @@ return { StatusLineFileFlags, } - -- a nice "x" button to close the buffer - local StatusLineCloseButton = { - condition = function() - return not vim.bo.modified - end, - { - provider = " 󰅙 ", - hl = function(self) - local fg = colors.peachRed - local bg = buffer_hl.active.bg - if not self.is_active then - fg = colors.autumnRed - bg = buffer_hl.inactive.bg - end - return { fg = fg, bg = bg } - end, - on_click = { - callback = function(_, minwid) - vim.schedule(function() - vim.api.nvim_buf_delete(minwid, { force = false }) - vim.cmd.redrawtabline() - end) - end, - minwid = function(self) - return self.bufnr - end, - name = "heirline_tabline_close_buffer_callback", - }, - }, - } - -- The final touch! local StatusLineBufferBlock = { { @@ -442,7 +411,6 @@ return { end, }, StatusLineFileNameBlock, - StatusLineCloseButton, { provider = seps.full.right, hl = function(self)