File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -451,14 +451,22 @@ class GuiControl {
451451
452452 const cliPanelDialog = {
453453 title : i18n . getMessage ( "cliPanelTitle" ) ,
454- buttonCloseText : i18n . getMessage ( "Close " ) ,
454+ buttonCloseText : i18n . getMessage ( "close " ) ,
455455 } ;
456456
457- // clear any text leftovers from previous session
458- $ ( "#cli-command" ) . val ( "" ) ;
457+ // clear response from previous session
459458 $ ( "#cli-response" ) . text ( "" ) ;
460459
461460 this . showInteractiveDialog ( cliPanelDialog ) ;
461+
462+ // Set focus on the CLI command input when dialog opens
463+ // Use timeout to ensure dialog is fully rendered
464+ setTimeout ( ( ) => {
465+ const cliInput = $ ( "#cli-command" ) ;
466+ if ( cliInput . length > 0 && cliInput . is ( ":visible" ) ) {
467+ cliInput . focus ( ) ;
468+ }
469+ } , 100 ) ;
462470 }
463471}
464472
You can’t perform that action at this time.
0 commit comments