]> git.cworth.org Git - lmno.games/commitdiff
anagrams: Add a "Noe, I'm done" button to the "Still playing?" dialog
authorCarl Worth <cworth@cworth.org>
Mon, 9 Mar 2026 03:08:17 +0000 (23:08 -0400)
committerCarl Worth <cworth@cworth.org>
Mon, 9 Mar 2026 03:08:17 +0000 (23:08 -0400)
This just dismisses the dialog.

I think it's important to add this because when theh dialog pops up it
triggers a natural reaction to want to click something to make it go
away. But when it hhas only one button, and that button isn't what you
want, it's mildly unnerving to just sit there and watch the countdown.

Much better to let the player answer the question the game is asking.

anagrams/anagrams.jsx

index 45c52eb97b95f3cb661739952b9c47f7a6ddc1ac..4a13e90d5021893f722f14572316dd6a376ddc4b 100644 (file)
@@ -1048,6 +1048,9 @@ class Game extends React.Component {
             <button onClick={() => this.still_looking()}>
               Still looking
             </button>
+            <button onClick={() => this.setState({ game_ending: false })}>
+              Nope, I'm done
+            </button>
           </div>
         </div>
       ) : null