skip to Main Content

When I try to select a word of text in the top 5% of the page in any English Wikipedia article (Example page) in Chrome, the page automatically starts scrolling up, even if the mouse pointer is far from the top edge of the page. How can I prevent this unwanted scrolling with user CSS/JS?

Trying to select "MA Cantab" on the page

Same behavior in Firefox and Safari. This doesn’t happen in other wikipedias, like German.

2

Answers


  1. This is could have been a comment, but there is too much to say so it’s an incomplete answer.

    In my terms, this is either a 1) ‘passive’ effect, or an 2) ‘active’/purposeful javascript-driven effect.

    1. ‘passive’ effect (byproduct of internal code shared between Firefox/Safari reacting to something unique to Wikipedia like hidden text or some CSS relative positioning thing), or

    2. an ‘active’/purposeful javascript-driven effect. To see if this is the case, do the following:

      • ctrl-shift-J
      • Performance Tab (maybe a hidden tab, if so click on >>)
      • start to record (top-left ◉︎ button)
      • record this:
        • highlight upwards, wait a second, then trigger the auto-pan-up behavior during highlight-drag
      • stop recording by pressing (Stop) button in the profiling popup in the middle of the debugging tools
      • mousewheel to zoom in on function calls in the timeline the Performance tab is now showing
      • find function on bottommost bricks/layers/levels of the timeline diagrams, click it (do this when, in the timeline, you start to trigger the scrolling behavior)
      • in bottom half of the pane, click Call Tree
      • click ▸ to expand "▸Event: Mouseover" repeatedly, over and over
      • right click on the various index.js:line# on the right column of the function invocations; this will swap tabs to code tab
      • click {} (bottom-left) to unminify. You may need to repeat last step to see where it sent you, if you haven’t previous unminified the code. Make sure you have enough expanded room to see where the code flashes when the tab changed.
      • try to guess what the minified code is doing, and compare the function calls you see in the timeline before and after scrolling behavior is triggered
    Login or Signup to reply.
  2. Was easily annotated for Reading audiences to understand hoping that my input is of good quality and would be rewarded with a good score in order for me to obtain the necessary points for the golden badge award

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search