From 7e7f5fac79f613cfff7f299c99dcb28e3d3a8ada Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Peter=20Babi=C4=8D?= Date: Thu, 18 Mar 2021 15:37:04 +0100 Subject: [PATCH] convert buttons to gray --- src/App.svelte | 6 +++++- src/Button.svelte | 16 +++++++++------- src/LevelButton.svelte | 12 ++++++++---- 3 files changed, 22 insertions(+), 12 deletions(-) diff --git a/src/App.svelte b/src/App.svelte index 48e400c..ced3939 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -114,7 +114,7 @@ } } - printSolutions(1) + printSolutions(-1) } const undo = () => { @@ -245,6 +245,10 @@ } const printSolutions = maxSolutionCount => { + if (maxSolutionCount < 0) { + return + } + let depth = 0 let solutions = [] let gameovers = [] diff --git a/src/Button.svelte b/src/Button.svelte index 2433023..89e5533 100644 --- a/src/Button.svelte +++ b/src/Button.svelte @@ -1,6 +1,5 @@