Skip to content

feat v4.1: add universal search - #604

Merged
lightbulbman merged 14 commits into
core-betafrom
feat/universal-search/core
Oct 19, 2026
Merged

lightbulbman merged 14 commits into
core-betafrom
feat/universal-search/core

Conversation

@lightbulbman

Copy link
Copy Markdown
Contributor

Summary

Adds a universal search to the plugin header that searches snippets, settings, stats, the welcome screen, the docs and the Cloud Community from one field, with a full results page.

Search bar

  • Searches as the query is typed, grouped by source, with scope chips, keyboard navigation (↑ ↓ ↵ Esc) and a / shortcut to focus the field.
  • Shows the matched line of code beside the active result.
  • Runs an AI search of the Cloud Community alongside the keyword search, with a longer typing delay, and lists its top results in an "AI results" group.
  • Shows a Cloud Library upgrade prompt when upgrade prompts are enabled, or a prompt to connect to Code Snippets Cloud.

Results page (subpage=search)

  • Tabs for each source, plus a Search with AI tab.
  • Every result uses the snippets table row layout: activation switch (local snippets only), title, description clipped to three lines, source path, a "Found in – Line X" bar that opens the matched code, type badge and actions.
  • A Search tab appears first in the toolbar while the page is open.

REST API

  • GET /code-snippets/v1/search with q, sources, fields, method (term or ai), per_source, excerpts and network parameters.

Fixes

  • A cloud error reply (success: false) is no longer read as a list containing one empty snippet.

Testing

  • npm run test:php: 403 tests pass, including a new case for cloud error replies.
  • tests/e2e/universal-search.spec.ts: 52 tests pass across the database and file-based snippet projects.
  • Checked manually against a local cloud API with AI search enabled.

🤖 Generated with Claude Code

@lightbulbman lightbulbman changed the title feat: add universal search feat v4.1: add universal search Oct 19, 2026
@lightbulbman lightbulbman added the run-tests Trigger automated tests label Oct 19, 2026
@lightbulbman
lightbulbman merged commit 17c4fdc into core-beta Oct 19, 2026
33 checks passed
@lightbulbman
lightbulbman deleted the feat/universal-search/core branch October 19, 2026 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

run-tests Trigger automated tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant