Skip to content

FIXED : While selecting any answer the space bar hit showing question is SKIPPED instead of telling INCORRECT ANSWER#72

Open
agneee-dev wants to merge 3 commits into
Razen04:v0.10.8from
agneee-dev:v0.10.8
Open

FIXED : While selecting any answer the space bar hit showing question is SKIPPED instead of telling INCORRECT ANSWER#72
agneee-dev wants to merge 3 commits into
Razen04:v0.10.8from
agneee-dev:v0.10.8

Conversation

@agneee-dev

Copy link
Copy Markdown

What does this PR do?

Implemented keyboard shortcuts to speed up the practice flow and refactored the PracticeCard component into a modular, hook-based architecture.

New Shortcuts:
Q / W (or Arrows): Previous/Next question.
Enter / Space: Submit (if selected) or Show Answer (if empty).
1-5 / A-E: Select options.
/: Open explanation.

Refactor:
Decoupled PracticeCard logic into useAnswerFlow, useQuestionState, and useQuestionNav for better maintainability.

How should this be manually tested?

  • Go to any practice session.
  • Use W and Q to navigate between questions.
  • Press A or 1 to select an option, then hit Enter to submit.
  • On a fresh question, hit Space to reveal the answer without selecting anything.
  • Verify shortcuts are disabled while typing in input fields.

What are the relevant tickets?

Fixes #71

@vercel

vercel Bot commented Apr 30, 2026

Copy link
Copy Markdown

@agneee-dev is attempting to deploy a commit to the razen04's projects Team on Vercel.

A member of the Team first needs to authorize it.

Comment thread src/features/landing/pages/LandingPage.tsx
@Razen04 Razen04 changed the title FIXED : While selecting wrong answer the space bar hit showing question is SKIPPED instead of telling INCORRECT ANSWER FIXED : While selecting any answer the space bar hit showing question is SKIPPED instead of telling INCORRECT ANSWER May 3, 2026
<Eye className="inline text-lg" />
<span className="hidden md:inline ml-2">
Submit <span className="font-mono">[⎵/↵]</span>
Submit {hasSelection && <span className="font-mono">[⎵/↵]</span>}

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This just makes it does not appear until the answer is not selected but it will still work regardless keeping this does not make sense I think. Instead what we can do is disable the Submit button until something is selected or typed in case of NAT and keep the Show Answer as always working cause that is the surrender button.

This will be better UX. Otherwise the thing is already fixed.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay - I am on to it ... i'll let you know after modifying

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 this pull request may close these issues.

2 participants