Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

en.wikipedia.org - Page jumps at the top of editor after pasting text while using WikEd #94036

Closed
webcompat-bot opened this issue Nov 20, 2021 · 21 comments
Labels
browser-firefox engine-gecko The browser uses the Gecko rendering engine priority-critical priority-normal severity-important A non-core broken piece of functionality, not behaving the way you would expect. status-needsinfo text-contenteditable Issues with contenteditable content
Milestone

Comments

@webcompat-bot
Copy link

webcompat-bot commented Nov 20, 2021

URL: https://en.wikipedia.org/w/index.php?title=User_talk:Cacycle/wikEd&action=edit&section=80

Browser / Version: Firefox 94.01
Operating System: Windows 10
Tested Another Browser: Yes Other

Problem type: Something else
Description: WikEd with Wikipedia: cursor jumps to top after pasting
Steps to Reproduce:
There is an issue with Firefox 94 when editing Wikipedia with the WikEd editor enabled. I have searched but not seen it reported.

It has been reported on the WikEd Talk page by several people, with no resolution reported: https://en.wikipedia.org/wiki/User_talk:Cacycle/wikEd#Loses_text_highlighting_after_toggle_uppercase_first_%E2%86%92_uppercase and the next section, "Cursor jumps to top of edit box, WikEd with Firefox 94"

Specifically, when editing any Wikipedia page or section with the WikEd editor enabled instead of the standard Wikipedia editor, if text is pasted into the page, the cursor jumps to the top of the page, and the page scrolls up if there is more text than fits the screen. Normal behaviour is that the cursor stays at the end of the inserted text.

Other uses report that this happens with Firefox 94 (and 94.1) only, in normal and Troubleshooting (to disable extensions) modes, under Windows and macOS, and does not happen with other browsers, older Firefoxes, or Firefox for Android. Link to discussion is above.

To replicate: open a Wikipedia page that is not too short (to show scrolling), click "Edit Source", enable the WikEd editor by clicking a "pencil and paper" icon at bottom left of a cluster of icons above the edit window at the top left, scroll down so that the top of the text is not displayed, and insert some text anywhere. The text will be inserted, but the box will scroll to the top, and the cursor will be at the beginning of text. Normally the cursor would be positioned at the end of the new insertion. This may be an issue with WikEd or with Firefox 94.

Browser Configuration
  • None

From webcompat.com with ❤️

@webcompat-bot webcompat-bot added the action-needsmoderation The moderation has not yet been completed label Nov 20, 2021
@webcompat-bot webcompat-bot added this to the needstriage milestone Nov 20, 2021
@webcompat-bot webcompat-bot added the browser-fixme This requires manual assignment for the browser name label Nov 20, 2021
@webcompat-bot webcompat-bot changed the title In the moderation queue. en.wikipedia.org - see bug description Nov 22, 2021
@webcompat-bot webcompat-bot added browser-firefox engine-gecko The browser uses the Gecko rendering engine priority-critical and removed browser-fixme This requires manual assignment for the browser name action-needsmoderation The moderation has not yet been completed labels Nov 22, 2021
@softvision-oana-arbuzov
Copy link
Member

Thanks for the report, but I'm not able to reproduce the issue. For me the cursor remains in the position of the typed text, even if I copy and paste a text.
image

Tested with:
Browser / Version: Firefox Nightly 96.0a1 (2021-11-21), Firefox Release 94.0.1
Operating System: Windows 10 Pro

Reporter could you try clearing cache/data/cookies, disable Ad-blocker (if available), or use a clean profile, and check again? Also if there are any changes made to default settings of the browser (e.g. in about:config) please revert to the default settings.

@wikied94
Copy link

I have the same issue. I have tried clearing everything, using Ccleaner and restarting my machine, all to no avail. Haven't changed anything else, and I don't see why ad-blocker should make any difference, but I have just tried disabling that and still have the problem. Very occasionally it doesn't happen, but this is random, and I cannot recreate a pattern.

@softvision-oana-arbuzov
Copy link
Member

@wikied94 could you create a video recording while it happens? Maybe I am missing some steps.

@softvision-oana-arbuzov
Copy link
Member

I'm back, it seems that wikEd was not enabled on my preferences. After enabling it I tried again to reproduce it, but without luck again.
image

Note: To enable it simply check wikEd under the Gadget section in your Wikipedia preferences.

Tested with:
Browser / Version: Firefox Nightly 96.0a1 (2021-11-23)
Operating System: Windows 10 Pro

@wikied94
Copy link

wikied94 commented Nov 25, 2021

Sorry - I had a busy day and didn't get to my emails yesterday, but don't know how I could produce an effective video without help, which I don't have at the moment.

Also, I didn't notice that you were not using WikEd in the first screenshot (which is where the issue is happening), but I am surprised that it didn't happen for you after you enabled it. It is still happening all the time for me (with WikEd, not with the standard editor).

Thanks very much for your assistance, btw!

I have 94.0.2 (22 Nov, but it was also happening before), and Windows 10 Home.

@softvision-oana-arbuzov
Copy link
Member

softvision-oana-arbuzov commented Nov 25, 2021

@wikied94 what I did was:

Note: With the link https://en.wikipedia.org/w/index.php?title=User_talk:Cacycle/wikEd&action=edit&section=80 it don't have scroll bar since it is not enough text in the section.
image

Prerequisites:

  1. Signed into Wikipedia account
  2. Enabled wikEd under the Gadget section in Wikipedia preferences.
    image

[Updated] Steps to reproduce:

  1. Navigate to https://en.wikipedia.org/wiki/User_talk:Cacycle/wikEd
  2. Click "Edit source" button.
  3. After the editor is shown, scroll down to the end of the article (scroll bar is available since there is a lot of text ).
  4. Copy some text from somewhere (e.g "Any work submitted to Wikipedia can be edited")
  5. Paste the text under the last line of already available text.
  6. Observe behavior.

Expected result:
The text is pasted and the page remains at the same position (cursor at the end of the inserted text).

Actual result:
The text is pasted, but the page jumps to the top of the editor.

@softvision-oana-arbuzov
Copy link
Member

softvision-oana-arbuzov commented Nov 25, 2021

@wikied94 I think I got it, it seems that the text needs to be pasted under the last already typed text.
Thanks for your help.

PageJumpPastedTest

Note: The issue does not occur on Chrome.

Tested with:
Thanks for the report, but I'm not able to reproduce the issue.

Tested with:
Browser / Version: Firefox Nightly 96.0a1 (2021-11-24)
Operating System: Windows 10 Pro

Reopening and moving to Needsdiagnosis for further investigation.

@softvision-oana-arbuzov softvision-oana-arbuzov added priority-normal severity-important A non-core broken piece of functionality, not behaving the way you would expect. labels Nov 25, 2021
@softvision-oana-arbuzov softvision-oana-arbuzov changed the title en.wikipedia.org - see bug description en.wikipedia.org - Page jumps at the top of editor after pasting text while using WikEd Nov 25, 2021
@wikied94
Copy link

Ah, yes - sorry if that wasn't clear, about it only happening when pasting, but I'm glad that you managed to replicate it, at least! Thanks for following up.

I don't know if the other problem is related, but also started around the same time - when you highlight some text to use the upper-lower case switch feature (A-a), the cursor moves to the top instead of staying where it is, as it used to.

@pol098
Copy link

pol098 commented Nov 30, 2021

I originally posted this issue anonymously; I have been unable to log into github to add necessary detail until now (changed email address + unacceptably short password = password reset sent to non-existent address). The original post is correct but needs adding to and clarifying: the issue only manifests for logged-in users who are using the optional WikEd editor. The issue arise with a logged-in Wikipedia user pasting (not just inserting) text into a scrolled-down WikEd edit box for a Wikipedia page. There is a discussion on WIkipedia which can also be used as the test page for editing.:
https://en.wikipedia.org/wiki/User_talk:Cacycle/wikEd#Cursor_jumps_to_top_of_edit_box,_WikEd_with_Firefox_94

Additional to my detailed report that started this thread:

I omitted important information to replicate the issue (sorry): - As I said, this only manifests with the optional WikEd editor, not the standard editor - you have to be logged in to Wikipedia - You have to tick Preferences > Gadgets > Editing section > "wikEd: alternative full-featured integrated text editor for Firefox, Safari, and Google Chrome." - when editing a page, the icon to switch to the WikEd editor instead of the standard editor must be clicked.

I attach a PNG screen dump of the edit screen with WikEd enabled - all the buttons should show. To switch to the WikEd editor instead of the standard Wikipedia one after selecting it in Preferences, click the button I've drawn a red square round, at the top right of the edit area, (not left as I had said); a large array of icons should appear.

The issue manifests in Troubleshooting mode; I have clean-installed Firefox in a Win7/32 virtual machine and the issue also manifests.

View the screenshotScreenshot

@pol098
Copy link

pol098 commented Dec 2, 2021

@softvision-oana-arbuzov: "it seems that the text needs to be pasted under the last already typed text"
(I originally posted this issue.) Wherever the text is pasted, focus jumps to the top of the edit box, it doesn't have to be at the bottom. Even if there is not enough text to make it scroll up, focus still jumps to the top of text. The jump is immediate: if you paste something then try to type additional text, the new text appears at the beginning.

@pol098
Copy link

pol098 commented Dec 7, 2021

ERROR PERSISTS IN FIREFOX 95.0. (Checked with Win10/64)

@pol098
Copy link

pol098 commented Dec 19, 2021

ERROR PERSISTS IN FIREFOX 95.0.1 (Checked with Win10/64)

@pol098
Copy link

pol098 commented Dec 19, 2021

ERROR PERSISTS IN FIREFOX 95.0.2 (Checked with Win10/64)

@ksy36
Copy link
Contributor

ksy36 commented Dec 20, 2021

This appears to be a regression caused by this change to contenteditable https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=a67baeba9a658f8650657389f38aa9bc7e2eef07&tochange=f895a0b6c0e3748e11381173b3cd32a7bb8c60dd.

I'll try to come up with a minimal test case tomorrow to figure out the root cause of this behaviour.

@pol098
Copy link

pol098 commented Dec 20, 2021

I have found that most pastes are followed by jumping to the top, but a minority are not. I haven't (yet) noticed if there is a difference between the jumping and non-jumping instances, or if repeating a non-jumping paste leads to consistent behaviour.

@ksy36
Copy link
Contributor

ksy36 commented Dec 21, 2021

I've created a reduced test case and filed a core bug https://bugzilla.mozilla.org/show_bug.cgi?id=1747008 for further investigation.

@ksy36 ksy36 closed this as completed Dec 21, 2021
@ksy36 ksy36 modified the milestones: needsdiagnosis, moved Dec 21, 2021
@ksy36
Copy link
Contributor

ksy36 commented Jan 19, 2022

Just an update here, this has been fixed in Firefox Nightly 98.0a1 (2022-01-19) and Firefox release will get this fix once it reaches 98.

@wikied94
Copy link

wikied94 commented Jan 20, 2022 via email

@wikied94
Copy link

wikied94 commented Jan 20, 2022 via email

@wikied94
Copy link

(Sorry - did that by email and the first one didn't seem to have been sent, and now I see it's there twice, and will a lot of other guff, and I don't seem to be able to delete or edit my comments.)

@ksy36 ksy36 removed their assignment Mar 30, 2022
@softvision-oana-arbuzov
Copy link
Member

I've checked again, and I can confirm it works now correctly.

Tested with:
Browser / Version: Firefox Nightly 108.0a1 (2022-10-20)
Operating System: Windows 10 Pro

@wikied94 can you still reproduce it?

[inv_42/2022]

@ksy36 ksy36 added the text-contenteditable Issues with contenteditable content label Oct 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
browser-firefox engine-gecko The browser uses the Gecko rendering engine priority-critical priority-normal severity-important A non-core broken piece of functionality, not behaving the way you would expect. status-needsinfo text-contenteditable Issues with contenteditable content
Projects
None yet
Development

No branches or pull requests

5 participants