Skip to content

Align Therapy Compass home with shared mode-home template#887

Merged
cursor[bot] merged 6 commits into
mainfrom
cursor/therapy-mode-home-align-1ae0
Jul 18, 2026
Merged

Align Therapy Compass home with shared mode-home template#887
cursor[bot] merged 6 commits into
mainfrom
cursor/therapy-mode-home-align-1ae0

Conversation

@BigSimmo

@BigSimmo BigSimmo commented Jul 18, 2026

Copy link
Copy Markdown
Owner

Summary

  • Align /therapy-compass home with the shared ModeHomeMain / ModeHomeTemplate structure used by other mode homes.
  • Restore the global responsive search composer for therapy routes via GlobalSearchShell.
  • Hide the therapy in-content nav on the home route and suppress the duplicate workspace verification footer on home only.
  • Keep a single main landmark on /therapy-compass by rendering the workspace shell as a non-main wrapper when ModeHomeMain owns the landmark.
  • Supersedes Align Therapy Compass home with shared mode-home template and enable universal search #875 with a policy-compliant description.

Verification

  • Focused therapy Vitest including landmark wiring (tests/therapy-compass-mode-wiring.test.ts, 5 passed)
  • npx prettier --check on touched therapy workspace/test files
  • Verification not run: full npm run verify:pr-local not re-run in this repair pass; CI Static/Unit/Build/UI gates apply on this PR.
  • UI verification not run: local npm run verify:ui not re-run after the landmark fix; Production UI CI is the merge gate for this UI surface.

Risk and rollout

  • Risk: low — presentation/layout alignment for Therapy Compass home; no retrieval, auth, or data-model changes.
  • Rollback: revert this PR squash commit on main.
  • Provider or production effects: None.

Clinical Governance Preflight

  • Source-backed claims still require linked source verification before clinical use
  • No patient-identifiable document workflow was introduced or expanded without explicit governance approval
  • Supabase target remains Clinical KB Database (sjrfecxgysukkwxsowpy)
  • Service-role keys and private document access remain server-only
  • Demo/synthetic content remains clearly separated from real clinical sources
  • Source metadata, review status, and outdated/unknown-source behavior remain conservative
  • Deployment classification/TGA SaMD impact was checked when clinical decision-support behavior changed

@supabase

supabase Bot commented Jul 18, 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 18, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Therapy Compass now uses the shared mode-home template, enables the shared search composer, hides navigation on the home route, and adjusts landmark/footer rendering by pathname. Review Queue navigation was removed, and structural wiring tests cover the home composition.

Changes

Therapy Compass home and workspace

Layer / File(s) Summary
Route-aware workspace chrome
src/app/therapy-compass/layout.tsx, src/components/therapy-compass/workspace.tsx, src/components/therapy-compass/nav.tsx
The shared search shell no longer suppresses the composer. Workspace rendering now varies by route, and the Review Queue navigation item is removed.
Mode-home screen composition
src/components/therapy-compass/screens/home-screen.tsx, tests/therapy-compass-mode-wiring.test.ts
HomeScreen uses ModeHomeTemplate and ModeHomeMain, routes actions through bindings, and adds structural assertions for home rendering and landmark selection.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Sequence Diagram(s)

sequenceDiagram
  participant TherapyCompassLayout
  participant GlobalSearchShell
  participant TherapyCompassWorkspace
  participant HomeScreen
  participant ModeHomeTemplate
  TherapyCompassLayout->>GlobalSearchShell: mount therapy-compass shell
  GlobalSearchShell->>TherapyCompassWorkspace: render workspace
  TherapyCompassWorkspace->>HomeScreen: render home route
  HomeScreen->>ModeHomeTemplate: provide home actions and composer slot
  ModeHomeTemplate->>HomeScreen: render mode-home content
Loading

Possibly related PRs

Suggested labels: codex

Suggested reviewers: claude

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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.
Title check ✅ Passed The title is concise and accurately summarizes the main change to Therapy Compass home.
Description check ✅ Passed The description matches the required template and includes summary, verification, risk, rollout, and governance sections.
✨ 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 cursor/therapy-mode-home-align-1ae0

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

@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: 0bab547705

ℹ️ 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 src/components/therapy-compass/screens/home-screen.tsx
@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.

@cursor
cursor Bot enabled auto-merge (squash) July 18, 2026 16:05

@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: 0bab547705

ℹ️ 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 src/components/therapy-compass/screens/home-screen.tsx
Comment thread src/components/therapy-compass/screens/home-screen.tsx
@github-actions

Copy link
Copy Markdown

CI triage

CI failed on this PR. Automated classification of the 2 failed job(s):

  • Static PR checksneeds investigation: inspect the failing step and uploaded diagnostics; rerun only after classifying the cause.
  • PR requiredneeds investigation: inspect the failing step and uploaded diagnostics; rerun only after classifying the cause.

Compared with main CI run #3410 (success).

Classification is evidence routing, not permission to ignore a failure. Exact quarantined Playwright identities remain governed by the flake ledger.

BigSimmo and others added 4 commits July 19, 2026 00:34
Home already renders ModeHomeVerificationFooter via ModeHomeTemplate;
skip the workspace footer on /therapy-compass so the notice appears once.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Home already renders ModeHomeMain; keep the workspace shell as a div on
/therapy-compass so screen readers see a single main landmark.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@BigSimmo
BigSimmo force-pushed the cursor/therapy-mode-home-align-1ae0 branch from cc1385f to 579e9f1 Compare July 18, 2026 16:34

@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: 579e9f1e13

ℹ️ 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 src/components/therapy-compass/screens/home-screen.tsx
Comment thread src/components/therapy-compass/workspace.tsx

@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.

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/therapy-compass/workspace.tsx`:
- Around line 75-83: Update the Tag selection in the workspace component to use
"main" when either asMain or b.error is true, preserving "div" otherwise. Extend
the landmark test to cover the b.error state while keeping the existing home and
non-home behavior unchanged.
🪄 Autofix (Beta)

❌ Autofix failed (check again to retry)

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: 773a4774-7d14-4a2f-9566-999d1d19cfbb

📥 Commits

Reviewing files that changed from the base of the PR and between 45ed28a and 579e9f1.

📒 Files selected for processing (5)
  • src/app/therapy-compass/layout.tsx
  • src/components/therapy-compass/nav.tsx
  • src/components/therapy-compass/screens/home-screen.tsx
  • src/components/therapy-compass/workspace.tsx
  • tests/therapy-compass-mode-wiring.test.ts

Comment thread src/components/therapy-compass/workspace.tsx
@coderabbitai

coderabbitai Bot commented Jul 18, 2026

Copy link
Copy Markdown
Contributor

Note

Autofix is a beta feature. Expect some limitations and changes as we gather feedback and continue to improve it.

⚠️ Branch updated during autofix.

The branch was updated while autofix was in progress. Please try again.

Co-authored-by: Cursor <cursoragent@cursor.com>
@cursor
cursor Bot merged commit 8b0a600 into main Jul 18, 2026
20 of 21 checks passed
@cursor
cursor Bot deleted the cursor/therapy-mode-home-align-1ae0 branch July 18, 2026 16:53
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.

2 participants