spectre.console
spectre.console copied to clipboard
SelectionPrompts not visible in console after selection
Is your feature request related to a problem? Please describe.
When using a SelectionPrompt, the prompt title and selected value don't remain visible in the console after selection.
Describe the solution you'd like Like other prompts, I'd like the title and value to appear in the console for troubleshooting/log retention.
Describe alternatives you've considered Currently, I need to manually print the title and value after selection:
string databaseTitle = $"[{Constants.PROMPT_COLOR}]Database:[/] ";
connectionSettings.DatabaseName = AnsiConsole.Prompt(new SelectionPrompt<string>()
{
Title = databaseTitle
}.AddChoices(databaseNames));
// SelectionPrompts do not appear in console after selection, so print the selected value
AnsiConsole.Markup(databaseTitle + connectionSettings.DatabaseName);
Please upvote :+1: this issue if you are interested in it.