chore(keymaps): add toggle options (#204)
Signed-off-by: Aaron Pham <contact@aarnphm.xyz>
This commit is contained in:
@@ -43,6 +43,25 @@ end
|
||||
H.keymaps = function()
|
||||
vim.keymap.set({ "n", "v" }, Config.mappings.ask, M.toggle, { noremap = true })
|
||||
vim.keymap.set("n", Config.mappings.refresh, M.refresh, { noremap = true })
|
||||
|
||||
Utils.toggle_map("n", Config.mappings.toggle.debug, {
|
||||
name = "debug",
|
||||
get = function()
|
||||
return Config.debug
|
||||
end,
|
||||
set = function(state)
|
||||
Config.override({ debug = state })
|
||||
end,
|
||||
})
|
||||
Utils.toggle_map("n", Config.mappings.toggle.hint, {
|
||||
name = "hint",
|
||||
get = function()
|
||||
return Config.hints.enabled
|
||||
end,
|
||||
set = function(state)
|
||||
Config.override({ hints = { enabled = state } })
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
H.autocmds = function()
|
||||
|
||||
Reference in New Issue
Block a user