Page MenuHomePhabricator

Minerva Neue: Stop mixing variant names with language names in the language overlay
Open, Needs TriagePublic

Description

Minerva Neue: Stop mixing variant names with language names in the language overlay.

Using variant names as language names were confusing, it caused issues like "Missing in 'Unconverted (language variant)' >".

We should stop mixing them.

This includes:

  • The language selection menu
    • Go to any zh wiki with MobileFrontend extension and Minerva Neue skin
    • Click the language menu icon / button where the page has interlanguage links
    • The language names and the language variant names were mixed together
  • The "Missing in <language name>" notice
    • Go to any non-zh wiki, which enabled ContentTranslation and have linked to a zh wiki, with zh-* Accept-Language header
    • Click the language menu icon / button where the page haven't linked to a zh page
    • It shows a "Missing in <language variant name>" notice

Reported by: Levi (列维劳德)


The language selection menu:

image.png (887×264 px, 26 KB)


The "Missing in <language name>" notice:

Screenshot_2023-03-31-06-26-37-137_com.microsoft.emmx.jpg (1×720 px, 49 KB)


Solution:

image.png (887×268 px, 28 KB)

QA steps

Test case 1

Visit https://zh.m.wikipedia.org/wiki/%E9%A9%AC%E4%BF%AE%C2%B7%E8%B4%B9%E6%96%AF%E6%B1%80 and click the language button

Expected: 大陆简体 appears once in list of language variants.

Actual: 大陆简体 appears in language variants AND language list

Test case 2

Go to https://zh.m.wikipedia.org/wiki/%E5%90%89%E6%9E%97%E7%9C%81%E5%8F%8B%E5%A5%BD%E5%9F%8E%E5%B8%82%E5%88%97%E8%A1%A8.

Check https://zh.m.wikipedia.org/wiki/%E5%90%89%E6%9E%97%E7%9C%81%E5%8F%8B%E5%A5%BD%E5%9F%8E%E5%B8%82%E5%88%97%E8%A1%A8 has no language versions, only variants.

Expected:

  • The language list should be empty

Actual:
The language list is not empty - it contains variants

Event Timeline

Jdlrobson subscribed.

I'm not sure how this relates to Minerva. Please expand the task description as it doesn't make it clear to other people what the problem we want to solve is.

Winston_Sung renamed this task from Interlanguage: Stop mixing variant names with language names to Minerva Neue: Stop mixing variant names with language names in the interlanguage menu.Jul 20 2023, 11:39 AM
Winston_Sung updated the task description. (Show Details)

I'm not sure how this relates to Minerva. Please expand the task description as it doesn't make it clear to other people what the problem we want to solve is.

Done.

I believe Minerva only provides the hook here so moving to tracking. Please let me know if I've misunderstood the task.

Also, it would be better if the title text under the variant name is using that variant.

That sounds a little tech debt as I'm not sure how to "manually fix the language conversion for 'plain text title' in language variant" (not the "display title").

Change 940209 had a related patch set uploaded (by Func; author: Func):

[mediawiki/extensions/ContentTranslation@master] Use language name instead of variant name for missing languages

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

Change 940210 had a related patch set uploaded (by Func; author: Func):

[mediawiki/extensions/MobileFrontend@master] PageHTMLParser: Exclude variants from the "other languages" section

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

Replication steps always help. I didn't fully understand what was being reported until I saw Func's patch.

That sounds a little tech debt as I'm not sure how to "manually fix the language conversion for 'plain text title' in language variant" (not the "display title").

I think something like varianttitles from the action=query API should be sufficient, but not ideal for all cases since it can not be aware of the -{T|}- syntax.

but not ideal for all cases since it can not be aware of the -{T|}- syntax.

Yeah, that's what I'm worried about.

Winston_Sung renamed this task from Minerva Neue: Stop mixing variant names with language names in the interlanguage menu to Minerva Neue: Stop mixing variant names with language names in the language overlay.Jul 22 2023, 5:49 AM
Winston_Sung updated the task description. (Show Details)

Change 940209 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] Use language name instead of variant name for missing languages

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

Change 940210 merged by jenkins-bot:

[mediawiki/extensions/MobileFrontend@master] PageHTMLParser: Exclude variants from the "other languages" section

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

Also, it would be better if the title text under the variant name is using that variant.

Should be possible: T178446: Expose display titles for a page in all available language variants through the action API .