add a minlength to the name form#116
Open
danisyellis wants to merge 1 commit intotannerkrewson:devfrom
Open
Conversation
Hi there, I'm a new player and chose "D" as my name. When I got the "Name too short/long" error message, I couldn't figure out how to change my name. I thought maybe the game was buggy and I couldn't edit it! I had to load the game in a browser on my computer to realize that the pencil was clickable. To me, it's non-obvious on mobile. I thought of a few different ways to fix that problem: - swap the "You, Host" text with the pencil icon. If it came after, I think it would be more obvious that it's a button. We're used to seeing a picture to the left of a person's name, or other text, just as decoration. - add an extra sentence to the error message that says something like "tap the pencil icon to edit" or, if it needs to be as short as the "Name too short/long" line, it could say "Tap pencil to edit". But I'm not sure if your button design has room for a second row of text. -make the pencil smaller and say "edit" underneath - instead of the pencil icon, just use the word edit as a clickable link (maybe with a box, maybe without) Then I realized that both the easiest and most useful way to handle this is to not let the user submit an invalid name in the first place. If you don't like the way that HTML's buit-in minlength handles this, you could write some custom JS to check on button-click if it's > 2 Note: Apologies, but I didn't set up a whole dev environment just to test this small change, so you'll have to do the verification if you want to merge this in.
kedskeds
approved these changes
Jan 12, 2022
danbernardi
approved these changes
Jan 12, 2022
frazermg
approved these changes
Jan 12, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi there,
I'm a new player and chose "D" as my name. When I got the "Name too short/long" error message, I couldn't figure out how to change my name. I thought maybe the game was buggy and I couldn't edit it! I had to load the game in a browser on my computer to realize that the pencil was clickable. To me, it's non-obvious on mobile.
I thought of a few different ways to fix that problem:
-make the pencil smaller and say "edit" underneath
Then I realized that both the easiest and most useful way to handle this is to not let the user submit an invalid name in the first place. If you don't like the way that HTML's buit-in minlength handles this, you could write some custom JS to check on button-click if it's > 2
Note: Apologies, but I didn't set up a whole dev environment just to test this small change, so you'll have to do the verification if you want to merge this in.