Fix/restrict clues to active spymaster#78
Merged
Conversation
…lues-to-active-spymaster
|
the-only-queen-anna
approved these changes
Jun 12, 2026
Collaborator
Author
Guesses würd ich fix drinnenlassen, Spymaster sollen auch live sehen wie viele guesses noch übrig sind usw. Bei Hint: weiß ich es nicht ganz weil wenn ein Clue reinkommt kommt dann ja auch Hint: das signalisiert ja auch ok ein Clue ist noch nicht reingekommen.. |
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.



Context
This PR fixes the frontend clue submission flow so only the active team’s spymaster can enter and send clues.
Description
Spymasters can now only access the clue input when their own team is currently in the spymaster phase. The inactive spymaster still sees the current clue like other players, but cannot enter or submit a new clue.
The clue submission flow now uses the current player’s actual team from the lobby state instead of deriving the team from the current turn. This prevents a spymaster from the wrong team from submitting a clue as the active team through the normal frontend flow.
Changes in the code base
Restrict clue input visibility to the active spymaster
Show the current clue to inactive spymasters instead of the clue input
Pass the current player team into clue submission
Validate clue submission against the active spymaster turn
Add ViewModel tests for active-spymaster clue validation and error handling
Add UI test coverage for inactive spymasters not being able to enter clues
Remove unused game connection parameters from the frontend ViewModel flow
Changes outside the code base
N/A
Additional information
N/A