File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -282,7 +282,7 @@ try {
282282 multipleChoice = null ;
283283 autocomplete . update ( ) ;
284284 // Focus input element
285- answerInput . focus ( ) ;
285+ // answerInput.focus();
286286 }
287287
288288 // Check answer
@@ -1018,7 +1018,7 @@ try {
10181018 false ,
10191019 ) ;
10201020
1021- target ?. querySelector ( 'input, textarea, math-field' ) ?. focus ( ) ;
1021+ // target?.querySelector('input, textarea, math-field')?.focus();
10221022
10231023 currentAnswerMode = mode ;
10241024 }
@@ -1126,6 +1126,10 @@ try {
11261126 if ( event . target . hasAttribute ( 'data-flag-response' ) ) return r . flagged ? unflagResponse ( event ) : flagResponse ( event ) ;
11271127 ui . view ( "" ) ;
11281128 await resubmitCheck ( r ) ;
1129+ window . scrollTo ( 0 , document . body . scrollHeight ) ;
1130+ setTimeout ( ( ) => {
1131+ document . querySelector ( `[data-answer-mode="${ r . mode === 'text' ? 'input' : r . mode } "]` ) ?. querySelector ( 'input, textarea, math-field' ) ?. focus ( ) ;
1132+ } , 500 ) ;
11291133 } ) ;
11301134 } ) ;
11311135 if ( sortedHistory . find ( r => r . flagged ) ) {
You can’t perform that action at this time.
0 commit comments