DREAM — Drug Reaction Evaluation & Anaesthetic Management.
A private clinical Progressive Web App for the Royal Prince Alfred Hospital Department of Clinical Immunology & Allergy. DREAM supports anaesthetic allergy workups from REDCap patient import through testing plans, clinical test logging, patient-facing handouts, and eMR-ready reports.
- Current version: v0.78.6
- Live app: dream.yuson.au
- Repository: private/internal clinical tooling
- Production host: Cloudflare Pages
- Release notes: GitHub Releases
- Data model: local-first browser processing, with optional deidentified Supabase research submission
- Import patient records from REDCap CSV exports.
- Search, filter, and review patient reaction histories.
- Review a missing-information checklist and high-risk clinical context before testing.
- Create manual patient entries when a record is not in the imported database.
- Keep in-progress testing data browser-local with time-limited persistence.
- Generate personalised testing plans from patient history and drug categories.
- Select protocol variants when a drug has more than one testing protocol or presentation.
- Autosave testing-plan builder drafts per patient under the same 6-hour TTL as other active clinical data.
- Print nursing request forms with B&W-safe styling and per-page patient identifiers.
- Record skin prick testing, intradermal testing, and IV challenge outcomes.
- Generate Clinical Report, Patient Handout, and Powerchart Letter views.
- Print reports with black-and-white safe AVOID/SAFE and positive/negative styling.
- Repeat patient identity in print headers/footers so separated pages remain identifiable.
- Copy eMR-ready text from reports where appropriate.
- View dashboard summaries of recent clinical activity and imported patient data.
- Use the dashboard worklist to track referral, plan-drafted, testing, and reported status and filter patients who need action.
- Optionally submit only deidentified research payloads to a configured Supabase project.
- Track app changes through the in-app changelog and Quick Start "What's New" modal.
- Curate short changelog summaries with
Summary:lines inCHANGELOG.md.
DREAM is designed as local-first clinical support tooling. During normal clinical use, identifiable patient data is processed in the browser from local REDCap exports and is not transmitted to an application backend.
The research submission path is the explicit exception: when configured and selected by the clinician, only the deidentified research payload is sent to the configured Supabase project. Do not commit real patient data, REDCap exports, screenshots containing identifiers, or generated clinical documents to this repository.
The screen lock is a shoulder-surfing control only. It is not a substitute for device, network, REDCap, or institutional access controls.
- Frontend: React 19 with TypeScript
- Build tool: Vite
- Styling: Tailwind CSS with shadcn/ui components
- Icons: Lucide React
- Testing: Vitest, Testing Library, Playwright, axe-core
- PWA: vite-plugin-pwa and Workbox
- Optional research storage: Supabase
- Hosting: Cloudflare Pages via Wrangler
-
Clone the repository
git clone https://github.com/monchee/dream.git cd dream -
Install dependencies
npm ci
-
Start the development server
npm run dev
-
Open the app
http://localhost:3000
If port 3000 is already in use, Vite may choose the next available port. Check the terminal output before testing browser flows.
npm run dev— start the Vite dev servernpx tsc --noEmit— type-check the appnpm run lint— run ESLintnpm run test:unit— run unit/component testsnpm run test:e2e— run Playwright testsnpm run test:e2e:ci— build DREAM first and run non-visual Chromium e2e tests against the production previewnpm run test:coverage— generate local coverage reportsnpm run build— sync changelog data and build production assetsnpm run preview— preview the production build locallynpm run changelog:sync— regeneratesrc/shared/data/changelog.jsonfromCHANGELOG.mdnpm run deploy— build and publishdist/to Cloudflare Pages via Wrangler
- Update
package.jsonversion. - Add a top entry to
CHANGELOG.md. - Include a short
Summary:line for the Quick Start "What's New" modal. - Run
npm run changelog:sync. - Validate with:
npx tsc --noEmit npm run lint npm run test:unit npm run build
- Commit, tag, push, and create a GitHub release.
- Publish production with:
npm run deploy
Production is hosted on Cloudflare Pages at dream.yuson.au. GitHub Pages is intentionally not used for this project.
The deploy script runs a production build and then publishes with:
wrangler pages deploy dist --project-name dream --commit-dirty=true --branch mainFor automated CI/CD deployment instructions, see MAINTAINERS.md. For service ownership, credentials, domain risks, and fallback procedures, see HANDOVER.md.
src/
├── features/ # Feature modules
│ ├── patients/ # Patient selection and history
│ ├── testing/ # Testing plans and clinical test logging
│ ├── reports/ # Clinical reports, handouts, and letters
│ ├── dashboard/ # Clinical dashboard and CSV upload
│ ├── research/ # Optional deidentified research submission/review
│ └── info-pages/ # About, FAQ, contact, legal, and changelog pages
├── core/ # App shell, routing, layout, and help modal
├── shared/ # Cross-feature hooks, types, utilities, and data
└── test/ # Test setup and factories
- GitHub Actions validate pushes and pull requests to
main, with automated deployment to Cloudflare Pages on push tomainwhen Cloudflare credentials (CLOUDFLARE_API_TOKENandCLOUDFLARE_ACCOUNT_ID) are configured. - Maintainer runbook and testing scripts are documented in MAINTAINERS.md.
- Succession inventory, credential rotation, and continuity plans are documented in HANDOVER.md.
- Branch protection is not configured because GitHub reports it is unavailable for this private repository without GitHub Pro.
- Production assets are split into dedicated vendor chunks (React runtime, Supabase, Sentry, Radix UI, forms, and icons) so production builds stay well within chunk-size limits without warnings.
/manifest.webmanifestis generated from the Vite PWA configuration. The Vite config is the manifest source of truth.
This repository is private clinical tooling for use within the RPAH Department of Clinical Immunology & Allergy workflow. No open-source license is granted. Contact the development team for reuse, access, or licensing questions.
For technical support, feature requests, or clinical workflow questions, contact the DREAM development team through the Royal Prince Alfred Hospital Department of Clinical Immunology & Allergy.
