Page MenuHomePhabricator

CheckUser 2.0: Input form
Closed, ResolvedPublic3 Estimated Story Points

Assigned To
Authored By
Niharika
Oct 31 2019, 3:45 PM
Referenced Files
F31122831: Screenshot 2019-11-21 at 6.34.26 PM.png
Nov 21 2019, 1:05 PM
F31098658: investigate-reason-link.png
Nov 18 2019, 8:28 PM
F31098432: Screen Shot 2019-11-18 at 13.44.47.png
Nov 18 2019, 6:45 PM
F31098036: image.png
Nov 18 2019, 3:34 PM
F31076947: image.png
Nov 14 2019, 8:50 PM
F31064542: image.png
Nov 13 2019, 6:16 PM
F31064541: image.png
Nov 13 2019, 6:16 PM
F30937806: image.png
Oct 31 2019, 3:45 PM

Description

Goal

We want to allow users to be able to input usernames, IP addresses and IP ranges in order to look up information about them. The input form will support the above three main input types. There will also be an input box to include a reason for the check (mandatory). This is only a UI ticket and there will be a follow-up ticket for the functionality after the information is submitted.

Mock

https://prtksxna.github.io/wmf-cu-prototype/index.html

Screenshot 2019-11-21 at 6.34.26 PM.png (550×1 px, 56 KB)

Acceptance criteria

  • Form header: Search for usernames, IP addresses or IP ranges
    • All three types will be added in a single text field. We should auto-complete the usernames and still allow IPs/ranges that become "capsules" once they are valid by regex. We did this with Interaction Timeline and should be able to do it here as well.
  • Input box for usernames. Limit on number of users accepted is 2 (for first iteration).
    • Placeholder: UserName or 1.1.1.1
    • Help text: Not required
    • Usernames and IPs auto-complete
  • Input box for the reason for the check.
    • This a mandatory; an error pops up if empty when the user tries to submit.
    • Placeholder text: Not required
    • Help text: Not required
  • Submit button for submitting the info for performing the check.

Related Objects

StatusSubtypeAssignedTask
OpenNone
ResolvedNiharika
ResolvedNiharika
Resolved Tchanders
ResolvedNiharika
Resolved Tchanders
Resolved Tchanders
ResolvedNone
ResolvedMar 19 2020dmaza
Resolved Tchanders
Resolved Tchanders
Resolved Tchanders
Resolved Tchanders
Resolved Tchanders
Resolved Tchanders
Resolved Tchanders
Resolved Tchanders
Resolved Tchanders

Event Timeline

Niharika triaged this task as Medium priority.Oct 31 2019, 3:45 PM
Niharika created this task.
Niharika created this object in space Restricted Space.
Niharika set the point value for this task to 3.
Niharika shifted this object from the Restricted Space space to the S1 Public space.Nov 5 2019, 7:54 PM

@Niharika @Prtksxna A few questions about the acceptance criteria:

  • Input box for usernames. [...]
    • Placeholder: Add users

Should the placeholder be the default "Add more..." instead? Might make more sense since this is not just for adding users.

  • Input box for the reason for the check.
    • [...]
    • Placeholder text: Example: Investigating Apples for suspected sockpuppetry

Are we OK with the fact that Apples can be a real username?

Finally, just wanted to ask whether we should make the help text inline? It's the default and recommended for accessibility, though it does make the page a bit busier:

inline: trueinline: false
image.png (418×858 px, 64 KB)
image.png (319×861 px, 34 KB)

@Niharika @Prtksxna Sorry, another question!

  • Input box for the reason for the check.
    • This a mandatory before the Submit button becomes active.

Is this suggesting that the Submit button be disabled until the required fields are filled, and if so how important is this? Unlike the current Special:CheckUser form, Special:Investigate can use required fields so won't submit anyway if they are empty.

Most other special pages that extend FormSpecialPage rely on required fields and so don't disable the submit (examples: Special:Block, Special:BotPasswords, Special:ChangeContentModel, Special:RandomInCategory). Special:Mute and Special:Preferences do disable the submit, but for these forms the submit needs to enable according to whether values have changed, rather than whether certain fields are filled.

@Niharika @Prtksxna A few questions about the acceptance criteria:

  • Input box for usernames. [...]
    • Placeholder: Add users

Should the placeholder be the default "Add more..." instead? Might make more sense since this is not just for adding users.

Yeah, it can be a user or IP address. I'm a bit iffy about Add more... as it kinda means they already added something. How about Add username or IP address instead?

  • Input box for the reason for the check.
    • [...]
    • Placeholder text: Example: Investigating Apples for suspected sockpuppetry

Are we OK with the fact that Apples can be a real username?

Ooh, good catch! It could be Investigating User:... for suspected sockpuppetry. @Prtksxna thoughts?

Finally, just wanted to ask whether we should make the help text inline? It's the default and recommended for accessibility, though it does make the page a bit busier:

inline: trueinline: false
image.png (418×858 px, 64 KB)
image.png (319×861 px, 34 KB)

Should be @Prtksxna's call.

@Niharika @Prtksxna Sorry, another question!

  • Input box for the reason for the check.
    • This a mandatory before the Submit button becomes active.

Is this suggesting that the Submit button be disabled until the required fields are filled, and if so how important is this? Unlike the current Special:CheckUser form, Special:Investigate can use required fields so won't submit anyway if they are empty.

Most other special pages that extend FormSpecialPage rely on required fields and so don't disable the submit (examples: Special:Block, Special:BotPasswords, Special:ChangeContentModel, Special:RandomInCategory). Special:Mute and Special:Preferences do disable the submit, but for these forms the submit needs to enable according to whether values have changed, rather than whether certain fields are filled.

I see. So the alternative would be to keep the button always active but return with an error message if the reason field is not populated? That works for me. We should have a mock for how the error would display. Ping @Prtksxna.

Change 550912 had a related patch set uploaded (by Tchanders; owner: Tchanders):
[mediawiki/extensions/CheckUser@master] Add search form fields to Special:Investigate

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

Thanks @Niharika. Placeholder has been updated; will await @Prtksxna's thoughts on the other questions too.

When an attempt is made to submit a form with an empty required field, the browser complains:

image.png (309×789 px, 37 KB)

Should the placeholder be the default "Add more..." instead? Might make more sense since this is not just for adding users.

Like you've done with the reason field, we'll put examples in the user/ip input field as well. I was thinking something like 'JohnSmith or 1.1.1.42'. I've updated the prototype to reflect this.

Are we OK with the fact that Apples can be a real username?

I am not sure about this one. We'll need a placeholder username for the user/ip input too. Jane/JohnSmith might be recognizable as placeholders but only in certain cultures and translation might be a concern too. How about UserName? Or would that be too generic? Thoughts @Tchanders @Niharika?

Finally, just wanted to ask whether we should make the help text inline? It's the default and recommended for accessibility, though it does make the page a bit busier:

Thanks for the side-by-side comparison @Tchanders 😊Really helpful!

I am quite sure that the user/ip field doesn't need help text, nor does the reason field. What do you think?

The checkbox will definitely need some help text and I think its best if it is visible all the time.


I see. So the alternative would be to keep the button always active but return with an error message if the reason field is not populated? That works for me. We should have a mock for how the error would display. Ping @Prtksxna.

We can have keep the Submit active all the time like other Special pages. @Tchanders, I see that some browsers will prevent you from submitting the form if the inputs aren't valid, but, if IIRC some don't and Special pages have a default way of showing the error — just red colored text in a larger font. Could you confirm if this is the case, and if we're able to change the design of this for our form?

I am quite sure that the user/ip field doesn't need help text, nor does the reason field. What do you think?
The checkbox will definitely need some help text and I think its best if it is visible all the time.

This makes sense to me.

I see that some browsers will prevent you from submitting the form if the inputs aren't valid, but, if IIRC some don't and Special pages have a default way of showing the error — just red colored text in a larger font. Could you confirm if this is the case, and if we're able to change the design of this for our form?

Support for the required attribute seems good: https://caniuse.com/#search=required - and if it's not supported, the submitted form will error as you say:

image.png (383×826 px, 42 KB)

Literally we are able override these designs, but it would be an extra thing to maintain and potentially extra modules to load so I'd advise against it. Other special pages seem to keep consistent with the default design.

@Tchanders, the default error state looks good, per your suggestion, let's keep it as is.

@dbarratt Thanks for checking! Yeah, in use and blocked for being a misleading username 😅According to me, it is okay if what we choose is an existing user, as long as it is clear by our usage that we are only using it as an example.

@Prtksxna This seems really busy to me...

Screen Shot 2019-11-18 at 13.44.47.png (700×1 px, 64 KB)

the placeholder text seems unnecessary.... do we even need it at all?

@dbarratt See screenshots in T237034#5661181 and @Prtksxna's reply in T237034#5670732 - we've removed the help text for the User and Reason widgets to make it less busy, and made the placeholder text more informative instead

@dbarratt See screenshots in T237034#5661181 and @Prtksxna's reply in T237034#5670732 - we've removed the help text for the User and Reason widgets to make it less busy, and made the placeholder text more informative instead

I think it should be taken further and the placeholder text removed.... I'm not sure an example is necessary and it increases the cognitive load without a lot of benefit (that I can see?).

@Prtksxna This seems really busy to me...

Screen Shot 2019-11-18 at 13.44.47.png (700×1 px, 64 KB)

the placeholder text seems unnecessary.... do we even need it at all?

I'm considering moving that checkbox down next to individual records in the table. That will allow gradual addition of users to the table, if warranted, instead of flooding it with all available accounts from same IPs. Might make things a bit easier technically too. This is on my to-discuss list with @Prtksxna tomorrow.

The cause of doing CU is often an SPI or a user request or suspicious edit. In any case, the reason should link to this cause and the form should require this link for the reason.
Would a separate field for the link be better or a two-line reason field?
With two separate fields I think it would be cleaner:

investigate-reason-link.png (180×725 px, 10 KB)

Change 550912 merged by jenkins-bot:
[mediawiki/extensions/CheckUser@master] Add search form fields to Special:Investigate

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

In T237034#5673142, @AronManning wrote:

The cause of doing CU is often an SPI or a user request or suspicious edit. In any case, the reason should link to this cause and the form should require this link for the reason.
Would a separate field for the link be better or a two-line reason field?
With two separate fields I think it would be cleaner:

investigate-reason-link.png (180×725 px, 10 KB)

I see that right now there is one field and a convention to supply a link in that field. Is that not good enough?

@Niharika the field is short for a textual description and a link. Either a longer 2-line textfield or 2 fields would be enough.
In any case, the comments should instruct to paste the link to the cause and form validation should check its presence.
The check is a bit simpler with a separate field, but it is less busy with one longer field.

In T237034#5676979, @AronManning wrote:

@Niharika the field is short for a textual description and a link. Either a longer 2-line textfield or 2 fields would be enough.
In any case, the comments should instruct to paste the link to the cause and form validation should check its presence.
The check is a bit simpler with a separate field, but it is less busy with one longer field.

We can make it a longer field for sure. For form validation to check for the presence of a link - I think we would need the Checkusers to explicitly agree to that being okay. Let's start with the status quo for now. :)

In T237034#5676979, @AronManning wrote:

@Niharika the field is short for a textual description and a link. Either a longer 2-line textfield or 2 fields would be enough.
In any case, the comments should instruct to paste the link to the cause and form validation should check its presence.
The check is a bit simpler with a separate field, but it is less busy with one longer field.

We can make it a longer field for sure. For form validation to check for the presence of a link - I think we would need the Checkusers to explicitly agree to that being okay. Let's start with the status quo for now. :)

Please don't require a link. As a CU on a non-WMF wiki, I almost never put a link in the reason field.

Thanks for that information, @JJMC89. As I mentioned, we have no intention of doing that. :)

@JJMC89 Yes, requiring a link to the cause is unnecessary for private/small wikis. Thanks for mentioning this.
It only matters on wikimedia wikis, where there are strong guarantees of privacy.
@Niharika It can be enabled with a flag in the configuration.

dom_walden subscribed.

Acceptance criteria

  • Form header: Search for usernames, IP addresses or IP ranges
    • All three types will be added in a single text field. We should auto-complete the usernames and still allow IPs/ranges that become "capsules" once they are valid by regex. We did this with Interaction Timeline and should be able to do it here as well.

Currently, we allow arbitrary input (T238318).

  • Input box for usernames. Limit on number of users accepted is 2 (for first iteration).

This will only be true after T237298#5681606 is merged. Currently, can enter any number of users/IPs.

  • Placeholder: UserName or 1.1.1.1

Placeholder text is: UserName or 1.1.1.42

  • Help text: Not required

No help.

  • Usernames and IPs auto-complete

You get a drop down menu of usernames that match the prefix. Clicking on them puts them in a capsule/tags them.

  • Input box for the reason for the check.
    • This a mandatory before the Submit button becomes active.

"Please fill out this field" message appears if you leave input empty.

  • Placeholder text: Not required

Placeholder text is: Example: Investigating UserName for suspected sockpuppetry

  • Help text: Not required

No help.

@Prtksxna I notice the requirements have been updated since the patch, hence the discrepancies in some of the placeholder text found by @dom_walden in T237034#5696564. Should we correct these?

@Prtksxna I notice the requirements have been updated since the patch, hence the discrepancies in some of the placeholder text found by @dom_walden in T237034#5696564. Should we correct these?

Sorry about the confusion around this. Yes, let us remove the placeholder text for Reason (per T238603#5674993) but keep it for the user name/IP input.

@Tchanders Looks like the conversation here got missed. Should I create a new ticket to address the design changes made since your last patch?

@Niharika Sorry I seem to have missed @Prtksxna's comment there. If it's no trouble, a new ticket could make it clearer what needs to happen - thanks.

Change 563244 had a related patch set uploaded (by Tchanders; owner: Tchanders):
[mediawiki/extensions/CheckUser@master] Update messages in Special:Investigate to match new design

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

@Niharika, @Prtksxna - I've updated the acceptance criteria to remove the requirement that the submit button is disabled (as per comments on this task).

The acceptance criteria don't quite match the screenshot in the description - could you confirm that we're working to the acceptance criteria rather than the screenshot?

The acceptance criteria don't quite match the screenshot in the description - could you confirm that we're working to the acceptance criteria rather than the screenshot?

Correct, the screenshot is not up to date.

Change 563244 merged by jenkins-bot:
[mediawiki/extensions/CheckUser@master] Update messages in Special:Investigate to match new design

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