Skip to content

fix(server): recover the results page when a scope filters everything out#82

Merged
ErikChevalier merged 1 commit into
mainfrom
fix/empty-scope-recovery
Jun 11, 2026
Merged

fix(server): recover the results page when a scope filters everything out#82
ErikChevalier merged 1 commit into
mainfrom
fix/empty-scope-recovery

Conversation

@ErikChevalier

Copy link
Copy Markdown
Contributor

Problem

On the served results page the scope bar only rendered when results existed. An include scope that matched nothing (e.g. "Recipes" on a threejs search) produced a blank "No results" page with no way to see or clear the scope that hid the results, and re-searching kept filtering to empty because the scope persisted invisibly.

Fix

The empty-results branch now (for the loopback owner):

  • renders the scope bar so the active scope is visible and switchable,
  • attributes the emptiness to the scope: "No results match the '{scope}' scope for '{query}'.",
  • offers a one-click Clear scope that posts an empty lens and returns to the same query unfiltered.

Mirrors the desktop fix (SearchMob-Desktop#88).

Verification

  • New test in WebUiPersonalizationTest drives a real loopback server with an active scope + empty provider and asserts the scope bar, the scope-attributed message, and the clear-scope control. ktlint + full unit suite green.

🤖 Generated with Claude Code

… out

On the served results page the scope bar only rendered when there were
results, so an include scope that matched nothing left a blank "No results"
page with no way to see or clear the scope that hid them. Re-searching kept
filtering to empty because the scope persisted invisibly.

The empty-results branch now renders the scope bar, attributes the emptiness
to the active scope ("No results match the '<scope>' scope for '<query>'"),
and offers a one-click "Clear scope" that posts an empty lens and returns to
the same query unfiltered. Owner-only, like the rest of the in-page controls.

Mirrors the desktop fix.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ErikChevalier ErikChevalier merged commit f772112 into main Jun 11, 2026
2 checks passed
@ErikChevalier ErikChevalier deleted the fix/empty-scope-recovery branch June 11, 2026 01:09
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.

1 participant