nvim/lua/plugins/markdown.lua.bak

129 lines
5.1 KiB
Lua

return {
"MeanderingProgrammer/render-markdown.nvim",
opts = {},
-- dependencies = { "nvim-treesitter/nvim-treesitter", "echasnovski/mini.nvim" }, -- if you use the mini.nvim suite
-- dependencies = { 'nvim-treesitter/nvim-treesitter', 'echasnovski/mini.icons' }, -- if you use standalone mini plugins
dependencies = { "nvim-treesitter/nvim-treesitter", "nvim-tree/nvim-web-devicons" }, -- if you prefer nvim-web-devicons
config = function()
vim.opt.conceallevel = 2
require("render-markdown").setup({
heading = {
-- Turn on / off heading icon & background rendering
enabled = true,
-- Turn on / off any sign column related rendering
sign = true,
-- Determines how icons fill the available space:
-- inline: underlying '#'s are concealed resulting in a left aligned icon
-- overlay: result is left padded with spaces to hide any additional '#'
position = "overlay",
-- Replaces '#+' of 'atx_h._marker'
-- The number of '#' in the heading determines the 'level'
-- The 'level' is used to index into the array using a cycle
icons = { "󰲡 ", "󰲣 ", "󰲥 ", "󰲧 ", "󰲩 ", "󰲫 " },
-- Added to the sign column if enabled
-- The 'level' is used to index into the array using a cycle
signs = { "󰫎 " },
-- Width of the heading background:
-- block: width of the heading text
-- full: full width of the window
-- Can also be an array of the above values in which case the 'level' is used
-- to index into the array using a clamp
width = "full",
-- Amount of padding to add to the left of headings
left_pad = 0,
-- Amount of padding to add to the right of headings when width is 'block'
right_pad = 0,
-- Minimum width to use for headings when width is 'block'
min_width = 0,
-- Determins if a border is added above and below headings
border = false,
-- Highlight the start of the border using the foreground highlight
border_prefix = false,
-- Used above heading for border
above = "",
-- Used below heading for border
below = "",
-- The 'level' is used to index into the array using a clamp
-- Highlight for the heading icon and extends through the entire line
backgrounds = {
"RenderMarkdownH1Bg",
"RenderMarkdownH2Bg",
"RenderMarkdownH3Bg",
"RenderMarkdownH4Bg",
"RenderMarkdownH5Bg",
"RenderMarkdownH6Bg",
},
-- The 'level' is used to index into the array using a clamp
-- Highlight for the heading and sign icons
foregrounds = {
"RenderMarkdownH1",
"RenderMarkdownH2",
"RenderMarkdownH3",
"RenderMarkdownH4",
"RenderMarkdownH5",
"RenderMarkdownH6",
},
},
-- require("render-markdown").setup({
-- heading = {
-- -- Turn on / off heading icon & background rendering
-- enabled = true,
-- -- Turn on / off any sign column related rendering
-- sign = true,
-- -- Determines how icons fill the available space:
-- -- inline: underlying '#'s are concealed resulting in a left aligned icon
-- -- overlay: result is left padded with spaces to hide any additional '#'
-- position = "overlay",
-- -- Replaces '#+' of 'atx_h._marker'
-- -- The number of '#' in the heading determines the 'level'
-- -- The 'level' is used to index into the array using a cycle
-- icons = { "󰲡 ", "󰲣 ", "󰲥 ", "󰲧 ", "󰲩 ", "󰲫 " },
-- -- Added to the sign column if enabled
-- -- The 'level' is used to index into the array using a cycle
-- signs = { "󰫎 " },
-- -- Width of the heading background:
-- -- block: width of the heading text
-- -- full: full width of the window
-- -- Can also be an array of the above values in which case the 'level' is used
-- -- to index into the array using a clamp
-- width = "full",
-- -- Amount of padding to add to the left of headings
-- left_pad = 0,
-- -- Amount of padding to add to the right of headings when width is 'block'
-- right_pad = 0,
-- -- Minimum width to use for headings when width is 'block'
-- min_width = 0,
-- -- Determins if a border is added above and below headings
-- border = false,
-- -- Highlight the start of the border using the foreground highlight
-- border_prefix = false,
-- -- Used above heading for border
-- above = "▄",
-- -- Used below heading for border
-- below = "▀",
-- -- The 'level' is used to index into the array using a clamp
-- -- Highlight for the heading icon and extends through the entire line
-- backgrounds = {
-- "RenderMarkdownH1Bg",
-- "RenderMarkdownH2Bg",
-- "RenderMarkdownH3Bg",
-- "RenderMarkdownH4Bg",
-- "RenderMarkdownH5Bg",
-- "RenderMarkdownH6Bg",
-- },
-- -- The 'level' is used to index into the array using a clamp
-- -- Highlight for the heading and sign icons
-- foregrounds = {
-- "RenderMarkdownH1",
-- "RenderMarkdownH2",
-- "RenderMarkdownH3",
-- "RenderMarkdownH4",
-- "RenderMarkdownH5",
-- "RenderMarkdownH6",
-- },
-- },
-- }),
})
end,
}