mirror of
https://github.com/nsnail/spectre.console.git
synced 2025-06-19 21:38:16 +08:00

committed by
Phil Scott

parent
9502aaf2b9
commit
c2bab0ebf8
@ -44,6 +44,16 @@ namespace Spectre.Console
|
||||
/// </summary>
|
||||
public Style? HighlightStyle { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the text that will be displayed if there are more choices to show.
|
||||
/// </summary>
|
||||
public string? MoreChoicesText { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets the text that instructs the user of how to select items.
|
||||
/// </summary>
|
||||
public string? InstructionsText { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets a value indicating whether or not
|
||||
/// at least one selection is required.
|
||||
@ -77,8 +87,11 @@ namespace Spectre.Console
|
||||
}
|
||||
|
||||
var converter = Converter ?? TypeConverterHelper.ConvertToString;
|
||||
var list = new RenderableMultiSelectionList<T>(
|
||||
console, Title, PageSize, Choices,
|
||||
Selected, converter, HighlightStyle,
|
||||
MoreChoicesText, InstructionsText);
|
||||
|
||||
var list = new RenderableMultiSelectionList<T>(console, Title, PageSize, Choices, Selected, converter, HighlightStyle);
|
||||
using (new RenderHookScope(console, list))
|
||||
{
|
||||
console.Cursor.Hide();
|
||||
|
Reference in New Issue
Block a user