change cmp complete and selection behavior
This commit is contained in:
parent
8d05aab071
commit
018c95dbd3
|
@ -20,27 +20,18 @@
|
||||||
'';
|
'';
|
||||||
# cmp mappings declaration
|
# cmp mappings declaration
|
||||||
mapping = {
|
mapping = {
|
||||||
"<C-s>" =
|
"<esc>" =
|
||||||
# Lua
|
|
||||||
"cmp.mapping.scroll_docs(-4)";
|
|
||||||
"<C-t>" =
|
|
||||||
# Lua
|
|
||||||
"cmp.mapping.scroll_docs(4)";
|
|
||||||
"<C-Space>" =
|
|
||||||
# Lua
|
|
||||||
"cmp.mapping.complete()";
|
|
||||||
"<C-esc>" =
|
|
||||||
# Lua
|
# Lua
|
||||||
"cmp.mapping.close()";
|
"cmp.mapping.close()";
|
||||||
"<Tab>" =
|
"<Down>" =
|
||||||
# Lua
|
# Lua
|
||||||
"cmp.mapping(cmp.mapping.select_next_item({behavior = cmp.SelectBehavior.Select}), {'i', 's'})";
|
"cmp.mapping(cmp.mapping.select_next_item({behavior = cmp.SelectBehavior.Select}), {'i', 's'})";
|
||||||
"<S-Tab>" =
|
"<Up>" =
|
||||||
# Lua
|
# Lua
|
||||||
"cmp.mapping(cmp.mapping.select_prev_item({behavior = cmp.SelectBehavior.Select}), {'i', 's'})";
|
"cmp.mapping(cmp.mapping.select_prev_item({behavior = cmp.SelectBehavior.Select}), {'i', 's'})";
|
||||||
"<CR>" =
|
"<Tab>" =
|
||||||
# Lua
|
# Lua
|
||||||
"cmp.mapping.confirm({ select = false, behavior = cmp.ConfirmBehavior.Replace })";
|
"cmp.mapping.confirm({ select = true, behavior = cmp.ConfirmBehavior.Replace })";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
# Scans the sources array and enable the corresponding plugins if they are known to nixvim.
|
# Scans the sources array and enable the corresponding plugins if they are known to nixvim.
|
||||||
|
|
Loading…
Reference in a new issue