Menu launcher lost Walker's web-search fallback for no-match queries
Title: Menu launcher lost Walker's "search the web" fallback for no-match queries
Before Quattro, Walker's websearch provider (via elephant) meant typing a
query with no matching app/setting would still let you hit Enter and get a
web search in your default browser. The new native Omarchy menu (Super+Space)
searches apps/settings/menu entries fine, but there's no fallback at all when
nothing matches — Enter just does nothing.
Checked the actual Menu.qml/MenuModel.js source to confirm this isn't
just undocumented: there's no websearch, google, or similar string
anywhere in /usr/share/omarchy/shell/plugins/menu/. It looks like an
omission from the Walker->native rewrite rather than an intentional drop.
I patched it locally (as a cloned omarchy.menu plugin, so it's easy to
test without touching the packaged copy) and it's a small, surgical change:
in rebuildDisplay(), when a search query produces zero rows, synthesize
one fallback row whose action shells out to omarchy-launch-browser (the
existing helper that already respects the user's actual default browser via
xdg-settings, not any specific browser) with a Google search URL for the
typed query.
Diff against shell/plugins/menu/Menu.qml:
@@ -602,6 +602,29 @@
for (var d = 0; d < drilldownRows.length; d++) drilldownRows[d].section = "drilldown"
}
rows = currentRows.concat(drilldownRows)
+
+ // No app/setting/menu entry matched — fall back to a web search, the
+ // way Walker's "websearch" elephant provider used to.
+ if (rows.length === 0) {
+ rows = [{
+ itemId: "lemec.websearch",
+ kind: "action",
+ icon: "",
+ iconFont: "",
+ appIcon: "",
+ appId: "",
+ label: "Search Google for “" + query + "”",
+ target: "",
+ detail: "",
+ path: "",
+ childCount: 0,
+ action: "omarchy-launch-browser " + Util.shellQuote("https://www.google.com/search?q=" + encodeURIComponent(query)),
+ provider: "",
+ score: 0,
+ section: ""
+ }]
+ }
} else {
for (var j = 0; j < root.itemOrder.length; j++) {
var child = root.item(root.itemOrder[j])
Tested live: reloaded the shell with the cloned plugin, searched a nonsense string, confirmed the fallback row renders, hit Enter, confirmed it opens the actual configured default browser (tested with both Chromium and Brave) at the right Google search URL — and confirmed normal app/setting search is completely unaffected when there IS a match.
Happy to open this as a PR against the packaged menu plugin if that's wanted, or if there's a reason this was left out on purpose I'd like to know so I can stop working around it locally.
Ran into the same gap. One data point from trying to solve it locally, since both open PRs put the fallback in the menu:
I first wired a web search into the menu as a ?? alias in my
omarchy-menu.jsonc extension. It never became muscle memory and, in my setup,
did not reliably fire — so I moved it to a dedicated key (SUPER + Q, which is
unbound on a stock install) and that stuck immediately. The difference for me
was that searching is a starting action, and reaching it through the app menu
means typing a query, watching it fail to match anything, and only then getting
the option.
That is one person's habit, not an argument against the menu fallback — the no-match case in #7075 and #8012 is clearly worth fixing on its own. Just flagging that the two might be complements rather than alternatives, since a dedicated binding needs no menu changes at all.
(What I ended up with, if it is useful to anyone:
https://github.com/HoneySpoons/omarchy-web-search — it uses omarchy-menu-input
and omarchy-launch-browser, so it is mostly glue.)
Went a different way instead of waiting for the fallback: I cloned the menu and added the web row myself (always the last result, opens the default browser). If it helps anyone before the PRs land: https://github.com/outcrop-labs/skal-menu, pending at omacom/omarchy-plugin-marketplace#8193.