Page MenuHomePhabricator

VisualEditor find and replace tool gets the page to auto-scroll and moves the button away from the cursor
Closed, DeclinedPublic

Description

VisualEditor find and replace tool gets the page to auto-scroll and moves the button away from the cursor.

To reproduce:

Observe: the window scrolls down and the find tool moves up. I would expect that just clicking again at the same place would click the same button, but the button moved away from the cursor. It happened to me several times and confused me each time.

Event Timeline

Amire80 created this task.Jan 11 2015, 12:37 AM
Amire80 raised the priority of this task from to Needs Triage.
Amire80 updated the task description. (Show Details)
Amire80 added a project: VisualEditor.
Amire80 added a subscriber: Amire80.
Ryasmeen triaged this task as Normal priority.Jan 15 2015, 2:08 AM
Ryasmeen set Security to None.
Ryasmeen moved this task from To Triage to Freezer on the VisualEditor board.
Rits added a subscriber: Rits.Mar 14 2015, 11:04 PM
Rits added a comment.Mar 15 2015, 5:50 PM

hello, i was working on this bug, found that this situation just arise only for the first time when the found word is out of the window view,otherwise the cursor doesn't scroll down in any situation, i have started understanding the FindAndReplaceDialog.js and the error generated could be because of this code from the FindAndReplace.js file http://pastebin.com/MaVU63Q0, please correct me if i am wrong and provide some furthers pointers for it. thank you

I took a look at this bug and this is an interesting issue. The problem here is that when we are at the very top of the page, the toolbar is attached to the article body, which is a little below the top of the actual window (because we have the article/talk/edit tabs, etc)
When we scroll (regardless of find/replace) the toolbar "sticks" to the top of the window, because we don't really need that extra space anymore.

The search and replace behavior is merely exposing this effect, and @Rits, you are right that it only happens if the word is outside the view -- when you go for that word, the window scrolls, which makes the toolbar stick to the top. As a result, the toolbar "goes up".

The only real way to fix this would make the user interface a lot worse, as we'd have to "stick" the toolbar either at the top of the page to begin with (which is not aligned with the article) or at the place where it starts (with a huge margin on top) when we scroll down, which is obscuring part of the text.

Mooeypoo closed this task as Declined.Mar 16 2015, 10:40 PM
Mooeypoo claimed this task.