fix(nvim): obsidian plugin removed the callbacks table

This commit is contained in:
Sergio Laín 2025-06-29 13:57:57 +02:00
parent 28545dbb8e
commit 04daca30a9
No known key found for this signature in database
GPG key ID: 51BB28D8B42FB438

View file

@ -65,25 +65,15 @@ return {
},
},
mappings = {
["gf"] = {
action = function()
return require("obsidian").util.gf_passthrough()
end,
opts = { noremap = false, expr = true, buffer = true },
},
["<C-c>"] = {
action = function()
return require("obsidian").util.toggle_checkbox()
end,
opts = { buffer = true },
},
["<cr>"] = {
action = function()
return require("obsidian").util.smart_action()
end,
opts = { buffer = true, expr = true },
},
callbacks = {
enter_note = function(_, note)
vim.keymap.set("n", "gf", "<cmd>ObsidianFollowLink<cr>", {
buffer = note.bufnr,
expr = note.expr,
noremap = note.noremap,
desc = "File Passthrough",
})
end,
},
new_notes_location = "notes_subdir",