Skip to content

Unify search across sub-sites - #69

Open
ctrueden wants to merge 1 commit into
napari:mainfrom
ctrueden:unified-search
Open

Unify search across sub-sites#69
ctrueden wants to merge 1 commit into
napari:mainfrom
ctrueden:unified-search

Conversation

@ctrueden

@ctrueden ctrueden commented Jul 30, 2026

Copy link
Copy Markdown
Member

This is a companion PR to napari/docs#1093, which aims to unify the search functionality between multiple documentation sub-sites, including workshops and docs. See napari/docs#1093 for full details.

For this PR to fully work, it must be merged in conjunction with the one on the docs side.

Here is a screenshot of the workshops search seeing content from docs:

search-docs-from-workshops

The trailing hash signs are a rough edge that still needs to be sorted out.

mystmd's own search bar ships disabled here (myst-search-bar-disabled),
and even working it would only cover this site's own pages, not the main
docs at napari.org. Build a Pagefind index alongside the existing
jupyter-book build and inject a widget that merges in the docs site's
Pagefind index at query time, since both are served under the same
napari.org origin.

mystmd has no documented hook for injecting arbitrary <head>/<body>
content, so this is done via HTML post-processing after the build rather
than through theme config.

Note that Pagefind's stock UI leaves .pagefind-ui__results-area
transparent, which reads as a broken translucent panel for our floating
overlay here (no ambient opaque ancestor like docs' navbar provides).
So we give it its own solid background, border, shadow, and scroll,
anchored as a dropdown under the search input, to match the main docs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

1 participant