Page MenuHomePhabricator

[M] Add a "pending" state to QualifierWidget read-mode
Closed, ResolvedPublic

Description

When the user submits new Qualifier data, the API request to provide a human-readable label can sometimes take a while to complete. This is probably more of an issue on development instances than on production but users with a poor connection are likely still impacted.

A simple "pending" state would improve the experience here. I'd like to avoid adding additional complexity, but even a simple "..." so that the user knows that *something* has happened as a result of their action.

@PDrouin-WMF I defer to your judgment here, but I will try to get a patch of the simplest possible solution ready as a starting point.

Acceptance Criteria:

  1. Put the qualifier element into the OOUI pending state while waiting for the qualifier submission to complete

COVID-19 Deployment Criteria

  • Can you roll back this change without lasting impact?
    1. A recovery plan is required as this will help identify our capacity for recovering from the failure
    2. THIS IS A KEY QUESTION, if you can’t answer it, you shouldn’t deploy
  • Is specialized knowledge required to support this change in production? If so, are there multiple people with this knowledge?

No specialized knowledge needed

  • Is there a way to increase confidence about the correctness of this change?

Code review + manual testing

  1. Reviews (Design, Code, etc)
  2. Testing coverage (unit tests, integration tests)
  3. Manual testing (e.g. Beta, vagrant, docker)

Event Timeline

Restricted Application added a project: Multimedia. · View Herald TranscriptJul 24 2019, 11:20 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
egardner triaged this task as Low priority.Jul 24 2019, 11:49 PM

Setting this to "low priority" because it seems like this is much more of an issue when developing locally in Docker (which is really slow). On BetaCommons, even when using browser devtools to throttle network speeds down to 2G levels, things seem to work pretty well.

Hey @egardner - whatever is simplest sounds good to me.

CBogen renamed this task from Add a "pending" state to QualifierWidget read-mode to [M] Add a "pending" state to QualifierWidget read-mode.Mar 18 2020, 4:53 PM
CBogen updated the task description. (Show Details)

Change 581100 had a related patch set uploaded (by Eric Gardner; owner: Eric Gardner):
[mediawiki/extensions/WikibaseMediaInfo@master] Add OO.ui.mixin.PendingElement to QualifierWidget

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

Change 581100 abandoned by Eric Gardner:
Add OO.ui.mixin.PendingElement to QualifierWidget

Reason:
Abandoned in favor of https://gerrit.wikimedia.org/r/c/mediawiki/extensions/WikibaseMediaInfo/ /582921

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

CBogen updated the task description. (Show Details)Mar 25 2020, 6:27 PM
AnneT updated the task description. (Show Details)Apr 8 2020, 2:01 PM
Ramsey-WMF added a subscriber: Ramsey-WMF.

ready to test on beta Commons 👍🏼

Etonkovidova closed this task as Resolved.EditedApr 21 2020, 8:57 PM

Checked in betalabs and wmf.28with 2G throttling.

Additionally adds a new CSS rule to hide elements in the qualifier area
(.wbmi-content-items and .wbmi-statement-footer) while the panel is in pending
state, so that users don't see the intermediate states of any QualifierWidgets
as data is being published.

(the sreenshot below is an animate gif - click to view)

  • no noticeable delay (pending) state when switching between Edit and view modes
  • when suggestions are being fetched