@@ -80,11 +80,13 @@ async fn select_experiment(os: &mut Os, session: &mut ChatSession) -> Result<Opt
8080 experiment_labels. push ( label) ;
8181 }
8282
83- experiment_labels. push ( String :: new ( ) ) ;
84- experiment_labels. push ( format ! (
85- "{}" ,
86- style:: Stylize :: white( "⚠ Experimental features may be changed or removed at any time" )
87- ) ) ;
83+ // Show disclaimer before selection
84+ queue ! (
85+ session. stderr,
86+ style:: SetForegroundColor ( Color :: Yellow ) ,
87+ style:: Print ( "⚠ Experimental features may be changed or removed at any time\n \n " ) ,
88+ style:: ResetColor ,
89+ ) ?;
8890
8991 let selection: Option < _ > = match Select :: with_theme ( & crate :: util:: dialoguer_theme ( ) )
9092 . with_prompt ( "Select an experiment to toggle" )
@@ -107,14 +109,14 @@ async fn select_experiment(os: &mut Os, session: &mut ChatSession) -> Result<Opt
107109 queue ! ( session. stderr, style:: ResetColor ) ?;
108110
109111 if let Some ( index) = selection {
110- // Clear the dialoguer selection line to avoid showing old status
112+ // Clear the dialoguer selection line and disclaimer
111113 queue ! (
112114 session. stderr,
113- crossterm:: cursor:: MoveUp ( 1 ) ,
114- crossterm:: terminal:: Clear ( crossterm:: terminal:: ClearType :: CurrentLine ) ,
115+ crossterm:: cursor:: MoveUp ( 3 ) , // Move up past selection + 2 disclaimer lines
116+ crossterm:: terminal:: Clear ( crossterm:: terminal:: ClearType :: FromCursorDown ) ,
115117 ) ?;
116118
117- // Skip if user selected disclaimer or empty line
119+ // Skip if user selected disclaimer or empty line (last 2 items)
118120 if index >= AVAILABLE_EXPERIMENTS . len ( ) {
119121 return Ok ( Some ( ChatState :: PromptUser {
120122 skip_printing_tools : false ,
0 commit comments