Page MenuHomePhabricator

Consistently style links (internal, inter-wiki and external)
Open, Needs TriagePublic

Description

I've recently seen a considerable amount of inconsistency in the ways in which the different types of links (internal, inter-wiki and external) are styled in various cases such as,

  1. Rendered wikitext
  2. VisualEditor
  3. 2017 wikitext editor preview

I searched for the related tasks and found a few of them but there wasn't anything that collects the different issues together and not every issue was covered. (I'll link the tasks I found to be most related, below.) So I thought of creating a task that collects them together. So, the tagging might be incorrect correct them in case they aren't right.

Wikitext

= Links =

=== Internal link ===
[[Special:Random]]

=== Inter-wiki link ===
[[m:Parsoid/Tests:quotes]]

[[dict:foo]]

=== External link ===
[https://example.com External link]

Different stylings

Read mode renderingVisualEditor rendering2017 wikitext editor previewStandalone visual diff
Screenshot
Internal linksNo icon No icon No icon No icon
Inter-wiki linksNo icon With icon No icon No icon
External linksWith icon With icon No icon No icon
NotesAll other modes must match read mode rendering.Partially fixed by https://gerrit.wikimedia.org/r/508693T187571; fixed by T58756T187692; not fixed?

Environment details

BrowserFirefox Nightly 59.0a1
OSDebian GNU/Linux 9 (stretch)
SkinVector (default)

Related tasks

Event Timeline

Kaartic created this task.Jan 17 2018, 10:11 AM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJan 17 2018, 10:11 AM
Kaartic updated the task description. (Show Details)Jan 17 2018, 10:16 AM
Schnark added a subscriber: Schnark.

The missing icon after external links in NWE preview is definitely a regression, in T180214 it was still there.

Esanders added a subscriber: Esanders.EditedJan 18 2018, 5:12 PM

This is related to T58756. Depending on how that is resolved this is probably duplicate.

The NWE preview issues should be fixed now.

However, VE showing external links for interwiki links isn't fixed because VE doesn't know about interwiki links .. it needs to convert the link to Wikitext (by asking Parsoid) and only then will it know if the "external link to another wiki" is actually an interwiki link.

I am going to consider the Parsoid side of this issue resolved and will untag Parsoid.

JTannerWMF added a subscriber: JTannerWMF.

Can someone determine whether or not this is resolved?

The Parsoid side is finished, but we still render interwiki links as external in VE.

Change 508693 had a related patch set uploaded (by Esanders; owner: Esanders):
[mediawiki/extensions/VisualEditor@master] Fix initial rendering of interwiki links

https://gerrit.wikimedia.org/r/508693

"This does not fix the rendering of new or modified interwiki links, which will require an API request."

matmarex added a subscriber: matmarex.

Esanders merged a task: T187571: External links look like interwiki links in preview.

I don't think that was actually a duplicate of this task. But it seems to be resolved now, thanks to Parsoid changes from T58756.

Esanders merged a task: T187692: Correctly style external links in visual diffs.

I don't think this is a duplicate either. The proposed patch above does not resolve this issue.

matmarex updated the task description. (Show Details)Wed, May 8, 10:33 PM

Change 508693 merged by jenkins-bot:
[mediawiki/extensions/VisualEditor@master] Fix initial rendering of interwiki links

https://gerrit.wikimedia.org/r/508693

matmarex updated the task description. (Show Details)Wed, May 8, 10:42 PM
matmarex updated the task description. (Show Details)Wed, May 8, 10:45 PM
matmarex moved this task from Code review to In progress on the VisualEditor (Current work) board.

I made a pretty table and added a case that covers T187692, since it was merged here.

matmarex updated the task description. (Show Details)Wed, May 8, 10:51 PM