Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On the last level, pressing enter to go to next screen doesn't work #193

Open
gm1357 opened this issue Oct 6, 2020 · 4 comments · May be fixed by #205
Open

On the last level, pressing enter to go to next screen doesn't work #193

gm1357 opened this issue Oct 6, 2020 · 4 comments · May be fixed by #205

Comments

@gm1357
Copy link
Contributor

gm1357 commented Oct 6, 2020

Only works clicking on the next button.

Tested on Firefox and Chrome.

@hedgecox
Copy link

hedgecox commented Oct 9, 2020

I've had a quick look at this, the problem appears to be because there are two valid answers

flex-direction: column-reverse;
align-content: space-between;
flex-wrap: wrap-reverse;
justify-content: center;

and

flex-flow: column-reverse wrap-reverse;
align-content: space-between;
justify-content: center;

Everything works as expected if you use the 4 line answer, however when using the 3 line answer the game.js does a check when the user presses enter to check the number of lines is the same as the expected answer and as it is less the button click is not triggered.

This could be fixed by adding a silent check each time the user presses enter incase it has been solved in less lines than expected however calling the check() function would cause the analytics functions to be called more than expected. As far as I can tell this question is the only one with multiple different answers so the problem shouldn't appear anywhere else...

@thomaspark
Copy link
Owner

Ahhh that explains it, thanks for the investigation @hedgecox.

This behavior is intended to avoid negative feedback when someone is simply entering a new line, which could get annoying and discouraging.

One approach is to have users hit enter a few times, and when the max lines is reached (even with blank lines), the answer is checked. This could be coupled with an alternate key combo to force checking, like shift-enter.

The second approach, which I'm leaning towards, is what @hedgecox suggests. The silent check would avoid the negative feedback shake, and only mark it if it's correct. It could help in another levels too if someone keeps multiple properties on one line, which isn't advised but could happen.

@thomaspark
Copy link
Owner

Turns out you can already hit control-enter or command-enter to force submit.

glebkema added a commit to glebkema/flexboxfroggy that referenced this issue Oct 19, 2020
@ADTC
Copy link

ADTC commented Apr 20, 2021

I hit this snag too! After all, we've learned flex-flow as a shorthand, so I'd expect the answer to be accepted as well. 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants