Skip to content

fix(config): block monkey with live text stats (@d1rshan)#7715

Open
d1rshan wants to merge 3 commits intomonkeytypegame:masterfrom
d1rshan:fix/monkey-live-stats-validation
Open

fix(config): block monkey with live text stats (@d1rshan)#7715
d1rshan wants to merge 3 commits intomonkeytypegame:masterfrom
d1rshan:fix/monkey-live-stats-validation

Conversation

@d1rshan
Copy link

@d1rshan d1rshan commented Mar 24, 2026

Prevents the invalid monkey + live text stats combination (monkey overlaps live speed / live accuracy)

This blocks:

  • enabling monkey while live speed style or live accuracy style is text
  • setting live speed style to text while monkey is enabled
  • setting live accuracy style to text while monkey is enabled

Also adds tests for these blocked config combinations.

Closes #7714

Copilot AI review requested due to automatic review settings March 24, 2026 12:06
@monkeytypegeorge monkeytypegeorge added the frontend User interface or web stuff label Mar 24, 2026
@github-actions github-actions bot added the waiting for review Pull requests that require a review before continuing label Mar 24, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Prevents unsupported UI config combinations that cause the monkey to overlap live stats when those stats use the text style, by blocking the conflicting settings at config-set time and notifying the user (closes #7714).

Changes:

  • Add isBlocked guards + notice toasts for liveSpeedStyle=text / liveAccStyle=text when monkey=true, and for enabling monkey when either live stat style is text.
  • Add setter-level tests verifying the blocked monkey/liveSpeedStyle combination triggers the expected notice.
  • Add metadata-level tests covering blocked combinations for monkey, liveSpeedStyle, and liveAccStyle.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
frontend/src/ts/config/metadata.ts Adds isBlocked rules + user notices to prevent monkey + live text stats conflicts.
frontend/tests/root/config.spec.ts Adds tests asserting setConfig rejects conflicting settings and emits the expected notice.
frontend/tests/root/config-metadata.spec.ts Adds table-driven isBlocked coverage for the new conflict rules.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend User interface or web stuff waiting for review Pull requests that require a review before continuing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

UI: Monkey overlaps live speed/live accuracy when those stats use text style

3 participants