Skip to content

Commit 0d28b43

Browse files
committed
Document some members in select.rs.
I'm not sure about the grammar or format of the comments, but open to changing it.
1 parent c2cc7c5 commit 0d28b43

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/prompts/select.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,19 @@ use console::{Key, Term};
3535
/// }
3636
/// ```
3737
pub struct Select<'a> {
38+
/// The initial selected element when the selection menu is rendered,
39+
/// indicated by its index in [`items`](#field::items).
3840
default: usize,
41+
/// Items the user can select.
3942
items: Vec<String>,
43+
/// Message of the selection prompt.
4044
prompt: Option<String>,
45+
/// whether to report the selected value after interaction
4146
report: bool,
47+
/// whether the selection menu should be erased from the screen after interaction
4248
clear: bool,
4349
theme: &'a dyn Theme,
50+
/// Maximal number of items on page (`None` if unbounded).
4451
max_length: Option<usize>,
4552
}
4653

0 commit comments

Comments
 (0)