stevearc / dressing.nvim

Neovim plugin to improve the default vim.ui interfaces
MIT License
1.73k stars 32 forks source link

feat: trim trailing colon from prompt #41

Closed axieax closed 2 years ago

axieax commented 2 years ago

2 sentence summary of change

vim.ui.select prompts may have a trailing semicolon which some users may want to remove from floating window displays. This allows them to remove it :D

Context

What is the problem you are trying to solve?

If related to an issue, please link it here. You may omit some background details if it is in the issue.

There may be an unnecessary trailing colon from vim.ui.select prompts when using floating displays.

Description

Describe how the changes add the functionality or fix the issue under "Context"

User can specify whether to automatically trim this trailing colon from select prompts.

Test Plan

list the steps you took to test this functionality. Steps should be reproducible by others.

Adjusting config value trim_prompt with different backends in tests/manual/select.lua (adding a trailing colon to the prompt in line 8).

stevearc commented 2 years ago

LGTM, thanks!