mirror of
https://github.com/neovim/neovim.git
synced 2025-11-26 20:20:42 +00:00
feat(ui): more intuitive :substitute confirm prompt #31787
Problem: Unknown key mappings listed in substitute confirm message. Solution: Include hints as to what the key mappings do.
This commit is contained in:
@@ -220,8 +220,10 @@ describe(':substitute', function()
|
||||
{2:o}ne |
|
||||
two |
|
||||
three |
|
||||
{1:~ }|*4
|
||||
{6:replace with (y/n/a/q/l/^E/^Y)?}^ |
|
||||
{1:~ }|*2
|
||||
{3: }|
|
||||
{6:replace with ? (y)es/(n)o/(a)ll/(q)uit/(l)ast/scroll up(^}|
|
||||
{6:E)/down(^Y)}^ |
|
||||
]])
|
||||
end)
|
||||
end)
|
||||
|
||||
@@ -1485,10 +1485,10 @@ describe('cmdheight=0', function()
|
||||
it('when substitute text', function()
|
||||
command('set cmdheight=0 noruler laststatus=3')
|
||||
feed('ifoo<ESC>')
|
||||
screen:try_resize(screen._width, 6)
|
||||
screen:try_resize(screen._width, 7)
|
||||
screen:expect([[
|
||||
fo^o |
|
||||
{1:~ }|*4
|
||||
{1:~ }|*5
|
||||
{3:[No Name] [+] }|
|
||||
]])
|
||||
|
||||
@@ -1497,14 +1497,15 @@ describe('cmdheight=0', function()
|
||||
{2:foo} |
|
||||
{3: }|
|
||||
|*2
|
||||
{6:replace with bar (y/n/a/q}|
|
||||
{6:/l/^E/^Y)?}^ |
|
||||
{6:replace with bar? (y)es/(}|
|
||||
{6:n)o/(a)ll/(q)uit/(l)ast/s}|
|
||||
{6:croll up(^E)/down(^Y)}^ |
|
||||
]])
|
||||
|
||||
feed('y')
|
||||
screen:expect([[
|
||||
^bar |
|
||||
{1:~ }|*4
|
||||
{1:~ }|*5
|
||||
{3:[No Name] [+] }|
|
||||
]])
|
||||
|
||||
|
||||
@@ -141,7 +141,7 @@ describe('ui/ext_messages', function()
|
||||
content = { { '' } },
|
||||
hl_id = 18,
|
||||
pos = 0,
|
||||
prompt = 'replace with X (y/n/a/q/l/^E/^Y)?',
|
||||
prompt = 'replace with X? (y)es/(n)o/(a)ll/(q)uit/(l)ast/scroll up(^E)/down(^Y)',
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user