From 0373a7c5169078e9ac9422b172ac8570ac09b5a9 Mon Sep 17 00:00:00 2001 From: Jens Mohrmann Date: Tue, 30 Dec 2025 22:39:19 +0100 Subject: [PATCH] reduce note match threshold_ms --- src/App.tsx | 5 ++++- src/AppConfig.ts | 6 ++++++ 2 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 src/AppConfig.ts diff --git a/src/App.tsx b/src/App.tsx index cb12ba9..db5503b 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -28,7 +28,10 @@ import { Mic, MicOff, SkipForward, HelpCircle, Volume2, X, Guitar, Settings, Max import './App.css'; import './styles/skip-button.css'; -const NOTE_MATCH_THRESHOLD_MS = 300; // How long to convert hold note to confirm +import { NOTE_MATCH_THRESHOLD_MS } from './AppConfig'; + + + function App() { const [listening, setListening] = useState(false); diff --git a/src/AppConfig.ts b/src/AppConfig.ts new file mode 100644 index 0000000..8f144dd --- /dev/null +++ b/src/AppConfig.ts @@ -0,0 +1,6 @@ +/** + * Global application configuration + */ + +// How long (in ms) a note must be held to be accepted as correct +export const NOTE_MATCH_THRESHOLD_MS = 50;