refactor: nvim
This commit is contained in:
38
nvim/lua/plugins/diagram.lua
Normal file
38
nvim/lua/plugins/diagram.lua
Normal file
@@ -0,0 +1,38 @@
|
||||
return {
|
||||
"3rd/diagram.nvim",
|
||||
event = 'BufEnter',
|
||||
opts = { -- you can just pass {}, defaults below
|
||||
events = {
|
||||
render_buffer = { "InsertLeave", "BufWinEnter", "TextChanged" },
|
||||
clear_buffer = {"BufLeave"},
|
||||
},
|
||||
renderer_options = {
|
||||
mermaid = {
|
||||
background = "transparent", -- nil | "transparent" | "white" | "#hex"
|
||||
theme = "dark", -- nil | "default" | "dark" | "forest" | "neutral"
|
||||
scale = 1, -- nil | 1 (default) | 2 | 3 | ...
|
||||
width = nil, -- nil | 800 | 400 | ...
|
||||
height = nil, -- nil | 600 | 300 | ...
|
||||
cli_args = nil, -- nil | { "--no-sandbox" } | { "-p", "/path/to/puppeteer" } | ...
|
||||
},
|
||||
plantuml = {
|
||||
charset = nil,
|
||||
cli_args = nil, -- nil | { "-Djava.awt.headless=true" } | ...
|
||||
},
|
||||
d2 = {
|
||||
theme_id = nil,
|
||||
dark_theme_id = nil,
|
||||
scale = nil,
|
||||
layout = nil,
|
||||
sketch = nil,
|
||||
cli_args = nil, -- nil | { "--pad", "0" } | ...
|
||||
},
|
||||
gnuplot = {
|
||||
size = nil, -- nil | "800,600" | ...
|
||||
font = nil, -- nil | "Arial,12" | ...
|
||||
theme = nil, -- nil | "light" | "dark" | custom theme string
|
||||
cli_args = nil, -- nil | { "-p" } | { "-c", "config.plt" } | ...
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
20
nvim/lua/plugins/dynomark.lua
Normal file
20
nvim/lua/plugins/dynomark.lua
Normal file
@@ -0,0 +1,20 @@
|
||||
return {{
|
||||
"k-lar/dynomark.nvim",
|
||||
dependencies = "nvim-treesitter/nvim-treesitter",
|
||||
event = 'BufEnter',
|
||||
opts = { -- Default values
|
||||
remap_arrows = false,
|
||||
results_view_location = "vertical", -- Can be "float", "tab", "vertical" or "horizontal"
|
||||
|
||||
-- This is only used when results_view_location is "float"
|
||||
-- By default the window is placed in the upper right of the window
|
||||
-- If you want to have the window centered, set both offsets to 0.0
|
||||
float_horizontal_offset = 0.2,
|
||||
float_vertical_offset = 0.2,
|
||||
|
||||
-- Turn this to true if you want the plugin to automatically download
|
||||
-- the dynomark engine if it's not found in your PATH.
|
||||
-- This is false by default!
|
||||
auto_download = true,
|
||||
},
|
||||
}}
|
||||
@@ -1,6 +1,6 @@
|
||||
return {
|
||||
"3rd/image.nvim",
|
||||
-- event = 'BufEnter',
|
||||
event = 'BufEnter',
|
||||
build = false, -- so that it doesn't build the rock https://github.com/3rd/image.nvim/issues/91#issuecomment-2453430239
|
||||
config = function()
|
||||
require("image").setup({
|
||||
@@ -11,7 +11,7 @@ return {
|
||||
enabled = true,
|
||||
clear_in_insert_mode = true,
|
||||
download_remote_images = true,
|
||||
only_render_image_at_cursor = false,
|
||||
only_render_image_at_cursor = true,
|
||||
only_render_image_at_cursor_mode = "popup",
|
||||
floating_windows = false, -- if true, images will be rendered in floating markdown windows
|
||||
filetypes = { "markdown", "vimwiki" }, -- markdown extensions (ie. quarto) can go here
|
||||
|
||||
27
nvim/lua/plugins/zk.lua
Normal file
27
nvim/lua/plugins/zk.lua
Normal file
@@ -0,0 +1,27 @@
|
||||
return {
|
||||
"zk-org/zk-nvim",
|
||||
event = 'BufEnter',
|
||||
config = function()
|
||||
require("zk").setup({
|
||||
-- Can be "telescope", "fzf", "fzf_lua", "minipick", "snacks_picker",
|
||||
-- or select" (`vim.ui.select`).
|
||||
picker = "telescope",
|
||||
|
||||
lsp = {
|
||||
-- `config` is passed to `vim.lsp.start(config)`
|
||||
config = {
|
||||
name = "zk",
|
||||
cmd = { "zk", "lsp" },
|
||||
filetypes = { "markdown" },
|
||||
-- on_attach = ...
|
||||
-- etc, see `:h vim.lsp.start()`
|
||||
},
|
||||
|
||||
-- automatically attach buffers in a zk notebook that match the given filetypes
|
||||
auto_attach = {
|
||||
enabled = true,
|
||||
},
|
||||
},
|
||||
})
|
||||
end,
|
||||
}
|
||||
Reference in New Issue
Block a user