-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Labels
Universal dictationSpeech-to-text transcription anywhere on the web.Speech-to-text transcription anywhere on the web.
Description
Expected: When dictating, transcribed text should be inserted at the caret position, preserving any text before and after. If the caret cannot be determined, insert at the end.
Actual: Transcribed text is always appended to the end of the target field.
Steps to Reproduce:
- Focus a text field with existing content (e.g., type “Hello |world”, caret between “Hello” and “world”).
- Start dictation and speak a short phrase.
- Observe that text is appended at the end rather than inserted at the caret.
Impact: Breaks editing workflows; users cannot dictate into the middle of text without losing position.
Proposed Fix:
- Update input/textarea insertion to use
selectionStart/selectionEndwhen available. - Insert computed delta at caret during accumulation; use replace-all only when server-merges or out-of-order corrections happen.
Acceptance Criteria:
- Dictated text inserts at caret for inputs/textarea and contenteditable editors.
- Pre-existing text is preserved before and after insertion point.
- The caret position should advance after insertion, as if the user had typed the text.
-- E.g. "Hello |world" + "beautiful" -> "Hello beautiful |world" - Out-of-order responses and server merges still produce correct final text.
- A new unit test(s) are introduced to cover this scenario; they fail before the fix and pass after.
- All tests pass, including out-of-order and formatting cases.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Universal dictationSpeech-to-text transcription anywhere on the web.Speech-to-text transcription anywhere on the web.