Page MenuHomePhabricator

Replace local namespaces with real links on Special:CentralAuth
Open, Needs TriagePublic

Description

Problem
In T200938, the details of blocks were expanded to include the same details that are on Special:BlockList. However, pages and namespaces that are not a part of core, cannot be safely rendered since that namespace may not exist on the current wiki and even if it does, may not be the same one.

Unfortunately, namespaces are not in the database, so it's impossible to know what the canonical name is for a namespace by the id when the page is rendered.

Solution
The siteinfo API does return a map of namespaces for a wiki.

When a "local" link is rendered, we should pass the details of the pages (page id or namespace id) to the client (by putting this data in the HTML somewhere). Then, we should attach a small JavaScript that, when this information is on the page, will use the local wiki's API to expand this link into the real links.

Event Timeline

dbarratt created this task.Jun 26 2019, 4:38 PM
Restricted Application added subscribers: MGChecker, Aklapper. · View Herald TranscriptJun 26 2019, 4:38 PM
dbarratt renamed this task from Replace local namespaces with real links to Replace local namespaces with real links on Special:CentralAuth.Jun 26 2019, 4:38 PM