feat: add practice typing mode (no stats, xp, or pb) (@Vishal27alpha)#7482
feat: add practice typing mode (no stats, xp, or pb) (@Vishal27alpha)#7482Vishal27alpha wants to merge 11 commits intomonkeytypegame:masterfrom
Conversation
|
Continuous integration check(s) failed. Please review the failing check's logs and make the necessary changes. |
There was a problem hiding this comment.
Pull request overview
Adds a new practice typing mode intended for “no-stats” sessions, wiring it through shared mode schemas, backend result submission, and default frontend result filters.
Changes:
- Extend shared mode/schema typing to include
practice. - Backend: special-case
practicein result submission (skip PB checks, skip DB insert, XP=0). - Frontend: default result filters mark
practiceas excluded.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| packages/schemas/src/shared.ts | Adds practice to the modes derived from PersonalBestsSchema. |
| backend/src/api/controllers/result.ts | Adds practice handling in result endpoints and XP calculation. |
| frontend/src/ts/constants/default-result-filters.ts | Excludes practice from default stats/result filtering. |
|
You can already turn off result saving in the comand line |
|
Thanks for pointing that out, I wasn’t aware this already existed via the command line. That explains the gap I felt from a user perspective. Would you be open to reframing this PR to focus on exposing the existing practice mode in the UI (making it more discoverable), rather than adding new backend behavior? Happy to adjust or close the PR based on your preference. |
Lets add a "result saving" settin to the account section in the settings page. In the description mention the word 'practice' so its easier to find. We should also add a 'practice' alias to the result saving commandline commands. |
|
Thanks a lot for the clarification that makes perfect sense. -Add a “Result saving” toggle in the Account section of Settings I’ll start exploring this and update the PR accordingly, unless you’d prefer this to be handled as a separate PR instead. |
Same pr is fine |
81ebe27 to
4aa931f
Compare
|
Continuous integration check(s) failed. Please review the failing check's logs and make the necessary changes. |
|
Continuous integration check(s) failed. Please review the failing check's logs and make the necessary changes. |
|
Continuous integration check(s) failed. Please review the failing check's logs and make the necessary changes. |
e6ec9f7 to
ac18f0f
Compare
|
Thanks for the review! reverted the dev-auth change All checks are passing now. |
|
hi @Vishal27alpha , i talked to @Miodec. There was a misunderstanding on where to put the setting. Mio requested the new setting to be added to the settings page under account settings, but that got moved. Please add it to the settings page after presents and before test difficulty. https://monkeytype.com/settings?highlight=difficulty |
|
Thanks for the clarification @fehmer! I’ve moved the result saving setting to the main settings page (between presets and test difficulty) and added the missing active state for the command-line command. |
|
Hi @Vishal27alpha , nice work 👍 To get rid of the
|
fix(settings): move result saving to config and align command metadata - removed localStorage persistence - deleted result-saving command list - added alias to command metadata - reverted unnecessary modal changes#
|
@fehmer I’ve reverted the requested changes and updated the implementation accordingly. |
|
Thanks! Really appreciate the review |
Description
What
Adds a new
practicetyping mode that allows users to type freely without affecting:Why
This enables low-pressure practice sessions while preserving competitive integrity of stats.
How
practicemodeNotes
Relevant files: