Skip to content

Add ReviewMode toggle for inline hints and solutions in handouts#99

Merged
PatrikBak merged 1 commit into
mainfrom
patrik/handout-review-mode
May 15, 2026
Merged

Add ReviewMode toggle for inline hints and solutions in handouts#99
PatrikBak merged 1 commit into
mainfrom
patrik/handout-review-mode

Conversation

@PatrikBak
Copy link
Copy Markdown
Owner

Summary

  • Adds \newif\ifReviewMode to data/handouts/_template.tex. When a handout sets \ReviewModetrue in its preamble, each \Problem renders its hints (Hint 1., Hint 2., ...) and \Solution. inline below the statement, and each \Exercise renders its \Solution. inline below the statement.
  • The existing \DisplayExerciseSolutions / \DisplayHints / \DisplayProblemSolutions calls at the end of every handout naturally become no-ops in review mode, so no per-handout edits are needed.
  • Adds a singular \captionHint per language (EN "Hint" / SK "Návod" / CS "Návod") used for the inline hint labels; the existing plural \captionHints (used for end-of-doc section headers) is untouched.
  • Couples review mode to "show texts" so Example solutions also render under review (Theorem proofs already always render).
  • Default is off; existing handouts render byte-comparably.

Opt-in \ReviewModetrue in a handout's preamble inlines each Problem's
hints and solution directly below its statement and each Exercise's
solution below its statement, so review reads top-to-bottom instead of
flipping to end-of-document sections. The bare \DisplayExerciseSolutions
/ \DisplayHints / \DisplayProblemSolutions lines already in every handout
become no-ops under review mode, so no per-handout edits are needed.
Default behavior is unchanged.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 15, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
math-comps Ready Ready Preview, Comment May 15, 2026 2:02pm

@PatrikBak PatrikBak enabled auto-merge May 15, 2026 14:00
@PatrikBak PatrikBak merged commit 1d5b2e9 into main May 15, 2026
4 checks passed
@PatrikBak PatrikBak deleted the patrik/handout-review-mode branch May 15, 2026 14:04
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.

1 participant