console-rs / dialoguer

Rust utility library for nice command line prompts and similar things
MIT License
1.31k stars 143 forks source link

Select : prompt is no longer displayed #281

Closed tbergerd closed 11 months ago

tbergerd commented 11 months ago

This is a regression at head I noticed. cargo run --example select

Behavior : The four options get displayed without the prompt Expected : the "Pick your flavor" prompt is correctly displayed (works fine in dialoguer 0.10.4)

Specifically the reg was introduced by fix #267 I'm under the impression Paging::update is only meant to be called after Paging::render_prompt calling it before makes it so self.activity_transition is set to false (iff there is only one page. notice we do see the prompt correctly on the third part of the 'select' example because it has 2 pages) here I think we only want to update self.current_page (to fix the issue mentioned in #267)

I'll try and submit a fix but I'm opening the issue in case what I propose is not what we want

pksunkara commented 11 months ago

I think that sounds about right.