WaitlistRow
ComplexScheduling
<co-waitlist-row>WaitlistRow is one waitlisted patient with wanted window, priority, a matched opening and Offer Slot.
import { WaitlistRow } from 'health-components';
Examples
Waitlist
No Match
Usage
<WaitlistRow item={{ patient: "Kristin Watson", type: "Annual Wellness", provider: "Any", window: "mornings this week", since: "09/30", match: "Thu 10/09 9:40 AM" }} />
When to use
- Filling cancellations.
When not to use
- Recalls: CareGapRow.
Variants and states
| Variant | What it is |
|---|---|
| match | Opening found, Offer Slot primary. |
| no match | Offer disabled. |
| priority | Red tag. |
Accessibility
- Actions named with the patient.
Do and don't
- Do: Text offers that expire.
- Don't: Offer the same slot to two people at once.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
item * | WaitlistItem | — | The waitlist entry. Required |
onOffer | (item: WaitlistItem) => void | none | Called when Offer Slot is pressed (enabled only with a match) |
onText | (item: WaitlistItem) => void | none | Row menu: Text Patient |
onEdit | (item: WaitlistItem) => void | none | Row menu: Edit Preferences |
onRemove | (item: WaitlistItem) => void | none | Row menu: Remove from Waitlist |
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-waitlist-row>. 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-waitlist-row default-checked auto-focus [item]="item" (co-offer)="onOffer($event.detail)"></co-waitlist-row>
| Kind | Name | Description |
|---|---|---|
| property / JSON attribute | item | The waitlist entry. Required |
| attribute | default-checked / defaultChecked | |
| property / JSON attribute | default-value / defaultValue | |
| attribute | auto-focus / autoFocus | |
| event | co-offer | Called when Offer Slot is pressed (enabled only with a match); default none (React: onOffer) |
| event | co-text | Row menu: Text Patient; default none (React: onText) |
| event | co-edit | Row menu: Edit Preferences; default none (React: onEdit) |
| event | co-remove | Row menu: Remove from Waitlist; default none (React: onRemove) |