fix(hint): consistent sidebar submit (#205)

Signed-off-by: Aaron Pham <contact@aarnphm.xyz>
This commit is contained in:
Aaron Pham 2024-08-25 00:24:48 -04:00 committed by GitHub
parent 305d972849
commit 80250de7a6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1366,8 +1366,8 @@ function Sidebar:create_input()
local function show_hint() local function show_hint()
close_hint() -- Close the existing hint window close_hint() -- Close the existing hint window
local hint_text = vim.fn.mode() ~= "i" and Config.mappings.submit.normal local hint_text = (vim.fn.mode() ~= "i" and Config.mappings.submit.normal or Config.mappings.submit.insert)
or Config.mappings.submit.insert .. ": submit" .. ": submit"
local buf = api.nvim_create_buf(false, true) local buf = api.nvim_create_buf(false, true)
api.nvim_buf_set_lines(buf, 0, -1, false, { hint_text }) api.nvim_buf_set_lines(buf, 0, -1, false, { hint_text })