@@ -68,19 +68,17 @@ impl Select<'_> {
68
68
69
69
/// Set the initial selected element when the selection menu is rendered.
70
70
///
71
- /// Element is indicated by the index at which it appears in `item` method invocation or `items` slice.
71
+ /// The default element is indicated by the index at which it appears in the `item` method invocation or the `items` slice.
72
72
pub fn default ( & mut self , val : usize ) -> & mut Self {
73
73
self . default = val;
74
74
self
75
75
}
76
76
77
- /// Sets an optional max length for a page.
78
- ///
79
- /// Max length is disabled by None
77
+ /// Set an optional max length for a page.
80
78
pub fn max_length ( & mut self , val : usize ) -> & mut Self {
81
79
// Paging subtracts two from the capacity, paging does this to
82
80
// make an offset for the page indicator. So to make sure that
83
- // we can show the intended amount of items we need to add two
81
+ // we can show the intended amount of items, we need to add two
84
82
// to our value.
85
83
self . max_length = Some ( val + 2 ) ;
86
84
self
@@ -168,7 +166,7 @@ impl Select<'_> {
168
166
/// The user can select the items with the 'Space' bar or 'Enter' and the index of selected item will be returned.
169
167
/// The dialog is rendered on stderr.
170
168
/// Result contains `index` if user selected one of items using 'Enter'.
171
- /// This unlike [`interact_opt`](Self::interact_opt) does not allow to quit with 'Esc' or 'q'.
169
+ /// Unlike [`interact_opt`](Self::interact_opt), this does not allow to quit with 'Esc' or 'q'.
172
170
#[ inline]
173
171
pub fn interact ( & self ) -> io:: Result < usize > {
174
172
self . interact_on ( & Term :: stderr ( ) )
0 commit comments