add Headlines.default_move_on_expand tunable

masterz
Andrew Dolgov 6 months ago
parent 1e90feef0e
commit 0578bf8025
No known key found for this signature in database
GPG Key ID: 1A56B4FA25D4AF2A
  1. 4
      js/Headlines.js

@ -13,6 +13,7 @@ const Headlines = {
_scroll_reset_timeout: false,
default_force_previous: false,
default_force_to_top: false,
default_move_on_expand: true,
line_scroll_offset: 120, /* px */
sticky_header_observer: new IntersectionObserver(
(entries, observer) => {
@ -255,7 +256,8 @@ const Headlines = {
// this would only work if there's enough space
App.byId("headlines-frame").scrollTop -= scroll_position_A-scroll_position_B;
Article.cdmMoveToId(id);
if (this.default_move_on_expand)
Article.cdmMoveToId(id);
}
} else if (in_body) {

Loading…
Cancel
Save