Skip to content

Voice-to-text dictation app with local (Nvidia Parakeet/Whisper) and cloud models (BYOK). Privacy-first and available cross-platform.

fix: blank screen on upgrade from older onboarding versions

Gabriel Steinee5cddbbb9a5
diff --git a/CHANGELOG.md b/CHANGELOG.md
index f47f6d136..4029ba33d 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
+## [1.2.1] - 2026-01-13
+
+### Fixed
+- **Blank Screen on Upgrade**: Fixed white screen issue for users upgrading from older versions with different onboarding step counts. The onboarding step index is now properly clamped to valid range.
+
## [1.2.0] - 2026-01-13
### Added
diff --git a/package-lock.json b/package-lock.json
index 5c7329a22..fba3053df 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "open-whispr",
- "version": "1.2.0",
+ "version": "1.2.1",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "open-whispr",
- "version": "1.2.0",
+ "version": "1.2.1",
"hasInstallScript": true,
"license": "MIT",
"dependencies": {
diff --git a/package.json b/package.json
index 71e559121..f379e34e8 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "open-whispr",
- "version": "1.2.0",
+ "version": "1.2.1",
"description": "A desktop dictation application using whisper.cpp for speech-to-text transcription",
"main": "main.js",
"private": true,
diff --git a/src/components/OnboardingFlow.tsx b/src/components/OnboardingFlow.tsx
index d0aeb4241..2c03b811e 100644
--- a/src/components/OnboardingFlow.tsx
+++ b/src/components/OnboardingFlow.tsx
@@ -52,12 +52,22 @@ type ReasoningModelOption = {
};
export default function OnboardingFlow({ onComplete }: OnboardingFlowProps) {
+ // Max valid step index for the current onboarding flow (6 steps, index 0-5)
+ const MAX_STEP = 5;
+
const [currentStep, setCurrentStep, removeCurrentStep] = useLocalStorage(
"onboardingCurrentStep",
0,
{
serialize: String,
- deserialize: (value) => parseInt(value, 10),
+ deserialize: (value) => {
+ const parsed = parseInt(value, 10);
+ // Clamp to valid range to handle users upgrading from older versions
+ // with different step counts
+ if (isNaN(parsed) || parsed < 0) return 0;
+ if (parsed > MAX_STEP) return MAX_STEP;
+ return parsed;
+ },
}
);
diff --git a/src/main.jsx b/src/main.jsx
index 54217c45e..e33e3e0fc 100644
--- a/src/main.jsx
+++ b/src/main.jsx
@@ -20,7 +20,9 @@ function AppRouter() {
useEffect(() => {
// Check if onboarding has been completed
const onboardingCompleted = localStorage.getItem("onboardingCompleted") === "true";
- const currentStep = parseInt(localStorage.getItem("onboardingCurrentStep") || "0");
+ // Clamp step to valid range (0-5) for current 6-step onboarding
+ const rawStep = parseInt(localStorage.getItem("onboardingCurrentStep") || "0");
+ const currentStep = Math.max(0, Math.min(rawStep, 5));
if (isControlPanel && !onboardingCompleted) {
// Show onboarding for control panel if not completed