Page MenuHomePhabricator

VisualEditor: Double colons when linking to File/Category
Closed, ResolvedPublic

Description

Intention:
Linking to a file using visual editor

Steps to Reproduce:

  1. Edit page on using VE
  2. Click add link
  3. Enter a filename with File-prefix (e.g. File:Foo.svg)
  4. Press enter
  5. Press enter again

The same thing happens for categories or if the preceding colon is added manually.

Actual Results:

  1. Inserted text is changed to :File:Foo.svg
  2. Inserted text is changed to ::File:Foo.svg

Expected Results:

  1. As result
  2. No change

Reproducible: Sometimes

The same thing happens for categories or if the preceding colon is added manually. I can get this to happen repeatedly but occasionally VE will correctly know not to add the second colon (have not identified when though.


Version: unspecified
Severity: normal
See Also:
https://bugzilla.wikimedia.org/show_bug.cgi?id=63355

Details

Reference
bz63353

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 3:03 AM
bzimport set Reference to bz63353.

Created attachment 14992
Screencast

Added video since this is not 100% reproducible

Attached:

Also happening with FF, Win8.
The resulting wikilink works, though.

Here's a variation:

  1. Edit page on using VisualEditor.
  1. Type the file name you want (with or without the colon prefix that you want): File:Example.jpg
  1. Open the link inspector, which will offer to link these files (at least on en.wp):

:File:Example.jpg
File:Example.jpg
File:Example.JPG

  1. Choose the first. Press enter. Now it has changed the link target to "::File:Example.jpg" and says "Invalid page title". (Saving this link will work correctly anyway.)
  1. Alternatively, choose the second, and press enter. This also works and does not produce the error message.

Dupe of 50279 (and now fixed).

  • This bug has been marked as a duplicate of bug 50279 ***