fix(settings): restore search-engine switcher in dashboard + desktop#1618
Merged
Conversation
The dashboard's <select> for switching web search backends shipped in #1558 against the old Preact panel; the React port (#1418) dropped it silently and the i18n strings have been dead code since. The desktop settings panel never had it. Both surfaces now expose the same dropdown under General → Behavior, alongside reasoning effort / edit mode / budget — six engines (bing, searxng, metaso, tavily, perplexity, exa) matching the `/search-engine` slash. - protocol: `webSearchEngine` on SettingsEvent + SettingsPatch in both desktop and dashboard mirrors - backend: `src/cli/commands/desktop.ts` settings_save persists the field via writeConfig; emitSettings reads it back via webSearchEngine() - dashboard bridge: emitServerSettings forwards the field from `GET /api/settings` (server side was already wired by #1558) - desktop i18n: copies the six already-translated strings that were living only in the dashboard bundle API keys for metaso / tavily / perplexity / exa still go through the slash command (or config.json) — UI-side key entry can come later if demand shows up.
This was referenced May 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
<select>shipped in feat(web-search): default to Bing, drop Mojeek, dashboard engine switcher #1558 against the old Preactpanels/settings.ts; the React port (feat: port desktop dashboard from Tauri+Preact to CLI-hosted React Web app #1418) dropped it silently. The i18n keys for it have been dead code indashboard/src/i18n/{en,zh-CN}.tsever since./search-engineslash.Changes
protocol.ts(desktop + dashboard):webSearchEngine?added toSettingsEvent+SettingsPatch. Type aliasWebSearchEngineNameexported.App.tsx(desktop + dashboard): same field on theSettingsstate, plumbed through the$settingsreducer.dashboard/src/lib/tauri-bridge.ts:emitServerSettingsforwardswebSearchEnginefromGET /api/settings(server side was already wired by feat(web-search): default to Bing, drop Mojeek, dashboard engine switcher #1558).src/cli/commands/desktop.ts: extendssettings_saveInMessage + handler to persist viawriteConfig;emitSettingsreads back viawebSearchEngine().desktop/src/ui/settings.tsx+dashboard/src/ui/settings.tsx: new<select>row inPageGeneralbehavior section.desktop/src/i18n/{en,zh-CN}.ts: copies the six already-translated strings (label, six engine options, note) that were living only in the dashboard bundle.API keys for metaso / tavily / perplexity / exa still go through the
/search-engine <engine> <key>slash or directconfig.jsonedit — UI-side key entry can come later.Test plan
npm run typecheck(root + dashboard + desktop) cleannpm run lintclean (only pre-existing warning in welcome-banner-hints)npm run test— 3586 passnpm run build:dashboardbuilds cleanwebSearchEnginefield; restart app, value persists; status bar / nextweb_searchcall uses the new engine/api/settingsGET