Page MenuHomePhabricator

Allow language selector search in UI language on Query Service UI, Query Builder and Mismatch Finder
Open, Needs TriagePublic

Description

As an editor, I want to be able to find a UI language to switch to not just by searching for its autonym, but also for its name in any other language.

The change will increase findability and avoid frustrating users' expectations in case they're not aware of the fact that they need to use the autonym instead of, for example, their current UI language.

Problem:

  1. open the language selector
  2. type the word "German"
  3. find no matching results
  4. delete input
  5. type "Deutsch"
  6. find matching result

What should happen:

  1. open the language selector
  2. type the word "German" or any other translation of the language's name
  3. find matching result as "Deutsch"

The language selector should still only show autonyms e.g. when searching for "German" the result is given as "Deutsch" see: https://phabricator.wikimedia.org/T345841#9382451

BDD
GIVEN a user wants to switch their UI language
AND they use the Language selector to pick a new language
WHEN they enter any of the translations of said language
THEN the Language selector provides the language's autonym as a matching result

Acceptance criteria:

  • The Language selector provides autonym matches for searches made in any language

Event Timeline

Providing language matches based on the current UI language would align the implementation of the Language Selector in our products with the behavior defined by the Language team. This would be a great improvement.

Screenshot 2023-12-05 at 11.59.22.png (876×1 px, 73 KB)

Regarding whether the selector menu should only show autonyms (e.g. when searching for "German" the result is given as "Deutsch"), it looks like the answer is yes. Autocompleting the query in the selector's field (as seen in the screenshot above, "spa[nish]") is a helpful way to connect the dots between the UI language input and the autonym.

Now, that query autocomplete is displayed by the Language selector component in the Query Service, but it's missing in the Mismatch Finder and the Query Service version of the component.

Query ServiceQuery Builder & Mismatch Finder
Screenshot 2023-12-05 at 12.16.47.png (770×1 px, 60 KB)
Screenshot 2023-12-05 at 12.20.44.png (688×786 px, 46 KB)

I would advise for consolidating that behavior too, but I'm not sure if that part of the work should be included in this task, or if we need a separate ticket for that improvement.

Arian_Bozorg renamed this task from language switcher in Query Service UI, Query Builder and Mismatch Finder only allows search for autonym, not in UI language to Allow language selector search in UI language on Query Service UI, Query Builder and Mismatch Finder.Dec 6 2023, 9:56 AM