Skip to content

Commit

Permalink
feat: add peek function
Browse files Browse the repository at this point in the history
  • Loading branch information
willothy committed Dec 29, 2023
1 parent 7eb18cf commit 7851c33
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion lua/precognition/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,14 @@ end

--- Show the hints until the next keypress or CursorMoved event
function M.peek()
error("not implemented")
on_cursor_hold()

vim.api.nvim_create_autocmd({ "CursorMoved", "InsertEnter", "BufLeave" }, {
buffer = vim.api.nvim_get_current_buf(),
once = true,
group = au,
callback = on_buf_leave,
})
end

--- Enable automatic showing of hints
Expand Down

0 comments on commit 7851c33

Please sign in to comment.