From 8d501d42a3788c5cc862e3ccca9199523fa80a4b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20R=C3=B6ger?= Date: Fri, 21 Aug 2026 14:14:24 +0200 Subject: [PATCH] feat(web): add solution space info --- src/lib/wasm.rs | 4 ++-- web/src/App.svelte | 23 ++++++++++++++++--- web/src/components/WordleLine.svelte | 4 ++-- web/src/solver/solver.ts | 34 ++++++++++++++++++++-------- web/src/solver/types.ts | 23 +++++++++++++++---- web/src/solver/worker.ts | 26 ++++++++++++++++----- 6 files changed, 88 insertions(+), 26 deletions(-) diff --git a/src/lib/wasm.rs b/src/lib/wasm.rs index bbe268e..1854a20 100644 --- a/src/lib/wasm.rs +++ b/src/lib/wasm.rs @@ -58,8 +58,8 @@ impl Solver { .collect() } - pub fn solution_space(&self) -> u64 { - self.0.stats().0 + pub fn solution_space(&self) -> u32 { + self.0.stats().0 as u32 } pub fn solution_space_uncertainty(&self) -> f64 { diff --git a/web/src/App.svelte b/web/src/App.svelte index b792ade..030fef4 100644 --- a/web/src/App.svelte +++ b/web/src/App.svelte @@ -1,7 +1,8 @@