Page MenuHomePhabricator

Auto-suggest dropdown for statements is too short
Closed, ResolvedPublicBUG REPORT

Description

User story: N/A

We have this:

Currently the scrollable element only shows 1.5 items before scrolling starts. This is too short.

We want this:
Make it work like Wikidata:

Screenshots (if possible):

Acceptance Criteria:

  • UI displays 7 Q items with their labels and descriptions fully visible (if fewer than 7 items are suggested, show all)
  • Vertical Scroll bars are NOT visible

[] ... until user clicks "More" to see more than the default number of suggested items (this of course requires the "more" clickable element to be there, as it is in Wikidata)

QA Results

ACStatusDetails
1T218629#5071869
2T218629#5071869

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 19 2019, 1:33 AM
Ramsey-WMF renamed this task from Auto-suggest dropdown for statements is too short to [Beta Commons] Auto-suggest dropdown for statements is too short.Mar 19 2019, 1:35 AM
Ramsey-WMF assigned this task to Cparle.
Ramsey-WMF triaged this task as High priority.
Ramsey-WMF moved this task from Untriaged to Next up on the Multimedia board.
Ramsey-WMF updated the task description. (Show Details)Mar 19 2019, 1:37 AM
Ramsey-WMF added a subscriber: PDrouin-WMF.

@PDrouin-WMF if you want to re-design the default Wikibase/Wikidata behavior on this one, let us know soon please :)

weirdly, this seems to be something to do with tabs

No visual changes needed (other than the amount of items displayed). I like our implementation so far (no dotted lines as separators).

Change 497728 had a related patch set uploaded (by Cparle; owner: Cparle):
[mediawiki/extensions/WikibaseMediaInfo@master] Make sure there's enough space for depicts dropdown

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

Change 497728 merged by jenkins-bot:
[mediawiki/extensions/WikibaseMediaInfo@master] Make sure there's enough space for depicts dropdown

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

@Cparle I looked at this on Test Commons and found the following:

  • Sometimes the autosuggest dropdown appears ABOVE the textbox (essentially becoming a drop UP ^_^)
  • The max number of entities shown before scroll is needed seems to always be 3 instead of 7
  • The "more" thing never shows up.

The first two work as expected on Beta but not test, but "more" doesn't show up anywhere.

This is happening because the drop-down is trying to fit itself "inside" the container. We want to give a different overlay to use that instead, so it uses the whole window size.

e.g. when the container is tall enough (because it has contents already) it looks fine:

Change 498291 had a related patch set uploaded (by Jforrester; owner: Jforrester):
[mediawiki/extensions/WikibaseMediaInfo@master] HACK: EntityLookupElement: Have the dropdown use the whole content div as overlay

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

@Ramsey: this is not yet fixed on testcommons because that has the code that's in the regular deployment schedule.
Beta has all merged code.
Cormac's patch (which adds a bunch of whitespace below the depicts widget, essentially giving the dropdown plenty of space to expand) didn't get merged until after the branch cut, but has already been merged, hence it's fixed on beta, but not on testcommons.

As for "more" - that is not a feature we have... :)
(I don't consider it a useful feature, but) if we want to build that, let's create a new ticket for it!

erm ... @Jdforrester-WMF not sure we really need your patch, unless you think my one is inadequate?

If more work needs to be done here beyond what is already in the patch, @Ha78na and I are working on a separate patch to re-write the Captions and Depicts panel CSS to use Flexbox. We may be able to find a solution for this as well.

Change 498291 abandoned by Jforrester:
HACK: EntityLookupElement: Have the dropdown use the whole content div as overlay

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

Cparle updated the task description. (Show Details)Mar 27 2019, 4:17 PM

@Ramsey-WMF I removed one of your acceptance criteria here - we haven't implemented that "more" widget, if you want it we'll need a separate ticket for it

Cparle removed Cparle as the assignee of this task.Mar 27 2019, 4:19 PM
Cparle added a subscriber: Cparle.
Cparle assigned this task to Edtadros.Mar 27 2019, 4:32 PM
Edtadros reassigned this task from Edtadros to Ramsey-WMF.Mar 30 2019, 4:13 PM
Edtadros added a subscriber: Edtadros.

Test Result

Status: ✅ PASS
OS: macOS Mojave
Browser: Chrome

Test Artifact(s):

✅ AC1: UI displays 7 Q items with their labels and descriptions fully visible (if fewer than 7 items are suggested, show all)
✅ AC2: Vertical Scroll bars are NOT visible

Edtadros updated the task description. (Show Details)Mar 30 2019, 4:14 PM

Tested and working on both Beta and Test. Throwing it over to Pam for design comments.

Looks good/is working well on both Beta and Test for me as well.

Ramsey-WMF renamed this task from [Beta Commons] Auto-suggest dropdown for statements is too short to Auto-suggest dropdown for statements is too short.Apr 10 2019, 7:02 PM
Ramsey-WMF claimed this task.
Ramsey-WMF closed this task as Resolved.Apr 23 2019, 11:20 PM

Works on production.