diff --git a/docs/site-map.md b/docs/site-map.md index 77f2c93e8f..9bd77fe332 100644 --- a/docs/site-map.md +++ b/docs/site-map.md @@ -1017,6 +1017,7 @@ This file is generated by `npm run docs:update` (or `npm run sitemap:update` dir - `/mockups/caring-contacts/team` - Route discovered from app directory Source: `src/app/mockups/caring-contacts/team/page.tsx`. - `/mockups/caring-contacts/templates` - Route discovered from app directory Source: `src/app/mockups/caring-contacts/templates/page.tsx`. - `/mockups/caring-contacts/templates/[pathwayId]` - Route discovered from app directory Source: `src/app/mockups/caring-contacts/templates/[pathwayId]/page.tsx`. +- `/mockups/development` - Route discovered from app directory Source: `src/app/mockups/development/page.tsx`. - `/mockups/document-navigation-contract` - Route discovered from app directory Source: `src/app/mockups/document-navigation-contract/page.tsx`. - `/mockups/document-navigation-final` - Route discovered from app directory Source: `src/app/mockups/document-navigation-final/page.tsx`. - `/mockups/document-navigation-final-review` - Route discovered from app directory Source: `src/app/mockups/document-navigation-final-review/page.tsx`. diff --git a/src/app/mockups/development/page.tsx b/src/app/mockups/development/page.tsx new file mode 100644 index 0000000000..351486e922 --- /dev/null +++ b/src/app/mockups/development/page.tsx @@ -0,0 +1,98 @@ +import type { Metadata } from "next"; +import Link from "next/link"; +import { ArrowRight, FlaskConical, ShieldAlert } from "lucide-react"; + +import { CARING_CONTACT_MOCKUP_ROUTES } from "@/components/caring-contacts/mockups/routes"; + +export const metadata: Metadata = { + title: "Development · Clinical KB", + description: "In-progress surfaces, off by default in a production deploy.", +}; + +// The index of what is being built. It lives under /mockups so it inherits the +// namespace's production gate (`mockupsEnabled()` in the mockups layout) rather +// than needing a second one: always on outside production, and 404 in a +// production deploy unless that deploy sets NEXT_PUBLIC_MOCKUPS_ENABLED=true — +// exactly like the surfaces it links to. +const DEVELOPMENT_SURFACES = [ + { + id: "caring-contacts", + name: "Caring Contact", + summary: + "Linked prototype of the one-way caring-contacts coordination workflow: 13 routes, the activation flow, and the offline, permission, session-expiry, conflict and recovery states.", + href: CARING_CONTACT_MOCKUP_ROUTES.today, + status: "Synthetic prototype", + entries: [ + { label: "Today", href: CARING_CONTACT_MOCKUP_ROUTES.today }, + { label: "Patients", href: CARING_CONTACT_MOCKUP_ROUTES.patients }, + { label: "Schedule", href: CARING_CONTACT_MOCKUP_ROUTES.schedule }, + { label: "Templates", href: CARING_CONTACT_MOCKUP_ROUTES.templates }, + { label: "System states", href: CARING_CONTACT_MOCKUP_ROUTES.systemStates }, + ], + }, +] as const; + +export default function DevelopmentIndexPage() { + return ( +
+
+

+

+

In-progress surfaces

+

+ Work being built, reachable from Settings while it is in development. These routes are not part of the + clinical product, and a production deploy 404s them unless it explicitly opts in. +

+
+ +

+

+ + +
+ ); +} diff --git a/src/components/clinical-dashboard/settings-dialog.tsx b/src/components/clinical-dashboard/settings-dialog.tsx index f26f0f46b7..4a6e3ab301 100644 --- a/src/components/clinical-dashboard/settings-dialog.tsx +++ b/src/components/clinical-dashboard/settings-dialog.tsx @@ -1043,19 +1043,19 @@ export function SettingsDialog({ note="In-progress surfaces, reachable only in development builds. Not clinical content." >
-

Caring Contact

+

Development page

- Linked prototype of the caring-contacts workflow. Synthetic data only — no patient record, message - or schedule here is real. + Index of the surfaces being built, including the Caring Contact prototype. Synthetic data only — no + patient record, message or schedule on them is real.

diff --git a/tests/settings-dialog-actions.dom.test.tsx b/tests/settings-dialog-actions.dom.test.tsx index acb2cd509c..6e350d6773 100644 --- a/tests/settings-dialog-actions.dom.test.tsx +++ b/tests/settings-dialog-actions.dom.test.tsx @@ -101,16 +101,16 @@ describe("SettingsDialog — destructive and account actions", () => { // built. It is gated to development builds, matching `mockupsEnabled()`, and the // rail must not advertise a section the body does not render. The route is a // mockup, so the entry navigates through and closes the sheet behind it. - it("opens the Caring Contact prototype from a gated Development section", () => { + it("opens the Development page from a gated Development section", () => { renderDialog(); const development = document.querySelector('[data-settings-section="development"]'); expect(development).not.toBeNull(); expect(development).toHaveTextContent("Development"); expect(development).toHaveTextContent("Synthetic data only"); - const prototypeLink = screen.getByTestId("settings-row-caring-contact-prototype"); - expect(prototypeLink).toHaveAttribute("href", "/mockups/caring-contacts"); - expect(prototypeLink).toHaveTextContent("Open Caring Contact prototype"); + const prototypeLink = screen.getByTestId("settings-row-development-page"); + expect(prototypeLink).toHaveAttribute("href", "/mockups/development"); + expect(prototypeLink).toHaveTextContent("Open Development page"); expect(prototypeLink).toHaveTextContent("Temporary"); expect(development?.contains(prototypeLink)).toBe(true);