Page MenuHomePhabricator

[EPIC] Making other entity types more accessible through the search box
Open, Needs TriagePublic

Description

As an editors I want to easily access not just Items but also Lexemes, Properties and Entity Schemas in the search box in order to have access to all content on Wikidata.

Problem:
Right now the top-right search box gives and easy type-ahead search for Items. It does not work for Lexemes, Properties and Entity Schemas. For that people need to use "P:", "L:" and "E:" in front of their search terms and then get redirected to Special:Search upon pressing enter. This is not a good experience and research has shown that people are not able to figure out how to search for Lexemes for example.

Solution:
After some design iteration, an initial solution was validated in a round of usability testing (T329706). The feedback and data gathered as part of said investigation will allow iterating and delivering a design solution for the new, extended main Wikidata search.

Screenshots/mockups:

Screenshot 2023-05-30 at 17.28.35.png (1×2 px, 268 KB)

BDD
GIVEN search bar
AND drop-down menu
AND type-ahead search
WHEN a user is looking for Lexemes, Properties and EntitySchemas
THEN the drop-down is used to toggle the search between namespaces
AND the query is entered in the search bar
THEN a type-ahead search is returned

Acceptance criteria:

  • Lexemes, Properties and EntitySchemas are searchable through the search bar

Notes:

  • This will be created for Vector 2022.

Implementation considerations:

  • The Scoped TypeaheadSearch solution is built using the combination of the Codex components: Select and TypeaheadSearch. It is yet to be determined if this new pattern should be introduced in the Codex library, or maintained by WMDE. The latter sounds more logical (this is quite a domain-specific solution) at the time of writing.
  • We might need to customize the Menu component (used by Select): The current width of the Codex's menu is 100% (of its parent). We’d need to adjust that to make it wrap (fit) its content by default and take a max-width (see linked specs for more details).
  • The current implementation of the Codex Menu doesn't include a menu heading slot. We'll need to decide which team will implement that missing element

Open questions:

  • What about other namespaces? Forms, Senses, Help and Project namespace might also be relevant here. This can come in later iterations
  • By updating the search component in Vector 2022, how will this affect other interactions on the skin?

Event Timeline

Constraint to be considered:

  • “Search in: Items” “All” would be problematic, because it’s really hard to rank results from different namespaces among each other.
Arian_Bozorg renamed this task from Making other entity types more accessible through the search box to [EPIC] Making other entity types more accessible through the search box.Jun 7 2023, 8:08 AM
Arian_Bozorg updated the task description. (Show Details)

Re: creating new component for Codex or creation of a library of LOD components see T338631