Skip to content

Commit 4450b30

Browse files
committed
snacks/picker: move spell suggest to cursor
1 parent 8d042f2 commit 4450b30

File tree

1 file changed

+23
-1
lines changed

1 file changed

+23
-1
lines changed

modules/nixvim/plugins/snacks/picker.nix

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,29 @@
260260
{
261261
mode = "n";
262262
key = "<leader>fS";
263-
action = ''<cmd>lua Snacks.picker.spelling()<cr>'';
263+
action.__raw = ''
264+
function()
265+
Snacks.picker.spelling({
266+
layout = {
267+
preview =false,
268+
layout = {
269+
relative = 'cursor',
270+
width = 70,
271+
min_width = 0,
272+
min_height = 0,
273+
row = 1,
274+
backdrop = false,
275+
width = 0.4,
276+
height = 0.4,
277+
box = "vertical",
278+
{ win = "input", height = 1, border = "rounded", title = "{title} {live} {flags}", title_pos = "center" },
279+
{ win = "list", border = "rounded" },
280+
{ win = "preview", title = "{preview}", border = "rounded" }
281+
}
282+
}
283+
})
284+
end
285+
'';
264286
options = {
265287
desc = "Find spelling suggestions";
266288
};

0 commit comments

Comments
 (0)