Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(admin): Hiding questions happen automatically between rounds #198

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

joshzcold
Copy link
Owner

  • automatically hide questions between rounds. Move the button down near the main controls. I believe this is closer UX wise to what our users would want either hosting in person or online.

Fixes: #195

- automatically hide questions between rounds. Move the button down near
  the main controls. I believe this is closer UX wise to what our users
  would want either hosting in person or online.
@joshzcold joshzcold added the enhancement New feature or request label Mar 8, 2025
@joshzcold joshzcold requested a review from karlromets March 8, 2025 04:13
@joshzcold joshzcold self-assigned this Mar 8, 2025
Copy link

github-actions bot commented Mar 8, 2025

Test Results

27 tests   27 ✅  55s ⏱️
 8 suites   0 💤
 1 files     0 ❌

Results for commit 57b8735.

Copy link
Collaborator

@karlromets karlromets left a comment

Choose a reason for hiding this comment

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

It would be good to turn this off for the final round since it doesn't do anything there.

After that, we should add a test in settings.spec.ts to check that the button gets disabled - something like "should block hiding questions in the final round".

Otherwise a banger 👍

game.settings.hide_questions = !game.settings.hide_questions;
setGame((prv) => ({ ...prv }));
send({ action: "data", data: game });
}}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
}}
}}
disabled={game.is_final_round}


let textColor = game.settings.hide_questions ? "text-foreground" : "text-foreground";
let buttonColor = game.settings.hide_questions ? "bg-secondary-500" : "bg-secondary-300";
let textContent = game.settings.hide_questions ? t("Show questions") : t("Hide questions");
Copy link
Collaborator

Choose a reason for hiding this comment

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

If disabled opacity-50 or something like that to indicate button is unclickable visually as well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: automatically check the "Hide questions" button when selecting "Next round"
2 participants