Add obsidian nvim plugin templates and daily notes. Remove blink toggle.
This commit is contained in:
@@ -1,26 +0,0 @@
|
||||
return {
|
||||
"saghen/blink.cmp",
|
||||
opts = function(_, opts)
|
||||
local completion_toggle = Snacks.toggle({
|
||||
name = "Completion",
|
||||
get = function()
|
||||
return vim.b.completion
|
||||
end,
|
||||
set = function(state)
|
||||
vim.b.completion = state
|
||||
end,
|
||||
})
|
||||
|
||||
local function toggle_completion()
|
||||
require("blink.cmp").hide()
|
||||
completion_toggle:toggle()
|
||||
end
|
||||
|
||||
vim.keymap.set({ "i", "n" }, "<C-Space>", toggle_completion, { desc = "Toggle Completion" })
|
||||
opts.enabled = function()
|
||||
return vim.b.completion
|
||||
end
|
||||
|
||||
return opts
|
||||
end,
|
||||
}
|
||||
@@ -34,6 +34,27 @@ return {
|
||||
min_chars = 4,
|
||||
},
|
||||
|
||||
daily_notes = {
|
||||
-- Optional, if you keep daily notes in a separate directory.
|
||||
folder = "0. Daily Notes",
|
||||
-- Optional, if you want to change the date format for the ID of daily notes.
|
||||
date_format = "%Y.%m.%d",
|
||||
-- Optional, if you workant to change the date format of the default alias of daily notes.
|
||||
alias_format = "%B %-d, %Y",
|
||||
-- Optional, default tags to add to each new daily note created.
|
||||
default_tags = { "daily-notes" },
|
||||
-- Optional, if you want to automatically insert a template from your template directory like 'daily.md'
|
||||
template = "98. Templates/Daily Note",
|
||||
},
|
||||
|
||||
templates = {
|
||||
folder = "98. Templates",
|
||||
date_format = "YYYY.MM.DD",
|
||||
time_format = "HHMM",
|
||||
-- A map for custom variables, the key should be the variable and the value a function
|
||||
substitutions = {},
|
||||
},
|
||||
|
||||
-- Optional, configure key mappings. These are the defaults. If you don't want to set any keymappings this
|
||||
-- way then set 'mappings = {}'.
|
||||
mappings = {
|
||||
|
||||
Reference in New Issue
Block a user