feat(treesitter-content): highlight line number (#709)

* fix:(treesitter-content): respect transparency

* chore: format

---------

Co-authored-by: Myles Mo <mylesmo.ash@gmail.com>
Co-authored-by: mrtnvgr <root@unixis.fun>
This commit is contained in:
Myles Mo 2024-05-26 14:22:31 +08:00 committed by GitHub
parent d97387aea8
commit 4edca6bed2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1,18 +1,21 @@
local M = {}
function M.get()
return O.transparent_background and {
TreesitterContextBottom = { sp = C.dim, style = { "underline" } },
} or {
TreesitterContextBottom = {
sp = C.surface0,
style = { "underline" },
},
TreesitterContextLineNumber = {
fg = C.surface1,
bg = C.mantle,
},
}
return O.transparent_background
and {
TreesitterContextBottom = { sp = C.dim, style = { "underline" } },
TreesitterContextLineNumber = { fg = C.rosewater },
}
or {
TreesitterContextBottom = {
sp = C.surface0,
style = { "underline" },
},
TreesitterContextLineNumber = {
fg = C.surface1,
bg = C.mantle,
},
}
end
return M