File tree Expand file tree Collapse file tree 3 files changed +9
-12
lines changed
frontend_tests/node_tests Expand file tree Collapse file tree 3 files changed +9
-12
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ const {strict: assert} = require("assert");
4
4
5
5
const _ = require ( "lodash" ) ;
6
6
7
- const { set_global, stub_out_jquery , zrequire} = require ( "../zjsunit/namespace" ) ;
7
+ const { set_global, zrequire} = require ( "../zjsunit/namespace" ) ;
8
8
const { run_test} = require ( "../zjsunit/test" ) ;
9
9
10
10
set_global ( "page_params" , {
@@ -13,9 +13,6 @@ set_global("page_params", {
13
13
is_guest : false ,
14
14
} ) ;
15
15
16
- set_global ( "document" , null ) ;
17
- stub_out_jquery ( ) ;
18
-
19
16
zrequire ( "color_data" ) ;
20
17
zrequire ( "hash_util" ) ;
21
18
zrequire ( "stream_topic_history" ) ;
Original file line number Diff line number Diff line change @@ -415,12 +415,4 @@ exports.all = new MessageList({
415
415
muting_enabled : false ,
416
416
} ) ;
417
417
418
- // We stop autoscrolling when the user is clearly in the middle of
419
- // doing something. Be careful, though, if you try to capture
420
- // mousemove, then you will have to contend with the autoscroll
421
- // itself generating mousemove events.
422
- $ ( document ) . on ( "message_selected.zulip wheel" , ( ) => {
423
- message_viewport . stop_auto_scrolling ( ) ;
424
- } ) ;
425
-
426
418
window . message_list = exports ;
Original file line number Diff line number Diff line change @@ -457,6 +457,14 @@ exports.initialize = function () {
457
457
$ ( document ) . on ( "compose_started compose_canceled compose_finished" , ( ) => {
458
458
bottom_of_feed . reset ( ) ;
459
459
} ) ;
460
+
461
+ // We stop autoscrolling when the user is clearly in the middle of
462
+ // doing something. Be careful, though, if you try to capture
463
+ // mousemove, then you will have to contend with the autoscroll
464
+ // itself generating mousemove events.
465
+ $ ( document ) . on ( "message_selected.zulip wheel" , ( ) => {
466
+ exports . stop_auto_scrolling ( ) ;
467
+ } ) ;
460
468
} ;
461
469
462
470
window . message_viewport = exports ;
You can’t perform that action at this time.
0 commit comments