Nvim: filter empty lines
This commit is contained in:
parent
b686925732
commit
f813d66d47
@ -121,7 +121,7 @@ endfunction
|
||||
" Function: #popup_create {{{1
|
||||
function! sy#util#popup_create(hunkdiff) abort
|
||||
let max_height = winheight('%') - winline()
|
||||
let height = len(a:hunkdiff)
|
||||
let height = len(filter(a:hunkdiff, {_,v -> !empty(v)}))
|
||||
let height = (height > max_height) ? max_height : height
|
||||
let offset = s:offset()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user