Skip to content

Add voice search to native input#8092

Merged
joshliebe merged 1 commit intodevelopfrom
feature/josh/voice-search-native-input
Mar 27, 2026
Merged

Add voice search to native input#8092
joshliebe merged 1 commit intodevelopfrom
feature/josh/voice-search-native-input

Conversation

@joshliebe
Copy link
Copy Markdown
Contributor

@joshliebe joshliebe commented Mar 26, 2026

Task/Issue URL: https://app.asana.com/1/137249556945/project/488551667048375/task/1213814620948013?focus=true

Description

  • Adds private voice search to native input

Steps to test this PR

With native input enabled

  • Enable private voice search
  • Tap the microphone button on the native input
  • Verify that it works as expected (both search and Duck.ai)

Note

Medium Risk
Integrates voice search into native input and alters voice-result routing (search vs Duck.ai), which could affect user flows around input/keyboard and Duck.ai submission behavior.

Overview
Adds a voice-search entry point to the native input widget: the widget can now show a mic button (gated by VoiceSearchAvailability) and report clicks via a new NativeInputCallbacks.onVoiceSearchPressed callback.

Updates voice search handling to support two modes (SEARCH vs DUCK_AI): native input can launch voice search in the appropriate mode, search results now hide native input without animation before populating the omnibar, and Duck.ai voice results are routed into native input (auto-selecting the chat tab and submitting the message) when native input is enabled, otherwise falling back to opening DuckChat.

Written by Cursor Bugbot for commit 6687035. This will update automatically on new commits. Configure here.

Copy link
Copy Markdown
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@joshliebe joshliebe force-pushed the feature/josh/voice-search-native-input branch from 5dcf6a1 to 2f60657 Compare March 26, 2026 15:44
Copy link
Copy Markdown
Contributor

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix prepared a fix for the issue found in the latest run.

  • ✅ Fixed: Voice search always uses Duck AI mode ignoring tab
    • Updated the native input voice click handler to pass isChatTabSelected() so voice search mode now matches the currently selected tab.

Create PR

Or push these changes by commenting:

@cursor push 6767a2570a
Preview (6767a2570a)
diff --git a/app/src/main/java/com/duckduckgo/app/browser/nativeinput/NativeInputManager.kt b/app/src/main/java/com/duckduckgo/app/browser/nativeinput/NativeInputManager.kt
--- a/app/src/main/java/com/duckduckgo/app/browser/nativeinput/NativeInputManager.kt
+++ b/app/src/main/java/com/duckduckgo/app/browser/nativeinput/NativeInputManager.kt
@@ -401,7 +401,7 @@
             hideMainButtons()
             if (voiceSearchAvailability.isVoiceSearchAvailable) {
                 setVoiceButtonVisible(true)
-                onVoiceClick = { callbacks.onVoiceSearchPressed(true) }
+                onVoiceClick = { callbacks.onVoiceSearchPressed(isChatTabSelected()) }
             }
         }
         bindSearchCallbacks(widgetView, callbacks)

@joshliebe joshliebe force-pushed the feature/josh/voice-search-native-input branch from 2f60657 to 015e10d Compare March 26, 2026 15:55
@joshliebe joshliebe force-pushed the feature/josh/voice-search-native-input branch from 015e10d to 6687035 Compare March 27, 2026 09:11
Copy link
Copy Markdown
Contributor

@malmstein malmstein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works as expected!

@joshliebe joshliebe merged commit 2ea96f2 into develop Mar 27, 2026
13 checks passed
@joshliebe joshliebe deleted the feature/josh/voice-search-native-input branch March 27, 2026 13:45
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.

2 participants