44 lines
1.6 KiB
Lua
44 lines
1.6 KiB
Lua
return {
|
|
{
|
|
"MeanderingProgrammer/markdown.nvim",
|
|
name = "render-markdown", -- Only needed if you have another plugin named markdown.nvim
|
|
-- 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
|
|
opts = {
|
|
file_types = { 'markdown', 'codecompanion' },
|
|
sign = {
|
|
enabled = false,
|
|
},
|
|
},
|
|
},
|
|
{
|
|
"zk-org/zk-nvim",
|
|
config = function()
|
|
require("zk").setup({
|
|
picker = "select",
|
|
})
|
|
|
|
function MAP(mode, l, r, desc)
|
|
vim.keymap.set(mode, l, r, { desc = desc, silent = true })
|
|
end
|
|
|
|
MAP("n", "<CR>", "<Cmd>lua vim.lsp.buf.definition()<CR>", "Open the link under cursor")
|
|
|
|
MAP("n", "<leader>zn", "<Cmd>ZkNew { dir = vim.fn.expand('%:p:h'), title = vim.fn.input('Title: ') }<CR>",
|
|
"Create new note")
|
|
MAP("v", "<leader>zN",
|
|
":'<,'>ZkNewFromContentSelection { dir = vim.fn.expand('%:p:h'), title = vim.fn.input('Title: ') }<CR>",
|
|
"Create new note using selection as content")
|
|
|
|
MAP("n", "<leader>zl", "<Cmd>ZkInsertLink<CR>", "Insert Link into cursor position")
|
|
MAP("v", "<leader>zl", ":'<,'>ZkInsertLinkAtSelection<CR>", "Insert Link into selection")
|
|
|
|
MAP("n", "<leader>zb", "<Cmd>ZkBacklinks<CR>", "Backlinks")
|
|
MAP("n", "<leader>zo", "<Cmd>ZkLinks<CR>", "Outlinks")
|
|
|
|
MAP("n", "<leader>zf", "<Cmd>ZkNotes<CR>", "Find note")
|
|
MAP("n", "<leader>zt", "<Cmd>ZkTags<CR>", "Find tags")
|
|
end
|
|
}
|
|
}
|