neoclide / coc.nvim

Nodejs extension host for vim & neovim, load extensions like VSCode and host language servers.
Other
24.37k stars 956 forks source link

FIx `opts.close` for `window.showDialog` #4835

Closed gera2ld closed 9 months ago

gera2ld commented 9 months ago

Currently if close: false is passed, it won't be set to opts.

https://github.com/neoclide/coc.nvim/blob/e10877749538a9875e359abe69974b0d0ca697ca/src/model/dialog.ts#L97

As a result, coc#dialog#create_dialog will consider opts.close not set and use 1 as a fallback.

https://github.com/neoclide/coc.nvim/blob/e10877749538a9875e359abe69974b0d0ca697ca/autoload/coc/dialog.vim#L300

This PR makes sure opts.close = 0 is properly set.

codecov[bot] commented 9 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (e108777) 98.64% compared to head (ab5650e) 98.64%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #4835 +/- ## ======================================= Coverage 98.64% 98.64% ======================================= Files 273 273 Lines 25981 25981 Branches 5390 5390 ======================================= + Hits 25628 25630 +2 + Misses 204 202 -2 Partials 149 149 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.