Page MenuHomePhabricator

QuizGame admin panel: Pressing delete or reinstate should ask for confirmation before performing the action
Closed, ResolvedPublic

Description

Similar to T155322:

After clicking one of these, it'll automatically do whatever action you pressed. They're quite close and thus, easy to accidentally click one of them. Deleting is also a destructive action and reinstating say, an inappropriate-submitted picture game isn't wanted, so it should ask for the person to confirm and acknowledge what kind of action they're performing before it's actually performed.

Details

Related Gerrit Patches:
mediawiki/extensions/QuizGame : masterAdded confirmation dialog to delete action.

Event Timeline

Filip claimed this task.Jan 15 2017, 9:41 PM

Is there any mediawiki special page for confirmation? Or create simple special page, with redirect to AJAX action?

Filip added a comment.EditedJan 16 2017, 6:52 PM

Ok. Decided to use OOjs UI popup. WIll provide patch tomorrow.

@FilipGCI I apologize I didn't get to you earlier! So it's an AJAX action, and you access by visiting Special:QuizGameHome and pressing the button that says "Create a quiz", which will lead you to Special:QuizGameHome&questionGameAction=createForm, here's what it looks like:

http://social-tools.wmflabs.org/w/index.php?title=Special:QuizGameHome&questionGameAction=createForm

Note that social-tools.wmflabs.org is the main, official testing environment for all Social-Tools extensions under the social tools umbrella. :)

Change 332399 had a related patch set uploaded (by Filip):
Added confirmation dialog to delete action.

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

Filip added a comment.Jan 16 2017, 9:07 PM

@SamanthaNguyen: Ok, I think its good solution.

Filip added a comment.Jan 16 2017, 9:38 PM

(Out-dated - reinstate is changed to restore in new PS)

SamanthaNguyen added a comment.EditedJan 16 2017, 9:44 PM

Let me show you a task that's related to this, which is T151112. Here's what I wrote:

If you press the back arrow during an edit, it'll say "Do you really want to abandon your edit?". It'll also give two choices, "Cancel", and "OK".
This is confusing and both are too generic. It doesn't exactly state what will happen next if you press one of them. For me, cancel can mean "Yes, I want to cancel my edit", or "No, I want to continue my edit." Which one is it? I figured it out after experimenting, but I believe it can be restated so it should say:
"Yes, I want to abandon my edit"
"No, I want to continue editing"

TL;DR - They can be very vague labels and confusing to choose from. They should be more specific - in this context, the choices should be:

  • If you choose to delete:
    • Cancel
    • Delete
  • If you choose to reinstate/restore/unflag:
    • Cancel
    • Restore (or whatever we choose)

Not sure what word we're keeping for the latter, it's currently being discussed (on here, on patch, and on IRC).

Uploading updated screenshots.


Filip added a comment.Jan 17 2017, 4:44 PM

@SamanthaNguyen : @ashley: Will wait for merge of this patch before adding this to PictureGame.

Filip added a comment.Jan 17 2017, 6:32 PM

@SamanthaNguyen: Not sure, does "Un-flag", should have constructive flag, or destructive?

I'd say constructive, since I'd consider the "destructive" adjective describes an action for making something go away, yet unflag means we're making it reappear. :)

Filip added a comment.Jan 18 2017, 7:32 AM

@SamanthaNguyen @ashley: Updated, needs review.

MtDu added a subscriber: MtDu.Jan 18 2017, 12:17 PM

I posted some comments @FilipGCI

Filip added a comment.Jan 18 2017, 5:56 PM

@MtDu: Thanks for review, fixed!

Change 332399 merged by jenkins-bot:
Added confirmation dialog to delete action.

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

Filip closed this task as Resolved.Jan 20 2017, 5:39 PM

Patch got merged - closing as resolved