Page MenuHomePhabricator

Add "quick actions" menu to the current language selector
Open, MediumPublic

Description

With recent desktop improvements the language selector is provided in a new place where some options are no longer available. In particular, users cannot easily edit interwiki links on Wikidata or find the translation tool.

This ticket proposes to incorporate a "more" option to the language selector that shows a new view listing available options. This will replace the current menu bar at the bottom listing display and font settings.

The general structure to support quick actions is:

  • Quick action icon. A floating icon is shown at the corner of the language selector. This can be either:
    • A direct access to an action, if there is only one available. For example, on wikis other than Wikipedia where there are no interlanguage links and Content translation is not supported, the only valid option is to open the language settings.
    • An ellipsis ("...") icon providing access to all options when there is more than one.
  • Options panel replacing the contents of the language selector to list the available actions.
    • Actions are defined by an icon and a label.
    • An option to go back (cancel) is also provided to return to the language selection.
One actionMore than one action
settings.png (316×354 px, 21 KB)
more-options.png (316×879 px, 37 KB)

For the case of Wikipedias the actions provided will be three:

  • "Translate this page" (using the "add" icon) will lead to Content Translation with the current page selected and the current language as the source language.
  • "Edit language links" (using the "pencil" icon) will lead to the interlanguage links section of the Wikidata page for the current item.
  • "Open language settings" will open the ULS language settings panel.

Additional design details

  • The quick actions are only shown in the default state of the language selector. That is, they are not visible when the user searches for a language or in the empty states in oder to avoid distractions.

Event Timeline

Pginer-WMF triaged this task as Medium priority.Aug 27 2021, 8:50 AM
Pginer-WMF created this task.
The quick actions are only shown in the default state of the language selector. That is, they are not visible when the user searches for a language or in the empty states in oder to avoid distractions.

I would imagine searching for a language and confirming it is not available is a pre-requisite for deciding to translate the article. This is what we did in mobile selector(T286470). So, if translate action is not available at that stage, user will miss that flow, right?

A direct access to an action, if there is only one available. For example, on wikis other than Wikipedia where there are no interlanguage links and Content translation is not supported, the only valid option is to open the language settings.

Can you please clarify this? For example, if an article exist only in language, currently language selector is not shown(Example: https://en.wikipedia.org/wiki/Emmanuel_Tshituka - there is no language selector). In that case how to open language settings or link that article to another language using wikidata?

settings.png (316×354 px, 21 KB)

This screenshot for "One action" has 5 languages. So this may not be a realistic screenshot ... or am I understanding this incorrectly?

The quick actions are only shown in the default state of the language selector. That is, they are not visible when the user searches for a language or in the empty states in oder to avoid distractions.

I would imagine searching for a language and confirming it is not available is a pre-requisite for deciding to translate the article. This is what we did in mobile selector(T286470). So, if translate action is not available at that stage, user will miss that flow, right?

There are some additional aspects of the new design such as empty states (T265585) that we may want to support on the current language selector. In particular:

  • Provide access to translation when searching for a language for which the content is not available.
  • Help to identify usual languages for which the content is not available. That is, the top panel that tells the page is missing in some of your usual language which replaces the functionality of grey links.

I'll create the links for those, but until we consider adding those to the current language selector, I think it is ok to keep the actions visible during search if that's simple technically and adjust it later in another iteration.

A direct access to an action, if there is only one available. For example, on wikis other than Wikipedia where there are no interlanguage links and Content translation is not supported, the only valid option is to open the language settings.

Can you please clarify this? For example, if an article exist only in language, currently language selector is not shown(Example: https://en.wikipedia.org/wiki/Emmanuel_Tshituka - there is no language selector). In that case how to open language settings or link that article to another language using wikidata?

settings.png (316×354 px, 21 KB)

This screenshot for "One action" has 5 languages. So this may not be a realistic screenshot ... or am I understanding this incorrectly?

The spec is referring to the number of actions available, not the number of languages.

For example, the option to translate with Content Translation is available in Wikipedia but not in Wikivoyage where the tool is not deployed. The option to edit links on Wikidata is not available on Commons pages.
I can use these examples to list the options and how they are presented in each case:

WikiOptions availableHow are they presented
WikipediaTranslate, edit links and lang. settings.More/ellipsis menu providing access to a menu with the 3 options.
WikivoyageEdit links and lang. settings.More/ellipsis menu providing access to a menu with the 2 options.
CommonsLang. settings.Cog icon providing directly access to the language settings.

The general idea is that it does not make much sense to provide a menu with just one option in the cases where only one is available.

Change 716241 had a related patch set uploaded (by Santhosh; author: Santhosh):

[mediawiki/extensions/UniversalLanguageSelector@master] POC: Language options in ULS

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

Change 716241 had a related patch set uploaded (by Santhosh; author: Santhosh):

[mediawiki/extensions/UniversalLanguageSelector@master] POC: Language options in ULS

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

This POC illustrates how to implement this new dialog. It is a quick illustration, since ULS does not use any UI framework, getting everything right as per the UI spec is a time consuming task

Test wiki created on Patch Demo by Pginer-WMF using patch(es) linked to this task:

https://patchdemo.wmflabs.org/wikis/9d1ef84c3b/w/

Test wiki created on Patch Demo by Pginer-WMF using patch(es) linked to this task:

https://patchdemo.wmflabs.org/wikis/9d1ef84c3b/w/

Testing with patch demo. This is what this looks like:

patchdemo.wmflabs.org_wikis_9d1ef84c3b_wiki_Main_Page(iPad).png (1×2 px, 196 KB)
patchdemo.wmflabs.org_wikis_9d1ef84c3b_wiki_Main_Page(iPad) (1).png (1×2 px, 195 KB)