From 5f9c35db1e033456c615db257e77f38a898ff9e9 Mon Sep 17 00:00:00 2001 From: Markus Graf Date: Sun, 29 Mar 2026 21:03:57 +0200 Subject: [PATCH] feat: dev shortcut Ctrl+Shift+X to wipe IndexedDB and restart Co-Authored-By: Claude Opus 4.6 (1M context) --- src/app.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/app.ts b/src/app.ts index da70c98..96ff8c7 100644 --- a/src/app.ts +++ b/src/app.ts @@ -188,6 +188,15 @@ export async function initApp(): Promise { e.preventDefault(); showParentCodePrompt(); } + // Dev shortcut: Ctrl+Shift+X to wipe all data and restart + if (e.ctrlKey && e.shiftKey && e.key === "X") { + e.preventDefault(); + if (confirm("DEV: Alle Daten löschen und neu starten?")) { + const delReq = indexedDB.deleteDatabase("zauberwald"); + delReq.onsuccess = () => location.reload(); + delReq.onerror = () => location.reload(); + } + } }); const progress = await getProgress(db);