Skip to main content

ResultsReview

ComplexChart panels<co-results-review>

ResultsReview is the inbox detail for one resulted order: values against the prior draw, then Acknowledge, Comment, Route and Notify Patient. A critical value needs the read-back recorded before Acknowledge.

import { ResultsReview } from 'health-components';

Examples​

Showcase​

Storybook

Routine​

Storybook

Read Only​

Storybook

Usage​

<ResultsReview result={bmp} routeOptions={["Lisa Chen RN", "Cardiology nurse pool"]} />

When to use​

  • Results inbox detail pane; covering-clinician review.

When not to use​

  • Trends across many draws: ResultsTrendPanel.

Variants and states​

VariantWhat it is
newGrey New tag.
criticalRed alert; Acknowledge is disabled until "Read-back done" is ticked.
commentInline comment box.
routePick a person or pool, then Route.
routedBlue tag with the recipient.
acknowledgedGreen tag and a locked confirmation.
readOnlyLock message for roles that cannot acknowledge.

Clinical values​

Every number renders through CareOS.ClinicalValue and CareOS.fmt (the clinical-values builder), matched by LOINC; measures that table lacks (NT-proBNP, lactate, vancomycin trough, CrCl, PHQ-9, per-kg doses) use a local table with the same rules: tabular figures, the unit always shown, fixed decimals per measure (potassium 1, sodium 0, creatinine 2), the reference range in the title or beside it, and H, L, HH or LL flags in words for screen readers. The flag says where the number sits against the adult reference range in the rules table; it does not say the number was measured correctly.

Accessibility​

  • A critical value uses role alert.
  • Acknowledge says why it is disabled through the required checkbox next to it.

Do and don't​

  • Do: Show the prior value next to the new one.
  • Don't: Allow acknowledging a critical value without a read-back.

Props​

PropTypeDefaultDescription
result *ResultReviewResult—The resulted order; required
routeOptionsstring[]nonePeople and pools the result can be routed to
userstring'You'Name of the signed-in user, used on new comments
readOnlybooleanfalseView only (role cannot acknowledge)
statusResultReviewStatusuncontrolled, starting at `result.status`Review status (controlled)
onStatusChange(status: ResultReviewStatus) => voidnoneCalled when the status changes
onAcknowledge() => voidnoneCalled when the user acknowledges the result
onComment(comment: ResultReviewComment) => voidnoneCalled with a comment the user adds
onRoute(to: string) => voidnoneCalled with the person or pool the result is routed to
onNotifyPatient() => voidnoneCalled when the user clicks Notify Patient
rangeContextRangeContextIdthe global context, else 'outpatient'Which shared reference range flags use; the lab range on a result still wins

Also accepts native attributes, including defaultChecked, defaultValue, autoFocus, plus className and event handlers on the root element.

Angular, Vue and HTML​

Register the elements once (Angular guide), then use <co-results-review>. Attributes take strings; arrays and objects are set as properties (Angular [prop], Vue :prop) or as JSON attributes. Callbacks are DOM events with the value in event.detail.

Angular template
<co-results-review user="…" read-only [result]="result" (co-status-change)="onStatusChange($event.detail)"></co-results-review>
KindNameDescription
property / JSON attributeresultThe resulted order; required
property / JSON attributeroute-options / routeOptionsPeople and pools the result can be routed to; default none
attributeuserName of the signed-in user, used on new comments; default 'You'
attributeread-only / readOnlyView only (role cannot acknowledge); default false
attributestatusReview status (controlled); default uncontrolled, starting at `result.status`
attributerange-context / rangeContextWhich shared reference range flags use; the lab range on a result still wins; default the global context, else 'outpatient'
attributedefault-checked / defaultChecked
property / JSON attributedefault-value / defaultValue
attributeauto-focus / autoFocus
eventco-status-changeCalled when the status changes; default none (React: onStatusChange)
eventco-acknowledgeCalled when the user acknowledges the result; default none (React: onAcknowledge)
eventco-commentCalled with a comment the user adds; default none (React: onComment)
eventco-routeCalled with the person or pool the result is routed to; default none (React: onRoute)
eventco-notify-patientCalled when the user clicks Notify Patient; default none (React: onNotifyPatient)