2021-04-23 14:46:45 +00:00
|
|
|
(module plugins.bufferline
|
|
|
|
{require {a aniseed.core
|
|
|
|
fennel aniseed.fennel
|
|
|
|
nvim aniseed.nvim
|
|
|
|
utils utils
|
|
|
|
bufferline bufferline}})
|
|
|
|
|
|
|
|
(local colors (utils.colors))
|
|
|
|
|
|
|
|
; :h bufferline-lua-highlights
|
|
|
|
(let [selected { :guibg colors.neutral_aqua :guifg colors.dark0 :gui ""}
|
|
|
|
visible { :guibg colors.dark1 :guifg colors.neutral_aqua :gui ""}]
|
|
|
|
(bufferline.setup
|
|
|
|
{ :options
|
|
|
|
{ :diagnostics "nvim_lsp"
|
|
|
|
:diagnostics_indicator (fn [cnt lvl diagnostics-dict] (.. " (" cnt ")"))
|
|
|
|
:show_buffer_close_icons false
|
|
|
|
:show_close_icon false
|
|
|
|
:show_tab_indicators false
|
|
|
|
:enforce_regular_tabs false
|
|
|
|
:tab_size 10}
|
|
|
|
|
2021-04-29 20:16:20 +00:00
|
|
|
; https://github.com/akinsho/nvim-bufferline.lua/blob/4ebab39af2376b850724dd29c29579c8e024abe6/lua/bufferline/config.lua#L74
|
2021-04-23 14:46:45 +00:00
|
|
|
:highlights
|
|
|
|
{ :fill { :guibg colors.dark0 :guifg colors.light0}
|
|
|
|
:background visible
|
|
|
|
:buffer_visible visible
|
|
|
|
:buffer_selected selected
|
|
|
|
:modified visible
|
|
|
|
:modified_visible visible
|
|
|
|
:modified_selected selected
|
|
|
|
:error visible
|
|
|
|
:error_selected selected
|
2021-04-29 19:08:05 +00:00
|
|
|
:error_visible selected
|
2021-04-23 14:46:45 +00:00
|
|
|
:warning visible
|
|
|
|
:warning_selected selected
|
|
|
|
:warning_visible visible
|
2021-04-29 20:16:20 +00:00
|
|
|
|
|
|
|
:duplicate visible
|
|
|
|
:duplicate_visible visible
|
|
|
|
:duplicate_selected selected
|
|
|
|
|
2021-04-30 08:23:30 +00:00
|
|
|
:diagnostic { :gui "" :guibg colors.dark1 :guifg colors.neutral_red}
|
|
|
|
:diagnostic_visible { :gui "" :guibg colors.dark1 :guifg colors.neutral_red}
|
|
|
|
:diagnostic_selected { :gui "" :guibg colors.neutral_aqua :guifg colors.faded_red}
|
2021-04-29 20:16:20 +00:00
|
|
|
|
2021-04-30 11:30:39 +00:00
|
|
|
:info_diagnostic { :gui "" :guibg colors.dark1 :guifg colors.neutral_blue}
|
|
|
|
:info_diagnostic_visible { :gui "" :guibg colors.dark1 :guifg colors.neutral_blue}
|
|
|
|
:info_diagnostic_selected { :gui "" :guibg colors.neutral_aqua :guifg colors.faded_blue}
|
2021-04-29 20:16:20 +00:00
|
|
|
|
2021-04-30 08:23:30 +00:00
|
|
|
:warning_diagnostic { :gui "" :guibg colors.dark1 :guifg colors.neutral_yellow}
|
|
|
|
:warning_diagnostic_visible { :gui "" :guibg colors.dark1 :guifg colors.neutral_yellow}
|
|
|
|
:warning_diagnostic_selected { :gui "" :guibg colors.neutral_aqua :guifg colors.faded_yellow}
|
2021-04-29 20:16:20 +00:00
|
|
|
|
2021-04-23 14:46:45 +00:00
|
|
|
:separator visible
|
|
|
|
:indicator_selected {:guibg colors.neutral_aqua :guifg colors.neutral_aqua}
|
|
|
|
|
|
|
|
; stuff I've never seen before :thonk:
|
|
|
|
:pick_selected {:guibg colors.bright_red :guifg colors.bright_red}
|
|
|
|
:tab_selected {:guibg colors.bright_green :guifg colors.bright_green}
|
|
|
|
:tab {:guibg colors.bright_yellow :guifg colors.bright_yellow}}}))
|
|
|
|
|
|
|
|
|
|
|
|
(utils.highlight :BufferLineInfoSelected { :bg colors.neutral_aqua :fg colors.dark0 :gui "NONE"})
|
|
|
|
|