feat(learning): progressive step hints with gated solution reveal#65
Merged
Conversation
Derssa
approved these changes
Jul 17, 2026
OthmaneZ05
added a commit
that referenced
this pull request
Jul 18, 2026
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.
Summary of Changes
The roadmap player now surfaces the
hints[]andsolutionfields that the roadmap format has carried since v1. Between the instruction and the failure message, a learner who is stuck gets a middle rung: progressive hints revealed one at a time, with the full solution as a distinct, gated last step.useLearningPlayerasrevealedHintsByStepId(mirrorsresultsByStepId: reset on roadmap open/close, kept across step navigation) — the natural seam for the upcoming local-progression persistence to pick up.renderInstruction+CodeBlock) moved fromRoadmapPlayer.tsxto a sharedInstructionMarkdown.tsxso hints and solutions render code fences exactly like instructions (mechanical extraction, no behavior change).Types of Changes
Verification & Testing
Automated Checks
npm run lintsuccessfully with no errorsnpm run buildsuccessfully with no compilation errorsnpm testsuccessfully (all tests pass)Manual Verification
Frontend suite: 213 tests green (10 new —
StepHints.test.tsxcovers ordered reveal, no skipping, the two-click solution brake, solution-only and hint-less steps, revisit with persisted state;useLearningPlayer.test.tscovers increment/clamp, per-step persistence across navigation, reset on open/close). Backend suite untouched and green (217).End-to-end against real Docker (headless Chrome driving the app on the example roadmap): 17/17 checks — revealed hints survive step navigation, the solution brake arms then reveals, the arming resets when leaving the step, a 1-hint step without solution shows no solution button, and the FR locale renders all new labels.
Checklist