Page MenuHomePhabricator

IE-9 on several wikipedias cause edit page to jump to top when using edit toolbar
Closed, ResolvedPublic

Description

summary: IE-9, use any editor toolbar button that insert text cause the whole page to scroll to top. if you are in "show preview" or "show diff" mode, it means you have to scroll back down to see the editor, because the preview/diff push the textarea lower on the page.

reproduction instruction:

  1. Use IE-9
  2. make sure you are not in "compatibility mode" (important! this does not happen in "compatability mode")
  3. go (as registered or as anon) to nlwiki, enwiki, hewiki or arwiki
  4. press "random article" enough times to find an article longer that one screen (i.e., an article where the vertical scrollbar shows for the article itself)
  5. go to "edit"
  6. press "show preview". now, in order to see the edit window, you need to scroll down.
  7. press any of the toolbar buttons that add text to the edit window. note that the page scroll to top, and you do not see the edit window any more.

the whole page scrolls to the top, and you have to scroll back down to see the edit textarea again.

a workaround is to use "compatibility mode", but on any RTL wiki, using compatibility mode means you have to resort to "old" (non-beta) toolbar, which means anons lose the toolbar completely, because of bug #34885.


Version: 1.19
Severity: normal
OS: Windows 7

Details

Reference
bz35201

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 12:17 AM
bzimport set Reference to bz35201.

I can confirm this in IE 9 on Windows 7... very annoying!

Can confirm on a local installation as well.

Fun fact! IE 9 is going through the 'Mozilla/Opera' code path in jquery.textSelection's encapsulateSelection.

Seems to be the focus() call that screws up the scrolling, though I'm not 100% sure why... testing to see if it can be safely dropped or something.

Switching the order so we prefer the IE method seems to work. Dropping the focus() call from the Mozilla/Opera path left the textarea unfocused on those browsers.

we have several complaints from users (as you said yourself - very annoying) - any chances of pushing this fix to local wikis before the next upgrade?

peace.

Reedy's looking it over, should get it in shortly.

Has been deployed; can confirm on en.wikipedia.org.

Thanks. confirmed on hewike. (wish we could have this kind of service for all bugs... ha ha ha ;) )

Kudos to Brion and Reedy - mucho thanks.

peace.