fix(markdown): create default numbered Headline groups for colorschemes that dont support them. Fixes #1822

This commit is contained in:
Folke Lemaitre committed 2023-10-25 14:23:44 +02:00
1 parent c400cf0014
commit eab464d52d
1 file changed
+6 -2
+6 -2
View File
@@ -67,9 +67,13 @@ return {
opts = function()
local opts = {}
for _, ft in ipairs({ "markdown", "norg", "rmd", "org" }) do
opts[ft] = { headline_highlights = {} }
opts[ft] = {
headline_highlights = {},
}
for i = 1, 6 do
table.insert(opts[ft].headline_highlights, "Headline" .. i)
local hl = "Headline" .. i
vim.api.nvim_set_hl(0, hl, { link = "Headline", default = true })
table.insert(opts[ft].headline_highlights, hl)
end
end
return opts