Skip to content

omamobile-shell: open native app search from the Home dock - #612

Open
marselnenaj wants to merge 1 commit into
derekross:mainfrom
marselnenaj:codex/native-app-search
Open

marselnenaj wants to merge 1 commit into
derekross:mainfrom
marselnenaj:codex/native-app-search

Conversation

@marselnenaj

@marselnenaj marselnenaj commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Native app Search is an opt-in launcher setting. Turning on nativeSearch opens the separate app search when tapping the dock. With the default setting, the dock and swipe up still open the App Library and its existing agent flow.

Search uses the existing application catalog, drawer palette and shell icon font. It joins the common Back surface list as app search. Back first dismisses the keyboard and then closes Search. While Search is visible, Home pauses its widgets and yields Back. The two always-mapped Search layers count as screen furniture. The Home strip retains the keyboard-scoped lock condition from main.

Verification

  • The complete local shell package suite and policy check pass. Qt exercises keyboard-first routing and Search dismissal without sending Escape to the app underneath. Tests also cover the opt-in default, the Search layer names, and a stale lock observation with the keyboard hidden.
  • The previously captured offscreen light and dark previews used the Omarchy 4.0.6 and 4.5 modules. Review media are outside the source tree.
  • The exact package still needs a phone run with first-tap keyboard, touch typing, both Back edges, Home, immediate reopen, manual keyboard hide and lock. The smoke report, Back state output and phone captures remain pending.

marselnenaj added a commit to marselnenaj/omarchy-mobile that referenced this pull request Nov 10, 2026
Restore the phone's Ask Agent card and editable in-place conversation.
Only explicit Send submits a task. Back returns to Search, Home closes it,
and closing or locking cancels active work without reviving stale input.

Use the configured provider and its existing account environment. The first
native adapter supports Codex with workspace-write; other providers retain
an explicit terminal handoff. Keep credentials with the CLI, bind requests
and completed conversation identities, acknowledge cancellation/reset and
preserve task artifacts. Never enable approval or sandbox bypass flags.

Exercise the actual QML/Python transport against inert CLIs, including
failed-turn continuity, account changes and local transport recovery. Add
Quickshell to CI/check dependencies and include neutral themed screenshots
and an actual component recording. Phone acceptance remains outstanding.

Depends on the native Search core in derekross#612; allocate the version at merge.

Co-Authored-By: Codex <codex@openai.com>
@derekross

Copy link
Copy Markdown
Owner

Thank you, @marselnenaj. This is careful work: the focus requests are generation-guarded, Search gives its input back before an app or the lock can take it, Back and Home are handled in the shell, the Omarchy focus prime is credited with its licence, and nearly everything visual comes from Commons and the applied theme. I checked the calls you use against the signed Omarchy 4.0.6-1 and 4.5.0-3 packages and they are all there (Style.duration only on 4.5, which you guard). CI is green.

Before I can take it:

  1. The version. Main shipped omamobile-shell 0.2.114 today, and because your branch sets the same number the merge is clean and would republish 0.2.114 with different contents. I'll give it the next free number at merge (0.2.115, or 0.2.116 if my weather fix lands first), so nothing for you to do except not to rely on the number.
  2. The review images. Please take docs/review-evidence/ out of the commit and attach the images to the pull request instead (dragging them into the description works). They're useful here, but I don't want review media in the tree.
  3. A run on a phone. This changes what a tap on the dock does on every phone, and the parts that matter most can't be shown offscreen: the keyboard coming up on the first tap after the short exclusive-focus prime, keyboard touches straight after it, Back from both edges, Home, reopening at once, hiding the keyboard by hand, and a lock taken with Search open. Could you run this exact head on your phone and add the tools/phone-smoke report, the phone, uname -r, and a screenshot in a dark and a light theme? I'll do the same on my Pixel 7 Pro before merging.

Three things on the look, where I'd like it to match the rest of the shell:

  • The close, search and chevron marks are inline SVG paths. Everywhere else, including the dock's own search pill, we use the icon font at Style.font.iconLarge. Could Search use the same glyphs?
  • mobile-search-backdrop-alpha and mobile-search-card-alpha are new theme keys that no Omarchy theme has. I'd rather not add keys of our own: the drawer's surface and Commons.Color.menu.scrim would keep Search looking like the drawer it sits next to. If you think the translucent tint matters, tell me why and I'll think about it.
  • The 0.72, 0.60 and 0.06 tints: is there a reason not to use the secondary ink the launcher already has (Qt.darker(root.foreground, 1.3))?

One decision is mine: whether this is the default tap now or starts as opt-in (nativeSearch false) for a release. I'll say which once I've used it on the phone.

And two questions. Back.qml now imports ../omamobile.launcher/AppsSearchLink.js and relies on sharing one library instance with the launcher: what happens on a phone where the launcher plugin isn't linked, does the back gesture still load? And with Search open and the keyboard hidden, is the Home strip still mapped in the moment a lock is taken?

@marselnenaj
marselnenaj force-pushed the codex/native-app-search branch from 7ea2e8f to 1b37705 Compare November 10, 2026 22:37
@marselnenaj

Copy link
Copy Markdown
Contributor Author

Thanks for the review. The updated Search uses the shell glyphs and existing drawer colors. I removed the review media from the source tree and retained the upstream version. The default remains for you to decide.

The static import could prevent Back from loading without the launcher. The optional client now loads only when available. The fixture exercises the full Back component body with inert surface imports and verifies the Escape fallback with no launcher directory, and the shared Search close path with the launcher present.

The old strip condition required an open keyboard to suppress the strip on lock. The new condition suppresses it whenever the launcher observes a lock. Since the observation refreshes around keyboard transitions, I haven't verified whether the strip unmaps immediately when a lock starts with the keyboard already hidden. The physical test sequence and smoke report remain pending. I have the refreshed offscreen captures locally and still need to upload them through GitHub's attachment UI.

@derekross

Copy link
Copy Markdown
Owner

Thank you, @marselnenaj. The look is where I wanted it: icon-font glyphs, the drawer's surface and scrim, the launcher's secondary ink, no keys of our own, and the review images are out of the tree. Thanks too for the straight answers on what you haven't verified.

Main moved under you this afternoon, and that's the main thing now. #643 (omamobile-shell 0.2.117) changed how Back works for the whole phone: Back.qml asks a shared list, plugins/omamobile.back/BackLink.js, before it sends Escape. The order is the on-screen keyboard first (Back hides it and does nothing else), then the topmost shell surface that registered, then Escape. Your branch is based on 0.2.116 and conflicts in Back.qml. Please rebase and build on that design instead of resolving the conflict around it:

  1. Register Search with Back's list, and leave Back.qml alone. In Launcher.qml, a Loader of ../omamobile.back/BackLinkClient.qml (its header shows the four lines) with item.name = "app search", a handler that calls closeSearch(), and item.active bound to searchOpened. Then the first Back puts the keyboard away and Search stays, the next Back closes Search, and a sheet that opens over Search is asked before it. AppsSearchLink.js, AppsSearchLinkClient.qml, the createComponent loader and test/back-search-link.py can all go; the Loader already covers a missing plugin, as it does for the other plugins. test/back-surfaces.py needs "omamobile.launcher/Launcher.qml": ["app search"] in EXPECT (it fails any plugin that registers without being listed), and the Back table in plugins/README.md a row.
  2. Tell the home screen about the two new windows. HomeModel.js now has BACK_FURNITURE: layer surfaces that are part of the screen. Anything else that maps counts as "open over the home screen", and while it is, the home screen doesn't take Back (edit mode, its sheets, back to the home page). Your omamobile-app-search and omamobile-app-search-background windows are always mapped and aren't on that list, so as far as I can read it the home screen would lose its Back for good. Please add both, and let Home know when Search is open the way it knows about the drawer (it reads drawerProgress from the launcher's root through DrawerLink; searchOpened is on the same root), so Back isn't the home screen's under an open Search and the widgets pause.
  3. The strip and the lock. stripShown went from !(oskOpen && sessionLocked) to !sessionLocked. sessionLocked is only re-read when the keyboard comes or goes and once 1.5 s later, so it can stay true after an unlock with no keyboard change (the lock's keyboard folds, then a fingerprint unlock). On main that only matters while the keyboard is up; with your change it would unmap the home pill over every app until the keyboard next moves. That was my question's fault as much as anything. Please keep main's term and add only || searchOpened: Search already closes itself when the lock is seen, and the lock covers the strip.
  4. Version. The branch no longer bumps it, so it would ship as whatever main has. I'll set it at merge; it's 0.2.118 as of today.
  5. The phone run is still open, as you say: this package on your phone after the rebase, with the tools/phone-smoke report, the phone, uname -r, and a dark and a light screenshot. Please include: Back with the keyboard up (only the keyboard goes), Back again (Search closes), a tap on the field after that (the keyboard returns), and omarchy-shell shell call omamobile.back state '' with Search open and closed.

On the decision that's mine: I'd like this to start as opt-in. Please make nativeSearch default to false in the manifest and test settings.nativeSearch === true in activateDock() and the placeholder, so a phone without the key keeps today's tap. Nobody has used it on a phone yet, and the focus hand-over is the part I most want to see on real hardware before it becomes everyone's dock. Once it has been in use for a release I'll turn it on by default.

Small things while you're there: the comment at AppsSearch.qml:118 still talks about glass, and the README's "Native app Search" section has a sentence that stops mid-way ("a Search opened over fullscreen can") and describes the old Back client.

I'll run it on my Pixel 7 Pro once it's rebased.

Use the existing app catalog and shell theme for a touch-sized search
surface. Leave the current dock tap and App Library as the default.
Prime keyboard focus briefly and release Search input on close, app
launch, or observed lock.

Register Search through the shared Back client. While the keyboard is
visible, the first Back dismisses it and the next Back closes Search.
Keep the always-mapped Search windows out of Home's covering-layer
census and pause Home from the explicit Search state.

The native focus prime follows Omarchy's MIT-licensed KeyboardPanel
pattern. Keep its attribution in LICENSE.omarchy.

Co-Authored-By: Codex <codex@openai.com>
@marselnenaj
marselnenaj force-pushed the codex/native-app-search branch from c5d8cff to 934af86 Compare November 11, 2026 00:25
@derekross

Copy link
Copy Markdown
Owner

Thank you, @marselnenaj. That was a fast and complete turn: Search registers through BackLinkClient and Back.qml is untouched, both windows are in BACK_FURNITURE, Home reads searchOpened through the drawer link, the strip keeps main's lock term, and the option is off unless someone turns it on. The test for a missing key and the keyboard-first Back case are what I'd have asked for. CI is green on this head and it merges cleanly onto today's main.

Two things in the code, then the phone:

  1. Search can lock itself out. openSearch(), open() for the apps-search view and AppsSearch.open() all refuse while sessionLocked is true. That value is only re-read when the keyboard comes or goes, and once 1.5 s later. So: Search open with the keyboard up, Power, the keyboard folds and the lock is seen (Search closes, good), the re-check 1.5 s later still says locked, and I unlock with the PIN pad or a finger a few seconds after that. Nothing moves the keyboard on the home screen, so as far as I can read it sessionLocked stays true and a tap on the dock does nothing until some other text field raises the keyboard. It's the staleness I described for the strip last time, now on the open path. Could the tap ask instead of trusting the cache: start lockCheck on the tap and open when it answers false? Closing Search when a lock is seen can stay as it is. apps-search-routing.js currently asserts the refusal on the cached value, so it needs a case for an unlock with no keyboard change.

  2. The two Search windows are mapped on every phone, also with the option off. I asked for the opt-in so that a phone without the key is exactly as it is today, and two more full-screen layers over every app isn't quite that. Could both bind visible to root.settings.nativeSearch === true? Once the option is on they stay mapped for the session, so your reason for keeping them mapped still holds.

  3. The phone run is the last open point, as you say. This package on your phone, with the tools/phone-smoke report, the phone, uname -r, and a dark and a light screenshot. The steps: first tap (the keyboard comes up), typing straight away, Back with the keyboard up (only the keyboard goes), Back again (Search closes), a tap on the field after hiding the keyboard (it returns), Back from both edges, Home, reopening at once, omarchy-shell shell call omamobile.back state '' with Search open and closed, and the lock case from point 1: lock with Search open, unlock after a few seconds, tap the dock.

One small thing while you're there: AppsSearch.qml still has a few lines with several statements or a whole component on them (the result row's icon and its fallback letter, the clear button). One statement per line, as in the other plugins, please.

I'll set the version at merge, and I'll run it on my Pixel 7 Pro once the two points are in, with the option off and on.

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