Remove default mappings from leap, l is now bound to all active windows
This commit is contained in:
parent
11f9c6cbae
commit
d949b834d6
1 changed files with 15 additions and 4 deletions
|
|
@ -1,15 +1,16 @@
|
||||||
return {
|
return {
|
||||||
"ggandor/leap.nvim",
|
"ggandor/leap.nvim",
|
||||||
dependencies = {
|
dependencies = {
|
||||||
"tpope/vim-repeat",
|
"tpope/vim-repeat",
|
||||||
},
|
},
|
||||||
config = function()
|
config = function()
|
||||||
require("leap").create_default_mappings()
|
local leap = require("leap")
|
||||||
|
leap.opts.safe_labels = {}
|
||||||
|
|
||||||
-- Hide the (real) cursor when leaping, and restore it afterwards.
|
-- Hide the (real) cursor when leaping, and restore it afterwards.
|
||||||
vim.api.nvim_create_autocmd(
|
vim.api.nvim_create_autocmd(
|
||||||
"User",
|
"User",
|
||||||
{
|
{
|
||||||
pattern = "LeapEnter",
|
pattern = "LeapEnter",
|
||||||
callback = function()
|
callback = function()
|
||||||
vim.cmd.hi("Cursor", "blend=100")
|
vim.cmd.hi("Cursor", "blend=100")
|
||||||
|
|
@ -27,5 +28,15 @@ return {
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
require("utils").add_keymaps({
|
||||||
|
n = {
|
||||||
|
["l"] = {
|
||||||
|
cmd = function()
|
||||||
|
require("leap").leap({ target_windows = require("leap.user").get_focusable_windows() })
|
||||||
|
end,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
end,
|
end,
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue