Page MenuHomePhabricator

support custom wikilink procedure per-wiki
Open, LowPublic

Description

When adding a wikilink, Visual Editor provides a dialog with autocomplete for local main namespace articles. There is no autocomplete or easy way to add link to an article from another wiki. The contributor is only able to do this if they know the relevant interwiki prefix ('w', 'meta', 'commons') and already know the target page name.

VisualEditor also does not currently know of custom templates, like this one, which some wikis use for wikilinking.

It would be nice to have this all fixed.

Example interface from one of the comments:

Event Timeline

If you paste in the full URL as an external link to VE, Parsoid actually appears to insert an interwiki link where possible
E.g. if I make some text like 'asd', and turn it into a link to https://www.mediawiki.org/wiki/MediaWiki then the wikitext it will save it is actually [[mw:MediaWiki|asd]]

Hi Krenair. This is nice, but it would be nice to have autocomplete too for people who do not yet know the page name.

Suggested look and feel:

(I "stole" the dropdown appearance from https://stats.wikimedia.org/v2/#/all-projects .)

I'm not sure how to incorporate custom W template into the suggestion. Perhaps list it under 'Wikipedia - English (custom)' but that would be confusing. :-(

Perhaps the best solution here is to allow custom definitions for some entries, for example, define 'English Wikipedia' as {{W|enwp page name|text to show}} despite showing the user the :w: prefix when they are searching for the page.

Deskana moved this task from To Triage to Freezer on the VisualEditor board.

Just a note to say this would be extremely valuable for WikiJournals, since almost all links in them are interwiki links pointing to wikipedia articles. (discussion, draft technical wishlist)