all repos

init.lua @ a39a64f

my nvim config
4 files changed, 35 insertions(+), 2 deletions(-)
feat: image support for markdown and update conceal setup for it
Author: Smirnov Oleksandr ss2316544@gmail.com
Committed at: 2024-12-18 16:43:22 +0200
Parent: 067490b
M lua/core/autocmd.lua

@@ -47,3 +47,12 @@ "1", -- don't break a line after a one-letter word

} end, }) + +u.aucmd("FileType", { + group = u.augroup "concealer", + pattern = { "markdown", "org" }, + callback = function() + vim.opt.conceallevel = 2 + vim.opt.concealcursor = "cv" + end, +})
M lua/core/options.lua

@@ -39,8 +39,6 @@ vim.o.hidden = true

vim.o.title = true vim.o.linebreak = true vim.o.wrap = false -vim.o.conceallevel = 2 -vim.o.concealcursor = 'cv' -- listchars vim.o.list = true
M lua/plugins/core.lua

@@ -46,4 +46,17 @@ "pmizio/typescript-tools.nvim",

ft = { "typescript" }, opts = {}, }, + { + "3rd/image.nvim", + ft = { "markdown" }, + opts = { + max_height_window_percentage = 65, + integrations = { + markdown = { + only_render_image_at_cursor = true, + clear_in_insert_mode = true, + }, + }, + }, + }, }
A queries/markdown_inline/highlights.scm

@@ -0,0 +1,13 @@

+(image + ["!"] @markup.link + (#set! conceal "🖼️ ")) + +(image + [ + "[" + "]" + "(" + (link_destination) + ")" + ] @markup.link + (#set! conceal ""))