@@ -486,6 +486,7 @@ export function createSampleGameDevConsoleIntegration(options = {}) {
486486 const code = sanitizeText ( event ?. code ) ;
487487 const key = typeof event ?. key === "string" ? event . key : "" ;
488488 const hasControlModifier = event ?. ctrlKey === true || event ?. metaKey === true || event ?. altKey === true ;
489+ const isShiftArrow = event ?. shiftKey === true && ( code === "ArrowUp" || code === "ArrowDown" ) ;
489490
490491 if ( hasControlModifier ) {
491492 return ;
@@ -542,7 +543,10 @@ export function createSampleGameDevConsoleIntegration(options = {}) {
542543 }
543544
544545 if ( code === "ArrowUp" ) {
545- if ( consoleTypingMode ) {
546+ if ( isShiftArrow ) {
547+ consoleTypingMode = false ;
548+ scrollConsoleHistory ( 1 ) ;
549+ } else if ( consoleTypingMode ) {
546550 navigateConsoleHistory ( - 1 ) ;
547551 } else {
548552 scrollConsoleHistory ( 1 ) ;
@@ -552,7 +556,10 @@ export function createSampleGameDevConsoleIntegration(options = {}) {
552556 }
553557
554558 if ( code === "ArrowDown" ) {
555- if ( consoleTypingMode ) {
559+ if ( isShiftArrow ) {
560+ consoleTypingMode = false ;
561+ scrollConsoleHistory ( - 1 ) ;
562+ } else if ( consoleTypingMode ) {
556563 navigateConsoleHistory ( 1 ) ;
557564 } else {
558565 scrollConsoleHistory ( - 1 ) ;
@@ -747,7 +754,7 @@ export function createSampleGameDevConsoleIntegration(options = {}) {
747754
748755 const commandHint = "Shift+` console | Ctrl+Shift+` overlay | Ctrl+Shift+R reload" ;
749756 const inputHint = consoleTypingMode
750- ? "Typing: Left/Right cursor | Up/Down history | Backspace/Delete | Esc mode"
757+ ? "Typing: Left/Right cursor | Up/Down history | Shift+Up/Down scroll | Backspace/Delete | Esc mode"
751758 : "Scroll: Up/Down output | Esc mode" ;
752759 const statusHint = `mode: ${ consoleTypingMode ? "typing" : "scroll" } | scroll: ${ consoleScrollOffset } | last: ${ lastCommandBinding || "none" } | status: ${ sanitizeText ( lastCommandExecution ?. status ) || "idle" } | history: ${ consoleCommandHistory . length } ` ;
753760
0 commit comments