Originally reported in June 2017 here.
Description: VisualEditor occasionally opens a link within a template instead of the template's settings when clicked.
There is a split second, when hovering over a template, before VisualEditor identifies the template as being in editor mode rather than reading mode; the link I'm hovering over flashes with an underline. Occasionally, this state of the template persists beyond a split second, and when this happens it only goes away when I stop hovering over the template.
Intention: Click on a template to select it.
Steps to reproduce: It is difficult to reproduce as this bug occurs at a somewhat occasional frequency, but:
- Enter VisualEditor.
- Hover the mouse over any link in any template in a page
- Click the link.
Result: 90% of the time, the template will be selected, as normal. ~10% of the time, the link inside the template will instead be clicked and you will be either taken to the page (if you've made no edits to the article yet) or, in Chrome, shown a dialogue message saying "Do you want to leave this site? Changes that you made may not be saved.", giving you an option to "Leave" or "Stay".
Expectation: Any template, when clicked in editor mode, should not open any links within it.
Web browser: Chrome 67
Operating system: Windows 7 64-bit
Screenshot:
(screenshot of the bug in action; I clicked the Other uses template in editor mode, but VisualEditor is trying to navigate me to a link within the template instead of opening the template's settings.)Video: I put together an annotated video showing the glitch in action.