Skip to content

refactor(frontend): rework speech-to-text to tap-first interaction#207

Merged
chriswritescode-dev merged 4 commits intomainfrom
refactor/speech-to-text-ui
Apr 29, 2026
Merged

refactor(frontend): rework speech-to-text to tap-first interaction#207
chriswritescode-dev merged 4 commits intomainfrom
refactor/speech-to-text-ui

Conversation

@chriswritescode-dev
Copy link
Copy Markdown
Owner

Summary

  • Remove hold-to-record gesture entirely; tap mic to start/stop recording
  • Desktop mic uses click only (no swipe handlers that interfere with recording)
  • Mobile swipe-up while recording stops, transcribes, and sends; tap stops and inserts into prompt
  • Clicking outside the mic control while recording now transcribes into the prompt (no longer aborts)
  • Add transcript-append guard so swipe-send waits for new speech before submitting, fixing lost transcript when existing prompt text is present
  • VoiceStatusOverlay shows large arrow with stacked "Swipe / To / Send" text and X at bottom; spinner during starting/processing/sending states

Changes

  • frontend/src/components/message/PromptInput.tsx - Tap-first recording flow, desktop/mobile gesture separation, transcript-append guard, outside-click transcribe behavior
  • frontend/src/components/message/VoiceStatusOverlay.tsx - State-driven overlay with arrow, stacked labels, and loading spinner

Type of Change

  • Bug fix
  • New feature
  • Refactor
  • Documentation

Checklist

  • Code follows project style (no comments, named imports)
  • TypeScript types are properly defined
  • pnpm lint passes locally

…swipe tracking

- Extract voice status overlay to dedicated VoiceStatusOverlay.tsx component
- Move pointer event handlers from button to container for larger swipe surface area
- Users can now initiate swipe gesture from anywhere in the container, not just the button
…ization

- Add SSEMessagePartDeltaEvent type for streaming delta updates
- Add SSESessionCreatedEvent type for session creation events
- Implement directory filtering for SSE events to prevent cross-contamination
- Add version tracking for status snapshots to ignore stale responses
- Replace individual status updates with atomic replaceStatuses operation
- Refactor parts batcher to use unified operation queue with delta support
- Clear stale statuses on initial snapshot and directory changes
- Add tests for status snapshot clearing and stale response handling
…t close behavior

Stop restarting OpenCode after assistant mode initialization since the
startup error logic is no longer needed. Also fix the repo quick switch
sheet to stay open when launched from the mobile tab bar, preventing
unwanted navigation away from the sheet.
@chriswritescode-dev chriswritescode-dev merged commit f0c87ff into main Apr 29, 2026
3 checks passed
@chriswritescode-dev chriswritescode-dev deleted the refactor/speech-to-text-ui branch April 29, 2026 16:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant