File tree Expand file tree Collapse file tree 2 files changed +4
-5
lines changed
crates/chat-cli/src/cli/chat Expand file tree Collapse file tree 2 files changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -170,8 +170,10 @@ impl PromptsArgs {
170170 . is_some_and( |args| !args. is_empty( ) )
171171 {
172172 let name_width = UnicodeWidthStr :: width( bundle. prompt_get. name. as_str( ) ) ;
173- let padding = arg_pos. saturating_sub( name_width) - UnicodeWidthStr :: width( "- " ) ;
174- " " . repeat( padding)
173+ let padding = arg_pos
174+ . saturating_sub( name_width)
175+ . saturating_sub( UnicodeWidthStr :: width( "- " ) ) ;
176+ " " . repeat( padding. max( 1 ) )
175177 } else {
176178 "\n " . to_owned( )
177179 }
Original file line number Diff line number Diff line change @@ -1427,7 +1427,6 @@ impl ChatSession {
14271427 queue ! ( self . stderr, style:: SetForegroundColor ( Color :: Magenta ) ) ?;
14281428 queue ! ( self . stderr, style:: SetForegroundColor ( Color :: Reset ) ) ?;
14291429 queue ! ( self . stderr, cursor:: Hide ) ?;
1430- execute ! ( self . stderr, style:: Print ( "\n " ) ) ?;
14311430
14321431 if self . interactive {
14331432 self . spinner = Some ( Spinner :: new ( Spinners :: Dots , "Thinking..." . to_owned ( ) ) ) ;
@@ -1631,10 +1630,8 @@ impl ChatSession {
16311630 queue ! (
16321631 self . stderr,
16331632 style:: SetForegroundColor ( Color :: Reset ) ,
1634- terminal:: Clear ( terminal:: ClearType :: CurrentLine ) ,
16351633 cursor:: MoveToColumn ( 0 ) ,
16361634 cursor:: Show ,
1637- cursor:: MoveUp ( 1 ) ,
16381635 terminal:: Clear ( terminal:: ClearType :: CurrentLine ) ,
16391636 ) ?;
16401637 }
You can’t perform that action at this time.
0 commit comments