VisualEditor: The category tool should automatically strip the namespace "Category:" out of the cat name, if the editor types it in


Add a category to a page

Steps to Reproduce:

  1. Open the page in VisualEditor and choose the categories tool.
  2. Type the full name of the category, including the namespace: Category:Example

Actual Results:
VisualEditor adds a non-existent, malformed category named [[Category:Category:Example]].

Expected Results:
That VisualEditor would recognize that "Category:Example" already contained the namespace, and thus omit the duplication. Ideally, at non-English wikis, it would recognize and remove both the local name for the namespace and the English name, since both are typically valid (e.g., strip out both "Kategorie" and "Category" at the German Wikipedia).

Reproducible: Always

Version: unspecified
Severity: enhancement

bzimport set Reference to bz57786.
Whatamidoing-WMF created this task.Via LegacyDec 1 2013, 12:05 AM
Aklapper added a comment.Via ConduitDec 2 2013, 10:12 AM

[new feature or "nice-to-have" => severity=enhancement]

Jdforrester-WMF added a comment.Via ConduitDec 3 2013, 3:25 AM

What to do when there's a category called "Category:Foo" and another called "Foo". Do we strip or not?

SalixAlba added a comment.Via ConduitDec 5 2013, 11:14 PM

There is [[Category:Category theory]], it might be worth checking as a corner case.

Whatamidoing-WMF added a comment.Via ConduitDec 6 2013, 7:58 PM

Do any [[Category:Category:Foo]] pages exist? I haven't seen one.

Jdforrester-WMF added a comment.Via ConduitDec 6 2013, 8:15 PM

(In reply to comment #4)

Do any [[Category:Category:Foo]] pages exist? I haven't seen one.

On all ten million MediaWiki wikis out there? Quite probably…


Jdforrester-WMF added a comment.Via ConduitDec 6 2013, 8:17 PM

Also there's the problem of either (a) only doing this hack for English, or (b) having to hold in VE a copy of all of the translations of Category:, and know which one to remove when (removing Catégorie: on French, but not on English, and so on).

Jdforrester-WMF moved this task to Backlog on the VisualEditor workboard.Via WebNov 24 2014, 4:15 PM

Add Comment