Repository navigation
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
🟡 Changes recommended
Retry-dependent analytics keys allow duplicate query and zero-result events within one dialog session.
1 open issue
What changed in this PR
Improves documentation search while retaining Orama and the current MDX collection, building on the legacy-tree retirement in #116.
Changes:
- Adds identifier-aware indexing, weighted ranking, matching anchors, and page-type filters.
- Introduces a keyboard-first search dialog with excerpts and PostHog analytics.
- Adds engine, browser, and production-build validation.
| File | Description |
|---|---|
| tests/search.spec.ts | Tests navigation, filters, errors, analytics, and mobile layout. |
| src/lib/search/tokenizer.ts | Normalizes identifiers and indexes suffixes. |
| src/lib/search/shared.ts | Defines result types, filters, and grouping. |
| src/lib/search/engine.ts | Builds and queries the weighted search index. |
| src/components/docs-search.tsx | Implements the search dialog and analytics. |
| src/components/docs-provider.tsx | Registers the custom search dialog. |
| src/app/layout.tsx | Integrates the docs provider. |
| src/app/api/search/route.ts | Serves validated queries and index metadata. |
| source.config.ts | Includes code fences and excludes navigation cards. |
| scripts/validate-search.ts | Checks live ranking, anchors, and filters. |
| scripts/search.test.ts | Tests search engine behavior. |
| README.md | Documents search design and validation. |
| playwright.config.ts | Configures browser checks. |
| package.json | Adds dependencies and validation commands. |
| IA.md | Records search feature completion. |
| bun.lock | Locks search and browser-test dependencies. |
| .gitignore | Excludes browser-test artifacts. |
| .github/workflows/search.yml | Runs production-build search checks in CI. |
Review effort: Balanced
This branch was successfully deployed
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.

Docs search omitted standalone code examples and treated developer identifiers as ordinary prose. Keep Orama, index code fences with their rendered heading anchors, and support namespace separators, suffixes, camelCase, prefixes and typo fallback. Queries such as
text_eq,eql_v3.text,ord_term,encryptedSupabaseandCS_CLIENT_KEYnow find the relevant documentation./stackpages excluded. The issue's dual-tree migration requirement was superseded by fix(docs): retire legacy stack pages and preserve redirects #116.Validation: full production build and prebuild checks pass (content, Mermaid, links and all 621 legacy redirects); TypeScript and changed-file Biome checks pass; six engine tests and five Chromium tests pass, including intercepted PostHog event assertions. All six required queries plus six additional symbol/regression queries pass top-three relevance checks, along with destination anchors, filters, zero results and input validation. The complete suite also passed in GitHub Actions on the committed revision.
Vercel preview deployed successfully. Direct preview verification is pending authenticated Vercel access: requests currently redirect to Vercel SSO. Local and CI production-build acceptance checks are complete; they are not a claim that the protected preview has been tested.
Closes CIP-3350.