Repository navigation
feat(search): add beta Images hits to unified search - #454
Merged
Merged
Conversation
Callers can request verses, topics, and images together. Image hits are id and passageId. Verse and topic hits stay the existing types.
Keep the UI barrel aligned with new core runtime exports so check-public-exports passes.
Measured brotlied barrel is 21.55 kB. Set the limit to measured size plus ~10% headroom per CONTRIBUTING.
Default omitted verses/topics/images wire keys to empty arrays, drop invalid image hits per item (structural USFM on passage_id), and replace the runtime field-coverage object with a type-only check.
Use the repo @ts-expect-error pattern for an invalid fields[] value instead of a typed assertion plus SAFETY comment.
Use false instead of never in the false branch so Record<..., true> rejects non-array field mappings.
Wire a vite-react page that calls SearchClient.searchUnified for images alone or with verses, and renders thin hits plus empty/error states.
Results was reading the live Fields control, so flipping mode after an images-only search showed a false empty verses section. Co-authored-by: cameron.b.llewellyn <cameron.b.llewellyn@gmail.com>
Build on PR446 core search with an additive React hook, image-aware coverage, and documented backend availability. Validate request intents and required response fields without requiring images on the wire. Amp-Thread-ID: https://ampcode.com/threads/T-01a15a0f-f2cd-72cf-a270-2102b3d073b2
Set the hooks full-barrel budget to measured 27.044 kB plus approximately 10% headroom, following CONTRIBUTING. Leave all narrow-import budgets unchanged. Amp-Thread-ID: https://ampcode.com/threads/T-01a15a0f-f2cd-72cf-a270-2102b3d073b2
Preserve verse/topic unified search, useUnifiedSearch, and contract validation while deferring Images types, mapping, tests, and smoke page. Amp-Thread-ID: https://ampcode.com/threads/T-01a15a0f-f2cd-72cf-a270-2102b3d073b2
Restore the complete pre-split Images work atop the unified-only release boundary without changing PR446. Amp-Thread-ID: https://ampcode.com/threads/T-01a15a0f-f2cd-72cf-a270-2102b3d073b2
🦋 Changeset detectedLatest commit: 84868b0 The changes in this PR will be included in the next version bump. This PR includes changesets to release 4 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
camrun91
self-requested a review
October 20, 2026 22:27
Treat optional wire keys and bad hits per ADR 0006 instead of rejecting the whole response, enable the hook only when input is valid, document the public API, and add a UI changeset for the unified search re-export.
Spread options.fields into subtopics so stub results use string[] and typecheck passes after readonly search field types in c2a6465.
cameronapak
marked this pull request as ready for review
October 22, 2026 19:37
Collaborator
|
@cameronapak can you address the merge conflicts please? |
Resolve conflicts with the squash-merged #446: keep the Images additions on top of main's unified-search, restore main's changesets, and add a dedicated Images changeset. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…ch page Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Collaborator
|
just confirmed that this does not make images show up in the UI this is good to mrege. |
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.
Summary
Preserve the Images follow-up separately from the live verse/topic unified-search release in #446. Adds image hit types and mapping, core/hook contract fixtures, and the example smoke page. This is unified-search Images support, not a full Images API client.
Stacked on #446: one restoration commit, 14 files. The source tree matches the preserved pre-split implementation. Mocked Images success cases do not establish deployed API support; earlier production probes returned HTTP 400 for
fields[]=images.Blockers before ready
mainwithout duplicating its unified-search changes.Draft for preservation and review only. Do not merge or publish without Cam's authorization.


Confidence Score: 5/5
No new code defect blocks merging, but the author's draft status and authorization requirement still apply.Summary
Adds Images field selection, maps image hits to
{ id, passageId }, and adds core/hook fixtures plus a demo page.Reviews (2) · Last reviewed commit: "fix(examples): share the configured API ..." · Reviewed by Greptile