Search palette
Starlight ships its own full-text search (Pagefind) — this site uses it natively for page search, so nothing here duplicates that. Circuit’s palette.js is a supplementary layer: a family-wide jump hub and a home for agent-facing actions that a generic per-repo search box wouldn’t have.
Why a supplementary layer, not a replacement
Section titled “Why a supplementary layer, not a replacement”Pagefind indexes real page content — replacing it with palette.js’s hand-seeded demo data would be a regression, not an upgrade. What Pagefind can’t do on its own:
- Jump across the family. Search from matey’s docs, land on an mcp-query page.
- Agent-facing actions. “Copy this page as Markdown,” “Open
llms.txtfor this page” — the same positioning erisera’s docs-for-agents story depends on everywhere else.
import { createCommandPalette } from '@erisera/circuit/palette.js';
createCommandPalette({ trigger: document.getElementById('search-trigger'), pages: [{ title: 'Quickstart', path: 'docs / getting-started', href: '/quickstart' }], actions: [ { title: 'Toggle dark mode', icon: '◐', run: () => document.documentElement.classList.toggle('dark') }, { title: 'Copy page as Markdown', run: () => navigator.clipboard.writeText(pageMarkdown), feedback: 'Copied' }, ],});Full behavior reference — keyboard nav, matching, empty state — is in the README.