janitor icon indicating copy to clipboard operation
janitor copied to clipboard

Show when something is pending after you clicked on a button

Open jankeromnes opened this issue 7 years ago • 2 comments

Today, when you click on a button on Janitor, chances are you won't see any UI changes for anywhere between a few seconds to like a minute or so (after that, when the server replies, you see whether the action has succeeded or failed, and you might see a message box appear with more information).

This is bad UX, because users don't know if the click worked, or if the server is doing anything at all. This caused some users to take on the habit of clicking some buttons multiple times, "just to be sure".

Instead, once an async action has been triggered, we should show a pending state (e.g. a spinner), and disable the button until the server replies (or the action fails some other way).

This should be pretty easy to do, by adding a spinner to the auto-generated .form-control-feedback element, and by showing it and disabling all form controls whenever an action is triggered.

If anyone is interested in taking this, I can mentor this bug, and show you where in the code this fix could be implemented.

jankeromnes avatar Aug 02 '17 16:08 jankeromnes

Partly addressed in 50a470de401926c3557a029298305caac371ac4d (by disabling buttons and inputs when a form is pending).

jankeromnes avatar Aug 04 '17 09:08 jankeromnes

@jankeromnes I'll do it

ar5had avatar Aug 09 '17 19:08 ar5had