Skip to content

Add tools and favourites mockup concepts#215

Merged
BigSimmo merged 22 commits into
mainfrom
feature/tools-page-mockups
Jul 3, 2026
Merged

Add tools and favourites mockup concepts#215
BigSimmo merged 22 commits into
mainfrom
feature/tools-page-mockups

Conversation

@BigSimmo

@BigSimmo BigSimmo commented Jul 2, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add favourites page mockup concepts and the task-directory tools concept route.
  • Refactor tools mockups through shared fixtures/filter state and wire mockup layout modes.
  • Apply UI token/primitive polish plus focused contract and UI coverage updates.

Verification

  • npm run typecheck passed.
  • npm run lint passed with existing ClinicalDashboard.tsx unused-symbol warnings only.
  • node scripts/run-vitest.mjs run tests/app-modes.test.ts tests/openai-cache.test.ts tests/document-enrichment.test.ts tests/model-index-extraction.test.ts --reporter=dot passed.
  • node scripts/run-playwright.mjs tests/ui-tools-task-directory.spec.ts --project=chromium passed.
  • npm run verify:cheap reached tests but hit a tests/pdf-extractor.test.ts timeout under the full suite; rerunning that file directly passed.
  • npm run verify:ui did not complete cleanly in this workspace; targeted task-directory Chromium coverage passed.

BigSimmo and others added 10 commits July 3, 2026 01:56
- differentials detail: give each Compare Basket item its own severity tag
  (shared likelihoodTag helper) instead of stamping the parent's status on
  all items; show the real related count instead of length + 8
- differentials stream: replace internal QA-scaffolding copy ("Stream helper /
  workflow verification only") with clinician-facing "Keep exploring" guidance
- services: expand "ATSI" display labels to "Aboriginal and Torres Strait
  Islander" while keeping "ATSI" as a search keyword in tags; rename the
  duplicate "Find a service" card to "Search services"
- favourites: derive saved-set counts from real items (2/2/1 vs 12/9/7),
  relabel the ambiguous "Active" stat to "Filters", fix "1 item" pluralization

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…ar, form

Commits the current working-tree state of these four files, which also carries
in-progress edits already present on this branch. Design-review changes here:

- service detail: use break-words instead of break-all so referral values no
  longer split mid-word ("service" -> "servic e", "Strait" -> "Stra it")
- master search header: use the magnifier submit affordance for every
  search-mode home; differentials no longer uses the send arrow
- sidebar: expand tool labels to full words (Favourites, Differentials,
  Medications) for consistency with the rest of the nav
- form detail: render Verification notes as proper sentences (joinNotes)
  instead of a bare space-joined run-on

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
… build

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…d mockups

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…uum, drop dead indexes

Postgres best-practices audit of the live Clinical KB Database found: an
unindexed FK on storage_cleanup_jobs.document_id, document_embedding_fields
(largest table, 215k+ rows, backs an HNSW index) missing the autovacuum
tuning its sibling RAG tables already have, no idle-in-transaction timeout
on the authenticator role, and 4 dead/duplicate indexes (~25MB) not
referenced by any query or by search_schema_health()'s required_indexes
invariant. All changes already applied live via Supabase MCP and verified
(search_schema_health() still reports ok:true).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
… clinical UI

Consolidates the in-progress design-token / design-review sweep from the
working tree of this shared checkout (38 files):

- globals.css: add size-only type-scale steps (--text-4xs/3xs/2xs/sm-minus/
  base-minus) and remove the dead `@theme inline` colour bridge; per-theme
  values are consumed directly via var() so .dark overrides cascade.
- Migrate hardcoded `text-[Npx]` sizes and ad-hoc values to the new tokens
  across dashboard, differentials, forms, services, document, and mockup
  surfaces.
- Update ui-smoke / ui-stress / ui-tools specs to match.

Excludes tools-page-mockup-page.tsx: its sweep edit was a mid-flight extraction
into ./tool-fixtures + ./use-tool-filter (modules not yet committed), left as
the owning session's WIP.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
- 07-token-adoption-audit.md: report from the design-token adoption sweep.
- 08-design-review-prompt.md: the design-review prompt driving the UI pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

@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: 6bbf3f2630

ℹ️ 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/lib/source-text-sanitizer.ts Outdated
Comment thread supabase/migrations/20260703010000_drop_dead_document_indexes.sql Outdated
Comment thread src/components/clinical-dashboard/differentials-home.tsx
Comment thread supabase/migrations/20260703010000_drop_dead_document_indexes.sql
Comment thread src/components/applications-launcher-page.tsx Outdated

@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: dae41bb68e

ℹ️ 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 supabase/migrations/20260703010000_drop_dead_document_indexes.sql
Comment thread src/components/ClinicalDashboard.tsx Outdated
Comment thread src/components/services/service-detail-page.tsx Outdated
@BigSimmo
BigSimmo enabled auto-merge (squash) July 3, 2026 04:16
@BigSimmo

BigSimmo commented Jul 3, 2026

Copy link
Copy Markdown
Owner Author

@copilot resolve the merge conflicts in this pull request

@BigSimmo

BigSimmo commented Jul 3, 2026

Copy link
Copy Markdown
Owner Author

@copilot resolve the merge conflicts in this pull request

BigSimmo and others added 4 commits July 3, 2026 12:43
…ckups

# Conflicts:
#	scripts/run-eval-safe.mjs
#	src/components/ClinicalDashboard.tsx
#	src/components/DocumentViewer.tsx
#	src/components/clinical-dashboard/differentials-home.tsx
#	src/components/clinical-dashboard/global-mockup-search-shell.tsx
#	src/components/clinical-dashboard/master-search-header.tsx
#	src/components/differentials/differential-detail-page.tsx
#	src/components/forms/forms-search-results-page.tsx
#	tests/ui-tools.spec.ts
… feature/tools-page-mockups

# Conflicts:
#	src/components/ClinicalDashboard.tsx
#	supabase/migrations/20260703000000_storage_cleanup_fk_index_and_embedding_fields_autovacuum.sql
#	supabase/schema.sql
#	tests/supabase-schema.test.ts
@BigSimmo
BigSimmo enabled auto-merge (squash) July 3, 2026 04:46
BigSimmo added 2 commits July 3, 2026 12:51
… feature/tools-page-mockups

# Conflicts:
#	scripts/run-eval-safe.mjs
#	src/components/ClinicalDashboard.tsx
#	src/components/DocumentViewer.tsx
#	src/components/clinical-dashboard/differentials-home.tsx
#	src/components/clinical-dashboard/global-mockup-search-shell.tsx
#	src/components/forms/forms-search-results-page.tsx
#	tests/ui-tools.spec.ts

@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: 952c2e7379

ℹ️ 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/clinical-dashboard/differentials-home.tsx Outdated
Comment thread src/components/clinical-dashboard/differentials-home.tsx Outdated
Comment thread src/components/clinical-dashboard/master-search-header.tsx
Comment thread src/components/DocumentViewer.tsx Outdated
Comment thread src/components/ClinicalDashboard.tsx
@BigSimmo
BigSimmo force-pushed the feature/tools-page-mockups branch from fde914a to 2ca4685 Compare July 3, 2026 05:41
@BigSimmo
BigSimmo merged commit db8a904 into main Jul 3, 2026
4 checks passed

@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: 5b623209e2

ℹ️ 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".

// library, whose single `document_labels.in(<all ids>)` request produces an
// over-long PostgREST URL that fails on large corpora. Corpus search runs
// unscoped (like Documents); users opt into label filters explicitly.
const requestId = ++searchRequestSeqRef.current;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Clear loading on setup-not-ready early returns

Because this sequence is incremented before the setup-readiness gate, a submit that reaches the later !canRunSearch return while another answer/document request is still loading invalidates the older request; its finally will skip cleanup, and the setup-not-ready branch only sets error before returning. The local-mode returns now clear loading, but this remaining branch can still leave the dashboard spinner/progress stuck after readiness/auth/local API state flips (or an Enter submit bypasses the disabled button), so clear loading/progress before returning there as well.

Useful? React with 👍 / 👎.

-- app role. With only 60 max_connections on this compute tier, a stuck idle
-- transaction can pin a slot indefinitely. 30s is well above normal
-- request/RPC duration for this app.
alter role authenticator set idle_in_transaction_session_timeout = '30s';

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Mirror the role timeout in schema bootstrap

This only protects databases that replay this migration. The repo's setup path bootstraps new Supabase projects by running supabase/schema.sql, and that file has no alter role authenticator ... entry, so fresh/local databases keep the default unbounded idle-in-transaction timeout even though migrated live databases get the 30s connection-slot guard. Add the role setting to the schema bootstrap or another setup-applied SQL file so new environments match the migrated role configuration.

Useful? React with 👍 / 👎.

type="button"
onClick={() => onSelect(app.id)}
data-testid={`mobile-application-row-${app.id}`}
{...{ href: app.href }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Turn mobile tool rows into real links

In the mobile Tools hub (/?mode=tools below lg), this adds an href prop to a <button>, but browsers ignore href on buttons; the click still runs selectApplication, which opens the selected-tool sheet for max-width 1023px instead of navigating to app.href. The updated direct-launch flow can therefore falsely pass attribute-only tests while mobile users still get the old extra sheet step; render a Link/anchor or navigate in the click handler.

Useful? React with 👍 / 👎.

BigSimmo added a commit that referenced this pull request Jul 3, 2026
Tools-page area captions stay verb-form (Assess/Treat/Coordinate) to match the
workflow-board lanes, but "personal" rendered as "Resume" — the same word as the
Favourites card's own action button, so the card showed "Resume" twice. Use the
noun "Saved" for that one caption. Design-review follow-up to #215.

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
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