Page MenuHomePhabricator

Unexpected relocation of cursor typing position after pressing "Shift" key when typing mid-line in New Discussion Tool replying to comment in Source Code mode
Open, Needs TriagePublicBUG REPORT

Description

List of steps to reproduce (step by step, including full links if applicable):

  • Go to a wiki with New Discussion Tool enable.
  • Copy a multi-line text/paragraph/template and past it into the source mode of the New Discussion Tool, for example:
{{subst:drv2
|page=
|xfd_page=
|reason=
}} ~~~~
  • Type in the middle of any line with Shift+[any key], for example try to type the world "Template" after "|page=", with the first character "T" being typed by clicking "Shift"+"T" keys

What happens?:
The following result should appears:

{{subst:drv2
|page=Template
|xfd_page=
|reason=
}} ~~~~

What should have happened instead?:
The following result appeared instead:

{{subst:drv2
Template|page=
|xfd_page=
|reason=
}} ~~~~

Software version (if not a Wikimedia wiki), browser information, screenshots, other information, etc.:
Firefox 93, x64
Windows 10
Found to have the situation in multiple IMEs, including English mode of Japanese IME, as well as regular English keyboards.
Might not reproduce after refreshing a page and enter text for second or third time, or trying to change the input mode, or after recovery of back-up-ed text, despite the bug appears in multiple different input modes.
Have possibility to encounter same bug even in situation other than typing within multi-line pasted text, but condition of this part is not certain.
It affect non-character keys too, for example Shift+; for :, or Shift+2 for @.

Event Timeline

hi @C933103 – we appreciate you filing this task. To ensure the issue you are experiencing is NOT being caused by a gadget or script, can you please use repeat the steps you described in the task description in "safe mode"?

Instructions for enabling "safe mode" can be found here: https://www.mediawiki.org/wiki/Help:Locating_broken_scripts?useskin=vector-2022#Test_if_you_have_problems_related_to_user_scripts_or_gadgets.

Please let us know if you have any questions doing the above.

hi @C933103 – we appreciate you filing this task. To ensure the issue you are experiencing is NOT being caused by a gadget or script, can you please use repeat the steps you described in the task description in "safe mode"?

Instructions for enabling "safe mode" can be found here: https://www.mediawiki.org/wiki/Help:Locating_broken_scripts?useskin=vector-2022#Test_if_you_have_problems_related_to_user_scripts_or_gadgets.

Please let us know if you have any questions doing the above.

Yes, it reproduce even in guest mode

I found that, the cause of the event is likely due to https://en.wikipedia.org/wiki/User:Endo999/GoogleTrans this widget being enabled.

the GoogleTrans gadget, as a workaround, can be turned off temporarily by going to MORE on the right top, Clicking on GoogleTrans menu item and then clicking on "Turn Off GoogleTrans".

This should disable the gadget when you are in the new piece of wiki code. You can turn it back on again, if you wish as well

I *might* have encountered the same issue in Meta, where I do hnot have the GoogleTrans widget, but this cannot be reproduced reliably