[go: up one dir, main page]

Page MenuHomePhabricator

"Waiting State" after clicking the submit button
Closed, ResolvedPublic5 Estimated Story Points

Description

As a user, I'd like to be aware when the Lexeme creation process is happening, so that I don't try to re-submit the lexeme, when the process is slow.

Acceptance Criteria:

  • When the submit button is clicked and there are no validation errors, The button's text changes to "Creating Lexeme...".

Original Request:

Currently, after the user clicks the submit button, nothing visually happens until either the creation of the Lexeme was successful and the user is redirected there, or there was some error and the user is presented with an error message.

We probably want to somehow communicate to the user: "Please wait, we're processing your request to create a new Lexeme."

(I have no idea about the structure of Design tasks, feel free to reword it as you see fit.)

Notes

  • From Sprint 8 Planning - disabled state for button was pushed for by dev and UX agreed

Event Timeline

Erdi: Can you make a suggestion here please?

Considering the new design system work is in progress and we don't have a clear pattern for this case in Wikidata, we can go with indicating through text. That's what happens currently in Item pages when you update an entry.

So basically we change the button text to 'Creating Lexeme...' for the in-progress state.

I've also created a new state in the Figma prototype for reference.

Ps. we don't have to make the button 'disabled' it can visually stay the same but when the user clicks basically nothing happens during this state. The text indicates what's going on clearly anyway.

I can happily answer any question regarding this.

Screenshot 2022-04-21 at 15.09.50.png (820×1 px, 201 KB)

ItamarWMDE renamed this task from DESIGN - "Waiting State" after clicking the submit button to "Waiting State" after clicking the submit button.May 11 2022, 10:39 AM
ItamarWMDE removed Erdinc_Ciftci_WMDE as the assignee of this task.
ItamarWMDE updated the task description. (Show Details)
ItamarWMDE subscribed.

IMO We would need the disabled state for the button to provide an additional indicator to the lack of behaviour, as well as prevent unnecessary clicks being processed by the browser.

Task Breakdown Notes:

  • We have decided to implement the disabled button alongside the changed text.
  • We would like to try and test this behaviour with cypress, an optional way to do so is by adding a timeout, for instance.

Potential plan of action:

  1. Add and use a new message 'Creating Lexeme' (by passing it down and using it in the Vue App)
  2. Disable the button while a submit is ongoing
  3. Make sure to reset the submit state when an error occurs

Main PR (#196) was merged, but we still need a new Wikit (pre)release with #588.

Change 800743 had a related patch set uploaded (by Lucas Werkmeister (WMDE); author: Lucas Werkmeister (WMDE)):

[mediawiki/extensions/WikibaseLexeme@master] Update new-lexeme submodule

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

Change 800743 merged by jenkins-bot:

[mediawiki/extensions/WikibaseLexeme@master] Change new lexeme button to “waiting” state after submitting

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

Can be verified on Beta.

One thing I noticed is that the button becomes enabled again, with the original text, when the lexeme has been created and the browser is currently loading the new lexeme. Depending on how fast the wiki responds to the request for the new lexeme page (and perhaps also depending on the browser), the user may still see the form with the re-enabled button for a short while (I saw it for about one second on Beta). We might want to change this.