Skip to content

UI: add universal search query ribbon#1166

Merged
BigSimmo merged 12 commits into
mainfrom
codex/query-ribbon-search-headings
Jul 24, 2026
Merged

UI: add universal search query ribbon#1166
BigSimmo merged 12 commits into
mainfrom
codex/query-ribbon-search-headings

Conversation

@BigSimmo

@BigSimmo BigSimmo commented Jul 24, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add the polished shared Query Ribbon to Services, Forms, Favourites, Differentials, and Medication/Prescribing search results.
  • Keep query, progress/result state, scopes, and real sort/view/save controls consistent across phone, tablet, and desktop layouts.
  • Add the /mockups/search-heading reference page and focused DOM/Chromium regression coverage.
  • Preserve current-main deferred search behavior while retaining the ribbon on mobile.

RAG impact: no retrieval behaviour change — presentation-only shared search-header update.

Verification

  • npm run verify:pr-local — runtime, Prettier, full ESLint, and TypeScript passed; the complete unit run stopped only on the unrelated load-sensitive reconciliation-preflight 30-second timeout, then that file passed 5/5 in isolation.
  • Focused production Chromium matrix: 16/16 across mobile, tablet, and desktop search routes plus 320px prescribing controls; isolated Next production build and TypeScript passed.
  • Focused Query Ribbon DOM suite: 4/4.
  • git diff --check.
  • Full npm run verify:ui — not repeated because the focused production matrix directly covers every changed production route and breakpoint; hosted UI checks remain required.
  • npm run verify:release — not run; no release/provider workflow requested or required for this presentation-only PR.
  • Retrieval/live evaluation and production-readiness checks are not applicable because retrieval, ranking, answer generation, clinical output, privacy, environment, and source governance are unchanged.

Risk and rollout

  • Risk: Low UI risk; responsive layout and stale-scope handling are covered, with residual risk in browser combinations outside the focused Chromium matrix.
  • Rollback: Revert the Query Ribbon commit; the current-main merge contains no feature-specific rollback requirement.
  • Provider or production effects: GitHub PR/CI only, explicitly authorized by the user. No OpenAI, Supabase, Railway, deployment, production-data, or clinical-provider workflow was run.

Clinical Governance Preflight

  • Source-backed claims still require linked source verification before clinical use.
  • No patient-identifiable document workflow was introduced or expanded.
  • Supabase target configuration is unchanged.
  • Service-role keys and private document access remain server-only and unchanged.
  • Demo/synthetic content separation is unchanged.
  • Source metadata, review status, and outdated/unknown-source behavior are unchanged.
  • No clinical decision-support behavior or TGA SaMD classification changed.

Notes

  • Review polish restored the compact Sort label at ordinary phone widths and suppresses empty utility strips for stale/unknown scopes.
  • Current-main Forms deferred empty-state behavior is retained after the clean merge reconciliation.

Summary by CodeRabbit

  • New Features

    • Added a search-heading mockup route showcasing three responsive heading designs with searching and results states.
    • Added responsive search heading and status displays across forms, favourites, and medication search results.
    • Improved filter chips, sorting, utility controls, and accessibility announcements in search result headers.
  • Tests

    • Added coverage for loading states, filters, controls, accessibility, and responsive search ribbons.
  • Documentation

    • Updated the site map and review records with the new mockup route.

BigSimmo added 2 commits July 24, 2026 19:17
…arch-headings

# Conflicts:
#	src/components/forms/forms-search-results-page.tsx
@supabase

supabase Bot commented Jul 24, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project sjrfecxgysukkwxsowpy because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@coderabbitai

coderabbitai Bot commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Changes

The shared search results heading now supports loading-aware status, accessibility metadata, filtered scope chips, conditional utilities, and responsive sort labels. Favourites, medication, and forms views use it directly across breakpoints. A new responsive search-heading mockup route presents three concepts, with DOM and UI smoke tests covering the updated behavior.

Universal search heading

Layer / File(s) Summary
Shared heading behavior
src/components/clinical-dashboard/search-results-header-band.tsx
Adds loading state, accessible status messaging, valid scope filtering, conditional utilities, and compact sort-label behavior.
Results-page integration
src/components/clinical-dashboard/favourites-command-library-page.tsx, src/components/clinical-dashboard/medication-prescribing-workspace.tsx, src/components/forms/forms-search-results-page.tsx
Renders the shared heading directly in favourites, medication, and forms search views while removing duplicate responsive controls.
Mockup route and previews
src/components/search-heading-mockups.tsx, src/app/mockups/search-heading/page.tsx, src/app/mockups/mockups-layout-client.tsx, docs/site-map.md
Adds three responsive heading concepts and exposes them at /mockups/search-heading without global mockup chrome.
Validation and ledger records
tests/search-results-header-band.dom.test.tsx, tests/ui-tools.spec.ts, docs/branch-review-ledger.md
Covers heading accessibility, loading, utilities, responsive ribbon assertions, and PR review records.

Estimated code review effort: 4 (Complex) | ~45 minutes

Possibly related PRs

Suggested labels: codex

Suggested reviewers: claude

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately summarizes the main UI change: adding a universal search query ribbon.
Description check ✅ Passed The PR description matches the template well, with completed Summary, Verification, Risk and rollout, Clinical Governance Preflight, and Notes sections.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/query-ribbon-search-headings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@BigSimmo
BigSimmo enabled auto-merge July 24, 2026 11:22

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: bac7245e87

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread docs/branch-review-ledger.md
@BigSimmo

Copy link
Copy Markdown
Owner Author

@codex resolve actionable Codex review findings for this pull request and current head using the repository instructions. This is the pull request's single automatic repair pass: do not perform a fresh review, create new standalone findings, or request another review. Work only the existing unresolved Codex threads on the current head. Always fix P0 and P1 findings. For P2 and lower findings, fix only clear, scoped, low-risk issues; otherwise disposition them with a concise reason. After fixing or dispositioning a thread, reply in that thread with as the first line, followed by a concise summary; that marker authorizes the workflow to close that exact thread. If human input or new authorization is required, do not use the marker and leave the thread open with the blocker. Finish only after every actionable thread is fixed or dispositioned and closed, or explicitly left open for a human decision. Do not update the branch from main, address unrelated reviews, broaden scope, or create more than one scoped fix commit. Do not use external APIs, paid services, credentials, dependency changes, or broad refactors unless explicitly authorized. Add targeted tests where behavior changes and run the narrowest relevant validation.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: bac7245e87

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/app/mockups/mockups-layout-client.tsx (1)

16-40: 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win

Suppress the shared search composer for /mockups/search-heading.

chromeVisible=false hides the header, but searchComposerVisible still defaults to true, so the master search composer still renders standalone. Excluding isSearchHeadingMockup prevents a fixed search bar from stacking over this mockup.

🩹 Proposed fix
       searchComposerVisible={
         !isToolsPageMockup &&
         !isFavouritesPageMockup &&
         !isStandaloneDocumentFlow &&
         !isUniversalSearchRedesignMockup &&
-        !isCalculatorsSearchPageMockup
+        !isCalculatorsSearchPageMockup &&
+        !isSearchHeadingMockup
       }
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@src/app/mockups/mockups-layout-client.tsx` around lines 16 - 40, Update the
searchComposerVisible condition in the GlobalMockupSearchShell props to also
exclude isSearchHeadingMockup, ensuring the shared composer is hidden for the
search-heading mockup while preserving existing visibility behavior for all
other mockups.

Source: Path instructions

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@src/app/mockups/mockups-layout-client.tsx`:
- Around line 16-40: Update the searchComposerVisible condition in the
GlobalMockupSearchShell props to also exclude isSearchHeadingMockup, ensuring
the shared composer is hidden for the search-heading mockup while preserving
existing visibility behavior for all other mockups.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 774c11df-6d9e-493a-99f7-3f06b9bb12f9

📥 Commits

Reviewing files that changed from the base of the PR and between b5456b9 and 16f9e21.

📒 Files selected for processing (11)
  • docs/branch-review-ledger.md
  • docs/site-map.md
  • src/app/mockups/mockups-layout-client.tsx
  • src/app/mockups/search-heading/page.tsx
  • src/components/clinical-dashboard/favourites-command-library-page.tsx
  • src/components/clinical-dashboard/medication-prescribing-workspace.tsx
  • src/components/clinical-dashboard/search-results-header-band.tsx
  • src/components/forms/forms-search-results-page.tsx
  • src/components/search-heading-mockups.tsx
  • tests/search-results-header-band.dom.test.tsx
  • tests/ui-tools.spec.ts

@BigSimmo
BigSimmo merged commit d21f9f7 into main Jul 24, 2026
22 checks passed
@BigSimmo
BigSimmo deleted the codex/query-ribbon-search-headings branch July 24, 2026 12:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant