diff --git a/web/app.ts b/web/app.ts index a05ccc2..12c2372 100644 --- a/web/app.ts +++ b/web/app.ts @@ -359,10 +359,13 @@ function bindMicButton(): void { micBtn.addEventListener("pointerdown", (e: PointerEvent) => { if (e.button !== 0) return; e.preventDefault(); + // Capture pointer so pointerleave won't fire while held + micBtn.setPointerCapture(e.pointerId); startRecording(); }); micBtn.addEventListener("pointerup", (e: PointerEvent) => { e.preventDefault(); + micBtn.releasePointerCapture(e.pointerId); stopRecording(); }); micBtn.addEventListener("pointerleave", () => { diff --git a/web/style.css b/web/style.css index 2cd0aa9..b786332 100644 --- a/web/style.css +++ b/web/style.css @@ -198,6 +198,7 @@ header h1 { display: flex; align-items: center; justify-content: center; + touch-action: none; } #mic-btn {