fix: land remaining PR cleanup batch onto main#798
Conversation
|
This pull request has been ignored for the connected project Preview Branches by Supabase. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (13)
🚧 Files skipped from review as they are similar to previous changes (10)
📝 WalkthroughWalkthroughThe PR standardizes error-state accessibility, lazy-loads PDF readers, adds responsive favourites quick views and pinned indicators, and introduces retryable Therapy Compass catalogue loading with a retryable error screen. ChangesError and state surfaces
PDF reader loading
Responsive favourites UI
Therapy Compass retry handling
Estimated code review effort: 4 (Complex) | ~60 minutes Sequence Diagram(s)sequenceDiagram
participant TherapyCompassShell
participant TcProvider
participant useTherapyData
TherapyCompassShell->>TcProvider: invoke retryData
TcProvider->>useTherapyData: invoke retry
useTherapyData->>useTherapyData: clear cache and start next attempt
useTherapyData-->>TcProvider: update loading and error state
TcProvider-->>TherapyCompassShell: render retryable catalogue state
Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
5115955 to
94c15aa
Compare
There was a problem hiding this comment.
Actionable comments posted: 3
🤖 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.
Inline comments:
In `@src/app/global-error.tsx`:
- Around line 49-52: Update the error heading element in the global error
component by removing role="alert" while preserving its native h1 semantics and
existing ref/focus behavior.
In `@src/components/clinical-dashboard/favourites-command-library-page.tsx`:
- Around line 490-496: Update the mobile card selection button near the pinned
indicator to announce the item’s pinned state to screen readers. Prefer
incorporating “Pinned” into the button’s existing aria-label, or associate the
existing “Pinned” text via aria-describedby, while preserving the current
selection label for unpinned items.
In `@tests/document-viewer-pdf-reader-lazy.test.ts`:
- Around line 10-17: Strengthen the test in “DocumentViewer PDF reader loading”
to verify both NativePdfEmbed and PdfCanvasViewer are loaded via the PDF viewer
dynamic import, and that each retains its client-only ssr: false configuration.
Keep the existing static-import and loading-fallback assertions while adding
checks that prevent either export from becoming eagerly loaded or
server-rendered.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 9cd5bf33-09e7-4dc6-ac58-c4bf6da57423
📒 Files selected for processing (13)
src/app/global-error.tsxsrc/components/ClinicalDashboard.tsxsrc/components/DocumentViewer.tsxsrc/components/clinical-dashboard/favourites-command-library-page.tsxsrc/components/clinical-dashboard/favourites-library-nav.tsxsrc/components/route-error-boundary.tsxsrc/components/therapy-compass/bindings.tsxsrc/components/therapy-compass/data/use-therapy-data.tssrc/components/therapy-compass/therapy-card.tsxsrc/components/therapy-compass/therapy-compass-page.tsxsrc/components/ui-primitives.tsxtests/document-viewer-pdf-reader-lazy.test.tstests/ui-primitives.dom.test.tsx
94c15aa to
72fdcc4
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 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.
Inline comments:
In `@src/components/clinical-dashboard/favourites-command-library-page.tsx`:
- Around line 731-734: Update the empty-state column-span configuration in the
favourites command library page to use five columns when selectedItemId hides
the Evidence column at 2xl, while preserving the existing responsive spans for
layouts where Evidence remains visible. Align the configuration near the
empty-state rendering with the selectedItemId column visibility logic.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: 0664cf8f-a8ec-41e3-9efa-c30ed50914bb
📒 Files selected for processing (13)
src/app/global-error.tsxsrc/components/ClinicalDashboard.tsxsrc/components/DocumentViewer.tsxsrc/components/clinical-dashboard/favourites-command-library-page.tsxsrc/components/clinical-dashboard/favourites-library-nav.tsxsrc/components/route-error-boundary.tsxsrc/components/therapy-compass/bindings.tsxsrc/components/therapy-compass/data/use-therapy-data.tssrc/components/therapy-compass/therapy-card.tsxsrc/components/therapy-compass/therapy-compass-page.tsxsrc/components/ui-primitives.tsxtests/document-viewer-pdf-reader-lazy.test.tstests/ui-primitives.dom.test.tsx
🚧 Files skipped from review as they are similar to previous changes (12)
- src/components/therapy-compass/therapy-card.tsx
- tests/document-viewer-pdf-reader-lazy.test.ts
- src/components/therapy-compass/therapy-compass-page.tsx
- src/components/ui-primitives.tsx
- src/components/DocumentViewer.tsx
- src/app/global-error.tsx
- src/components/therapy-compass/data/use-therapy-data.ts
- src/components/therapy-compass/bindings.tsx
- src/components/route-error-boundary.tsx
- src/components/clinical-dashboard/favourites-library-nav.tsx
- tests/ui-primitives.dom.test.tsx
- src/components/ClinicalDashboard.tsx
2995c7d to
1db742c
Compare
Keep the global error heading as a real heading, include pinned state in the mobile favourites select label, and assert both PDF lazy-load wrappers. Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
1db742c to
802adb7
Compare
Summary
mainin one up-to-date branch to avoid repeated behind/CI races.Verification
npm run verify:pr-local— covered by CI Static PR checks / Unit coverage / Build on this PRnpm run verify:ui— CI Production UI / Advisory UI gates are the evidence pathRisk and rollout
Clinical Governance Preflight
Clinical KB Database(sjrfecxgysukkwxsowpy)Notes
Summary by CodeRabbit