import type { AccessPolicyResource } from '@medplum/fhirtypes'; import { AddFavoriteParams } from '@medplum/core'; import { AddPharmacyResponse } from '@medplum/core'; import { addPreferredPharmacyToPatient } from '@medplum/core'; import type { Address } from '@medplum/fhirtypes'; import type { AddressFormatOptions } from '@medplum/core'; import type { AlertProps } from '@mantine/core'; import type { AnchorProps } from '@mantine/core'; import type { Annotation } from '@medplum/fhirtypes'; import type { AriaRole } from 'react'; import type { Attachment } from '@medplum/fhirtypes'; import type { AvatarProps } from '@mantine/core'; import type { BadgeProps } from '@mantine/core'; import type { BaseLoginRequest } from '@medplum/core'; import type { Bundle } from '@medplum/fhirtypes'; import type { ButtonProps } from '@mantine/core'; import type { ClientApplication } from '@medplum/fhirtypes'; import type { CodeableConcept } from '@medplum/fhirtypes'; import type { Coding } from '@medplum/fhirtypes'; import type { ComboboxData } from '@mantine/core'; import type { ComboboxItem } from '@mantine/core'; import type { ComboboxProps } from '@mantine/core'; import type { Communication } from '@medplum/fhirtypes'; import { Component } from 'react'; import type { ComponentType } from 'react'; import type { ContactDetail } from '@medplum/fhirtypes'; import type { ContactPoint } from '@medplum/fhirtypes'; import type { ContainerProps } from '@mantine/core'; import { Context } from 'react'; import { createPreferredPharmacyExtension } from '@medplum/core'; import type { CSSProperties } from 'react'; import type { DiagnosticReport } from '@medplum/fhirtypes'; import type { DocumentReference } from '@medplum/fhirtypes'; import type { ElementDefinitionBinding } from '@medplum/fhirtypes'; import type { ElementDefinitionType } from '@medplum/fhirtypes'; import type { ElementProps } from '@mantine/core'; import type { Encounter } from '@medplum/fhirtypes'; import type { ErrorInfo } from 'react'; import type { ExtendedInternalSchemaElement } from '@medplum/core'; import type { ExtractResource } from '@medplum/fhirtypes'; import type { Filter } from '@medplum/core'; import { ForwardRefExoticComponent } from 'react'; import { getPreferredPharmaciesFromPatient } from '@medplum/core'; import type { HumanName } from '@medplum/fhirtypes'; import type { HumanNameFormatOptions } from '@medplum/core'; import type { Identifier } from '@medplum/fhirtypes'; import type { InternalSchemaElement } from '@medplum/core'; import { isAddPharmacyResponse } from '@medplum/core'; import { isOrganizationArray } from '@medplum/core'; import type { JSX } from 'react'; import type { LoginAuthenticationResponse } from '@medplum/core'; import type { MantineColor } from '@mantine/core'; import type { MeasureReport } from '@medplum/fhirtypes'; import type { Media } from '@medplum/fhirtypes'; import type { Medication } from '@medplum/fhirtypes'; import type { MedicationCartClearRequest } from '@medplum/core'; import type { MedicationCartContentsRequest } from '@medplum/core'; import type { MedicationCartContentsResponse } from '@medplum/core'; import type { MedicationCartManageResponse } from '@medplum/core'; import type { MedicationCartRemoveRequest } from '@medplum/core'; import type { MedicationCheckoutRequest } from '@medplum/core'; import type { MedicationCheckoutResponse } from '@medplum/core'; import type { MedicationOrderRequest } from '@medplum/core'; import type { MedicationOrderResponse } from '@medplum/core'; import type { MedicationRequest } from '@medplum/fhirtypes'; import type { MedicationSearchParams } from '@medplum/core'; import type { MedplumClient } from '@medplum/core'; import { MemoExoticComponent } from 'react'; import type { ModalProps as ModalProps_2 } from '@mantine/core'; import type { Money } from '@medplum/fhirtypes'; import type { MouseEvent as MouseEvent_2 } from 'react'; import type { MouseEventHandler } from 'react'; import type { Observation } from '@medplum/fhirtypes'; import type { ObservationDefinition } from '@medplum/fhirtypes'; import type { ObservationDefinitionQualifiedInterval } from '@medplum/fhirtypes'; import type { OperationOutcome } from '@medplum/fhirtypes'; import type { OperationOutcomeIssue } from '@medplum/fhirtypes'; import { Operator } from '@medplum/core'; import type { OrderSetSyncResponse } from '@medplum/core'; import type { Organization } from '@medplum/fhirtypes'; import type { PaperProps } from '@mantine/core'; import type { PasswordInputProps } from '@mantine/core'; import type { Patient } from '@medplum/fhirtypes'; import { PATIENT_PREFERRED_PHARMACY_URL } from '@medplum/core'; import type { Period } from '@medplum/fhirtypes'; import { PHARMACY_PREFERENCE_TYPE_SYSTEM } from '@medplum/core'; import { PHARMACY_TYPE_PREFERRED } from '@medplum/core'; import { PHARMACY_TYPE_PRIMARY } from '@medplum/core'; import { PharmacySearchParams } from '@medplum/core'; import type { PlanDefinition } from '@medplum/fhirtypes'; import type { Practitioner } from '@medplum/fhirtypes'; import { PreferredPharmacy } from '@medplum/core'; import type { ProfileResource } from '@medplum/core'; import type { Quantity } from '@medplum/fhirtypes'; import type { QueryTypes } from '@medplum/core'; import type { Questionnaire } from '@medplum/fhirtypes'; import type { QuestionnaireItem } from '@medplum/fhirtypes'; import type { QuestionnaireItemAnswerOption } from '@medplum/fhirtypes'; import type { QuestionnaireItemEnableWhen } from '@medplum/fhirtypes'; import type { QuestionnaireItemInitial } from '@medplum/fhirtypes'; import type { QuestionnaireResponse } from '@medplum/fhirtypes'; import type { QuestionnaireResponseItem } from '@medplum/fhirtypes'; import type { QuestionnaireResponseItemAnswer } from '@medplum/fhirtypes'; import type { Range as Range_2 } from '@medplum/fhirtypes'; import type { Ratio } from '@medplum/fhirtypes'; import type { ReactNode } from 'react'; import { RefAttributes } from 'react'; import type { Reference } from '@medplum/fhirtypes'; import { removePreferredPharmacyFromPatient } from '@medplum/core'; import type { RequestGroup } from '@medplum/fhirtypes'; import type { Resource } from '@medplum/fhirtypes'; import type { ResourceArray } from '@medplum/core'; import type { ResourceModifiedEvent } from '@medplum/core'; import type { ResourceType } from '@medplum/fhirtypes'; import type { Schedule } from '@medplum/fhirtypes'; import type { SearchParameter } from '@medplum/fhirtypes'; import type { SearchRequest } from '@medplum/core'; import type { ServiceRequest } from '@medplum/fhirtypes'; import type { Signature } from '@medplum/fhirtypes'; import type { Slot } from '@medplum/fhirtypes'; import type { SortRule } from '@medplum/core'; import type { SpotlightActionData } from '@mantine/spotlight'; import type { StructureDefinition } from '@medplum/fhirtypes'; import type { Subscription } from '@medplum/fhirtypes'; import type { SyntheticEvent } from 'react'; import type { TabsProps } from '@mantine/core'; import type { Task } from '@medplum/fhirtypes'; import type { TextProps } from '@mantine/core'; import type { Timing } from '@medplum/fhirtypes'; import type { TypedValue } from '@medplum/core'; import type { ValueSetExpandParams } from '@medplum/core'; import type { ValueSetExpansionContains } from '@medplum/fhirtypes'; import type { WithId } from '@medplum/core'; /** * Adds a filter for a date between two dates (inclusive of both dates). * @param definition - The original search request. * @param field - The field key name. * @param d1 - The start date. * @param d2 - The end date. * @returns The updated search request. */ export declare function addDateFilterBetween(definition: SearchRequest, field: string, d1: Date, d2: Date): SearchRequest; export { AddFavoriteParams } /** * Adds a field. * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addField(definition: SearchRequest, field: string): SearchRequest; /** * Adds a filter. * @param definition - The original search request. * @param field - The field key name. * @param op - The operation key name. * @param value - The filter value. * @param opt_clear - Optional flag to clear filters on the field. * @returns The updated search request. */ export declare function addFilter(definition: SearchRequest, field: string, op: Operator, value?: string, opt_clear?: boolean): SearchRequest; /** * Adds a filter that constrains the specified field to "last month". * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addLastMonthFilter(definition: SearchRequest, field: string): SearchRequest; /** * Adds a filter that constrains the specified field to "missing". * @param definition - The original search request. * @param field - The field key name. * @param value - Optional boolean value. Default is true. * @returns The updated search request. */ export declare function addMissingFilter(definition: SearchRequest, field: string, value?: boolean): SearchRequest; /** * Adds a filter that constrains the specified field to "next 24 hours". * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addNext24HoursFilter(definition: SearchRequest, field: string): SearchRequest; /** * Adds a filter that constrains the specified field to "next month". * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addNextMonthFilter(definition: SearchRequest, field: string): SearchRequest; export { AddPharmacyResponse } export { addPreferredPharmacyToPatient } export declare function AddressDisplay(props: AddressDisplayProps): JSX.Element | null; export declare interface AddressDisplayProps { readonly value?: Address; readonly options?: AddressFormatOptions; } export declare function AddressInput(props: AddressInputProps): JSX.Element; export declare type AddressInputProps = ComplexTypeInputProps
; /** * Adds a filter that constrains the specified field to "this month". * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addThisMonthFilter(definition: SearchRequest, field: string): SearchRequest; /** * Adds a filter that constrains the specified field to "today". * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addTodayFilter(definition: SearchRequest, field: string): SearchRequest; /** * Adds a filter that constrains the specified field to "tomorrow". * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addTomorrowFilter(definition: SearchRequest, field: string): SearchRequest; /** * Adds a filter that constrains the specified field to the year to date. * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addYearToDateFilter(definition: SearchRequest, field: string): SearchRequest; /** * Adds a filter that constrains the specified field to "yesterday". * @param definition - The original search request. * @param field - The field key name. * @returns The updated search request. */ export declare function addYesterdayFilter(definition: SearchRequest, field: string): SearchRequest; export declare function AIRealTimeQuestionnaireForm(props: AIRealTimeQuestionnaireFormProps): JSX.Element; export declare interface AIRealTimeQuestionnaireFormProps extends QuestionnaireFormProps { readonly aiModel?: string; readonly onTranscript?: (fullTranscript: string, chunk: string) => void; readonly voiceInstructions?: ReactNode; readonly silenceDebounceMs?: number; } /** Allergies section — searches for AllergyIntolerance resources. */ export declare const AllergiesSection: PatientSummarySectionConfig; export declare function AnnotationInput(props: AnnotationInputProps): JSX.Element; export declare interface AnnotationInputProps extends ComplexTypeInputProps { } /** * Applies the `questionnaire-optionExclusive` rule to an answer change. * * Given the previous and newly requested answers for an item, enforces that selecting an answer * option marked exclusive clears every other answer, and selecting any other option clears a * previously selected exclusive answer. Returns the new answers unchanged if the item has no * exclusive options or the change only removed answers. * * See: https://hl7.org/fhir/extensions/StructureDefinition-questionnaire-optionExclusive.html * * @param item - The questionnaire item being answered. * @param previousAnswers - The item's answers before the change. * @param newAnswers - The answers requested by the change. * @returns The reconciled answers. */ export declare function applyOptionExclusive(item: QuestionnaireItem, previousAnswers: QuestionnaireResponseItemAnswer[] | undefined, newAnswers: QuestionnaireResponseItemAnswer[]): QuestionnaireResponseItemAnswer[]; export declare function AppShell(props: AppShellProps): JSX.Element; export declare interface AppShellAnnouncement { readonly id?: string; readonly message: ReactNode; readonly color?: MantineColor; readonly icon?: ReactNode; readonly dismissible?: boolean; readonly onDismiss?: (announcement: AppShellAnnouncement) => void; readonly role?: AriaRole; } export declare interface AppShellProps { readonly logo: ReactNode; readonly pathname?: string; readonly searchParams?: URLSearchParams; readonly headerSearchDisabled?: boolean; readonly version?: string; readonly menus?: NavbarMenu[]; readonly children: ReactNode; readonly displayAddBookmark?: boolean; readonly resourceTypeSearchDisabled?: boolean; readonly notifications?: ReactNode; readonly announcements?: AppShellAnnouncement[]; readonly layoutVersion?: 'v1' | 'v2'; readonly showLayoutVersionToggle?: boolean; readonly spotlightPatientsOnly?: boolean; readonly spotlightActions?: SpotlightLinkAction[]; } export declare function AsyncAutocomplete(props: AsyncAutocompleteProps): JSX.Element; export declare interface AsyncAutocompleteOption extends ComboboxItem { readonly active?: boolean; readonly resource: T; } export declare interface AsyncAutocompleteProps extends Omit { readonly name?: string; readonly label?: ReactNode; /** * Names the field for assistive technology, for use instead of a visible `label` (don't pass both). The name * goes on the search box and on a group around the whole field, which keeps the selected values (and, at * `maxValues`, the clear button) named while the search box is hidden (disabled or at `maxValues`). */ readonly 'aria-label'?: string; readonly description?: ReactNode; readonly error?: ReactNode; readonly defaultValue?: T | T[]; readonly toOption: (item: T) => AsyncAutocompleteOption; readonly loadOptions: (input: string, signal: AbortSignal) => Promise; readonly itemComponent?: (props: AsyncAutocompleteOption) => JSX.Element | ReactNode; readonly pillComponent?: (props: { item: AsyncAutocompleteOption; disabled?: boolean; onRemove: () => void; }) => JSX.Element; readonly emptyComponent?: (props: { search: string; }) => JSX.Element | ReactNode; readonly onChange: (item: T[]) => void; readonly onCreate?: (input: string) => T; readonly creatable?: boolean; readonly clearable?: boolean; readonly required?: boolean; readonly withAsterisk?: boolean; readonly className?: string; readonly placeholder?: string; readonly leftSection?: ReactNode; readonly maxValues?: number; readonly optionsDropdownMaxHeight?: number; readonly minInputLength?: number; } export declare function AttachmentArrayDisplay(props: AttachmentArrayDisplayProps): JSX.Element; export declare interface AttachmentArrayDisplayProps { readonly path?: string; readonly values?: Attachment[]; readonly maxWidth?: number; readonly includeDescriptionListEntry?: boolean; readonly property?: InternalSchemaElement; } export declare function AttachmentArrayInput(props: AttachmentArrayInputProps): JSX.Element; export declare interface AttachmentArrayInputProps { readonly name: string; readonly defaultValue?: Attachment[]; readonly arrayElement?: boolean; readonly onChange?: (value: Attachment[]) => void; readonly disabled?: boolean; } export declare function AttachmentButton(props: AttachmentButtonProps): JSX.Element; export declare interface AttachmentButtonProps { readonly securityContext?: Reference; readonly onUpload: (attachment: Attachment) => void; readonly onUploadStart?: () => void; readonly onUploadProgress?: (e: ProgressEvent) => void; readonly onUploadError?: (outcome: OperationOutcome) => void; children(props: { disabled?: boolean; onClick(e: MouseEvent_2): void; }): ReactNode; readonly disabled?: boolean; } export declare function AttachmentDisplay(props: AttachmentDisplayProps): JSX.Element | null; export declare interface AttachmentDisplayProps { readonly value?: Attachment; readonly maxWidth?: number; } export declare function AttachmentInput(props: AttachmentInputProps): JSX.Element; export declare interface AttachmentInputProps extends ComplexTypeInputProps { readonly arrayElement?: boolean; readonly securityContext?: Reference; readonly onChange?: (value: Attachment | undefined) => void; } export declare function BackboneElementDisplay(props: BackboneElementDisplayProps): JSX.Element | null; export declare interface BackboneElementDisplayProps { readonly value: TypedValue; /** The path identifies the element and is expressed as a "."-separated list of ancestor elements, beginning with the name of the resource or extension. */ readonly path: string; readonly compact?: boolean; readonly ignoreMissingValues?: boolean; readonly link?: boolean; /** (optional) Profile URL of the structure definition represented by the backbone element */ readonly profileUrl?: string; /** * (optional) If provided, inputs specified in `accessPolicyResource.hiddenFields` are not shown. */ readonly accessPolicyResource?: AccessPolicyResource; } export declare function BackboneElementInput(props: BackboneElementInputProps): JSX.Element; export declare interface BackboneElementInputProps extends BaseInputProps { /** Type name the backbone element represents */ readonly typeName: string; /** (optional) The contents of the resource represented by the backbone element */ readonly defaultValue?: any; /** (optional) callback function that is called when the value of the backbone element changes */ readonly onChange?: (value: any) => void; /** (optional) Profile URL of the structure definition represented by the backbone element */ readonly profileUrl?: string; /** * (optional) If provided, inputs specified in `accessPolicyResource.readonlyFields` are not editable * and inputs specified in `accessPolicyResource.hiddenFields` are not shown. */ readonly accessPolicyResource?: AccessPolicyResource; } /** * BaseChat component for displaying and managing communications. * * **NOTE: The component automatically filters `Communication` resources where the `sent` property is `undefined`.** * * @param props - The BaseChat React props. * @returns The BaseChat React node. */ export declare function BaseChat(props: BaseChatProps): JSX.Element | null; export declare interface BaseChatProps extends PaperProps { readonly title: string; readonly communications: Communication[]; readonly setCommunications: (communications: Communication[]) => void; readonly query: string; readonly sendMessage: (content: string, file?: File, existingDocRef?: DocumentReference) => void; readonly onMessageReceived?: (message: Communication) => void; readonly onMessageUpdated?: (message: Communication) => void; readonly inputDisabled?: boolean; readonly excludeHeader?: boolean; readonly onError?: (err: Error) => void; readonly uploadEnabled?: boolean; readonly attachmentSubjectRef?: Reference; readonly onViewInDocuments?: (reference: Reference) => void; } export declare interface BaseInputProps { /** The path identifying the related element definition and is expressed as a "."-separated list of ancestor elements, beginning with the name of the resource or extension. */ readonly path: string; /** (optional) A FHIRPath expression that identifies the input more precisely than `path`, e.g. `Patient.identifier[0].system` versus `Patient.identifier.system` */ readonly valuePath?: string; /** (optional) OperationOutcome from the last attempted system action*/ readonly outcome?: OperationOutcome; } /** * A generic widget to choose an option by date/time. Renders a monthly * calendar UI and lets the viewer drill down into options on a given day. * * @param props - The React props * @returns the JSX Element */ export declare function BaseScheduler(props: BaseSchedulerProps): JSX.Element | null; export declare interface BaseSchedulerProps { /** A Reference or Resource to the actor being scheduled against (typically a Practitioner) */ readonly actor?: Reference | Resource; /** A function that fetches SchedulingOption pairs. If this is not a stable function it can cause duplicate queries. */ readonly fetchOptions: FetchOptionsFunction; /** React nodes to render inside the scheduler container */ readonly children?: React.ReactNode; /** A callback invoked when a specific option is selected */ readonly onSelectOption?: (el: T, date: Date) => void; } /** * Returns a field display name. * @param key - The field key. * @returns The field display name. */ export declare function buildFieldNameString(key: string): string; export declare function buildInitialResponse(questionnaire: Questionnaire, questionnaireResponse?: QuestionnaireResponse): QuestionnaireResponse; export declare function buildInitialResponseItem(item: QuestionnaireItem): QuestionnaireResponseItem; /** * Returns a display label for a search parameter code. Metadata codes keep their * underscore-prefixed code so they never share a label with a same-named element * (e.g. `ProjectMembership.project` vs `_project`). * @param code - The search parameter code. * @returns The display label for the search parameter. */ export declare function buildSearchParamFieldLabel(code: string): string; export declare function CalendarDateInput(props: CalendarDateInputProps): JSX.Element; export declare interface CalendarDateInputProps { readonly availableDates: Date[]; readonly onChangeMonth: (date: Date) => void; /** Called with the day picked. */ readonly onClick: (date: Date) => void; readonly month?: Date; /** An extra day to mark as picked, alongside any `range`. Ignored while a drag is under way. */ readonly selected?: Date; readonly allowUnavailableDates?: boolean; readonly earliestDate?: Date; /** * The stretch of days on show, banded across the weeks it spans. The ends may carry a time of * day; only the days they fall on are used. */ readonly range?: { readonly start: Date; readonly end: Date; }; /** * Called with the stretch of days a drag or a shift-click asked for, earlier end first. * * A shift-click moves the nearer end of the range to the day clicked and leaves the other where * it is, so clicking beyond either end widens the range and clicking within it draws that end in. * A day exactly between the two holds the start. The nearer end is measured on the range itself, * which may begin in a month that has been paged away from. */ readonly onSelectRange?: (start: Date, end: Date) => void; /** * Shown in place of the month and year above the grid, such as a button for jumping to a month. * Rendered inside a `

`, so it must be inline content. */ readonly monthLabel?: ReactNode; } /** * A calendar that marks the days with slots as available. * @deprecated Use CalendarDateInput instead, which takes the available dates directly * and supports month navigation, a controlled selection, and date ranges. * @param props - The Input props. * @returns The JSX element to render. */ export declare function CalendarInput(props: CalendarInputProps): JSX.Element; /** @deprecated Use CalendarDateInputProps instead. */ export declare interface CalendarInputProps { readonly slots: Slot[]; readonly onChangeMonth: (date: Date) => void; readonly onClick: (date: Date) => void; } export declare function ChangePasswordForm(props: ChangePasswordFormProps): JSX.Element; export declare interface ChangePasswordFormProps { readonly onSuccess?: () => void; } export declare interface ChatBubbleSkeletonProps { readonly alignment: 'left' | 'right'; readonly parentWidth: number; } export declare function ChatModal(props: ChatModalProps): JSX.Element | null; export declare interface ChatModalProps { readonly open?: boolean; readonly children: ReactNode; } export declare function CheckboxFormSection(props: CheckboxFormSectionProps): JSX.Element; export declare interface CheckboxFormSectionProps { readonly htmlFor?: string; readonly title?: string; readonly description?: string; readonly withAsterisk?: boolean; readonly children?: ReactNode; readonly testId?: string; readonly fhirPath?: string; readonly readonly?: boolean; } export declare function ChooseScopeForm(props: ChooseScopeFormProps): JSX.Element; export declare interface ChooseScopeFormProps { readonly login: string; readonly scope: string | undefined; readonly handleAuthResponse: (response: LoginAuthenticationResponse) => void; readonly title?: string; readonly submitLabel?: string; readonly logo?: ReactNode; readonly children?: ReactNode; } /** * Clears all of the filters. * @param definition - The original search request. * @returns The updated search request. */ export declare function clearFilters(definition: SearchRequest): SearchRequest; /** * Clears all of the filters on a certain field. * @param definition - The original search request. * @param code - The field key name to clear filters. * @returns The updated search request. */ export declare function clearFiltersOnField(definition: SearchRequest, code: string): SearchRequest; export declare function CodeableConceptDisplay(props: CodeableConceptDisplayProps): JSX.Element; export declare interface CodeableConceptDisplayProps { readonly value?: CodeableConcept; } export declare function CodeableConceptInput(props: CodeableConceptInputProps): JSX.Element; export declare interface CodeableConceptInputProps extends Omit, ComplexTypeInputProps { readonly onChange?: (value: CodeableConcept | undefined) => void; } export declare function CodeInput(props: CodeInputProps): JSX.Element; export declare interface CodeInputProps extends Omit { readonly defaultValue?: string; readonly onChange: ((value: string | undefined) => void) | undefined; } export declare function CodingDisplay(props: CodingDisplayProps): JSX.Element; export declare interface CodingDisplayProps { readonly value?: Coding; readonly includeCode?: boolean; } export declare function CodingInput(props: CodingInputProps): JSX.Element; export declare interface CodingInputProps extends Omit, ComplexTypeInputProps { readonly response?: QuestionnaireResponseItem; } export declare function codingToValueSetElement(coding: Coding): ValueSetExpansionContains; export declare type Command = { command: string; value?: T; }; /** * Compares two resources by meta.lastUpdated descending. * Resources without meta.lastUpdated sort after resources with meta.lastUpdated. * @param a - First resource. * @param b - Second resource. * @returns Comparator result for Array.sort(). */ export declare function compareByLastUpdatedDescending(a: Resource, b: Resource): number; export declare interface ComplexTypeInputProps extends BaseInputProps { readonly name: string; readonly defaultValue?: ValueType; readonly onChange?: (value: ValueType, propName?: string) => void; readonly disabled?: boolean; } export declare function ContactDetailDisplay(props: ContactDetailDisplayProps): JSX.Element | null; export declare interface ContactDetailDisplayProps { readonly value?: ContactDetail; } export declare function ContactDetailInput(props: ContactDetailInputProps): JSX.Element; export declare type ContactDetailInputProps = ComplexTypeInputProps; export declare function ContactPointDisplay(props: ContactPointDisplayProps): JSX.Element | null; export declare interface ContactPointDisplayProps { readonly value?: ContactPoint; } export declare function ContactPointInput(props: ContactPointInputProps): JSX.Element; export declare type ContactPointInputProps = ComplexTypeInputProps & { readonly onChange?: (value: ContactPoint | undefined) => void; }; export declare function Container(props: ContainerProps): JSX.Element; /** * Converts an ISO-8601 date/time string to a local date/time string. * @param isoString - The ISO-8601 date/time string to convert. * @returns The local date/time string. */ export declare function convertIsoToLocal(isoString: string | undefined): string; /** * Converts a local date/time string to an ISO-8601 date/time string. * @param localString - The local date/time string to convert. * @returns The ISO-8601 date/time string. */ export declare function convertLocalToIso(localString: string | undefined): string; export declare function convertToPCM16(float32Array: Float32Array): Uint8Array; /** * Labs section — searches for both ServiceRequest and DiagnosticReport resources. * Accepts an optional `onRequestLabs` callback via closure. * @param onRequestLabs - Optional callback invoked when the user requests labs. * @returns A section config for labs. */ export declare function createLabsSection(onRequestLabs?: () => void): PatientSummarySectionConfig; /** * Pharmacies section — no FHIR searches; the Pharmacies component resolves its own data * from patient extensions. * Accepts an optional `pharmacyDialogComponent` via closure. * @param pharmacyDialogComponent - Optional component for the pharmacy search dialog. * @returns A section config for pharmacies. */ export declare function createPharmaciesSection(pharmacyDialogComponent?: ComponentType): PatientSummarySectionConfig; export { createPreferredPharmacyExtension } /** * Dynamically creates a script tag for the specified JavaScript file. * @param src - The JavaScript file URL. * @param onload - Optional callback for the onload event. */ export declare function createScriptTag(src: string, onload?: () => void): void; /** * The DateTimeInput component is a wrapper around the HTML5 input type="datetime-local". * The main purpose is to reconcile time zones. * Most of our date/time values are in ISO-8601, which includes a time zone offset. * The datetime-local input does not support the time zone offset. * @param props - The Input props. * @returns The JSX element to render. */ export declare function DateTimeInput(props: DateTimeInputProps): JSX.Element; export declare interface DateTimeInputProps extends PrimitiveTypeInputProps { readonly label?: string; readonly placeholder?: string; readonly defaultValue?: string; readonly autoFocus?: boolean; readonly outcome?: OperationOutcome; readonly onChange?: (value: string) => void; } /** The sort {@link SearchControl} applies when a search has no sort rules: Last Updated, newest first. */ export declare const DEFAULT_SORT_RULES: readonly SortRule[]; /** * Default item component for resource autocomplete inputs. * Displays the resource avatar, display name, and birth date or ID. */ export declare const DefaultResourceItemComponent: ForwardRefExoticComponent & RefAttributes>; export declare function DefaultResourceTimeline(props: DefaultResourceTimelineProps): JSX.Element; export declare interface DefaultResourceTimelineProps extends Pick, 'getMenu'> { readonly resource: Resource | Reference; } /** * Deletes a filter at the specified index. * @param definition - The original search request. * @param index - The filter index. * @returns The updated search request. */ export declare function deleteFilter(definition: SearchRequest, index: number): SearchRequest; /** Demographics section — no FHIR searches, renders patient info items directly. */ export declare const DemographicsSection: PatientSummarySectionConfig; export declare function DescriptionList(props: DescriptionListProps): JSX.Element; export declare function DescriptionListEntry(props: DescriptionListEntryProps): JSX.Element; export declare interface DescriptionListEntryProps { readonly term: string; readonly children: ReactNode; } export declare interface DescriptionListProps { readonly children: ReactNode; readonly compact?: boolean; } export declare function DiagnosticReportDisplay(props: DiagnosticReportDisplayProps): JSX.Element | null; export declare namespace DiagnosticReportDisplay { var defaultProps: DiagnosticReportDisplayProps; } export declare interface DiagnosticReportDisplayProps { readonly value?: DiagnosticReport | Reference; readonly hideObservationNotes?: boolean; readonly hideSpecimenInfo?: boolean; readonly hideSubject?: boolean; } declare function Document_2(props: PanelProps): JSX.Element; export { Document_2 as Document } export declare function ElementDefinitionInputSelector(props: ElementDefinitionSelectorProps): JSX.Element; export declare interface ElementDefinitionSelectorProps extends ResourcePropertyInputProps { readonly elementDefinitionTypes: ElementDefinitionType[]; } export declare function ElementDefinitionTypeInput(props: ElementDefinitionTypeInputProps): JSX.Element; export declare interface ElementDefinitionTypeInputProps extends Pick { readonly elementDefinitionType: ElementDefinitionType; readonly min: number; readonly max: number; readonly binding: ElementDefinitionBinding | undefined; readonly readOnly?: boolean; } export declare function EncounterTimeline(props: EncounterTimelineProps): JSX.Element; export declare interface EncounterTimelineProps extends Pick, 'getMenu'> { readonly encounter: Encounter | Reference; } /** * ErrorBoundary is a React component that handles errors in its child components. * See: https://reactjs.org/docs/error-boundaries.html */ export declare class ErrorBoundary extends Component { readonly state: ErrorBoundaryState; constructor(props: ErrorBoundaryProps); static getDerivedStateFromError(error: Error): ErrorBoundaryState; componentDidUpdate(_prevProps: ErrorBoundaryProps, _prevState: ErrorBoundaryState): void; shouldComponentUpdate(nextProps: ErrorBoundaryProps, nextState: ErrorBoundaryState): boolean; componentDidCatch(error: Error, errorInfo: ErrorInfo): void; render(): ReactNode; } export declare interface ErrorBoundaryProps { readonly children: ReactNode; } export declare interface ErrorBoundaryState { readonly error?: Error; readonly lastLocation: string; } /** * Evaluates the calculated expressions in a questionnaire. * Updates response item answers in place with the calculated values. * * See: https://build.fhir.org/ig/HL7/sdc/StructureDefinition-sdc-questionnaire-calculatedExpression.html * * @param items - The questionnaire items to evaluate. * @param response - The questionnaire response to evaluate against. * @param responseItems - The response items to update. */ export declare function evaluateCalculatedExpressionsInQuestionnaire(items: QuestionnaireItem[], response: QuestionnaireResponse, responseItems?: QuestionnaireResponseItem[] | undefined): void; /** * Creates a Blob object from the JSON object given and downloads the object. * @param jsonString - The JSON string. * @param fileName - Optional file name. Default is based on current timestamp. */ export declare function exportJsonFile(jsonString: string, fileName?: string): void; export declare type FetchOptionsFunction = (period: Period) => Promise[]>; /** * The FhirPathTable component represents the embeddable search table control. * @param props - FhirPathTable React props. * @returns FhirPathTable React node. */ export declare function FhirPathTable(props: FhirPathTableProps): JSX.Element; export declare interface FhirPathTableField { readonly propertyType: string; readonly name: string; readonly fhirPath: string; } export declare interface FhirPathTableProps { readonly resourceType: string; readonly query: string; readonly fields: FhirPathTableField[]; readonly checkboxesEnabled?: boolean; readonly onClick?: (e: SearchClickEvent) => void; readonly onAuxClick?: (e: SearchClickEvent) => void; readonly onBulk?: (ids: string[]) => void; } /** Descriptor for a single FHIR search that a section needs. */ export declare interface FhirSearchDescriptor { /** Unique key used to access this search's results via `SectionResults[key]`. */ readonly key: string; readonly resourceType: ResourceType; /** Which search param references the patient. Defaults to 'subject'. Examples: 'patient', 'beneficiary'. */ readonly patientParam?: string; /** * Additional search params — same format as the 2nd arg to medplum.searchResources(). * When using a string, do not include _count or _sort; they are appended automatically. */ readonly query?: QueryTypes; } export declare function Form(props: FormProps): JSX.Element; export declare interface FormProps { readonly onSubmit?: (formData: Record) => Promise | void; readonly style?: CSSProperties; readonly children?: ReactNode; readonly testid?: string; } export declare function FormSection(props: FormSectionProps): JSX.Element; export declare interface FormSectionProps { readonly title?: string; readonly htmlFor?: string; readonly description?: string; readonly withAsterisk?: boolean; readonly outcome?: OperationOutcome; readonly children?: ReactNode; readonly testId?: string; readonly fhirPath?: string; readonly errorExpression?: string; readonly readonly?: boolean; } /** * Returns the application name from environment variables or a default value. * @returns The application name. */ export declare function getAppName(): string; /** * Returns the default set of sections, matching the original hardcoded PatientSummary layout. * The `onRequestLabs` callback is threaded through to the Labs section. * @param onRequestLabs - Optional callback invoked when the user requests labs. * @returns The default array of section configs. */ export declare function getDefaultSections(onRequestLabs?: () => void): PatientSummarySectionConfig[]; export declare function getErrorsForInput(outcome: OperationOutcome | undefined, expression: string | undefined): string | undefined; /** * Returns the collection of field definitions for the search request. * @param search - The search request definition. * @returns An array of field definitions. */ export declare function getFieldDefinitions(search: SearchRequest): SearchControlField[]; export declare function getIssuesForExpression(outcome: OperationOutcome | undefined, expression: string | undefined): OperationOutcomeIssue[] | undefined; export declare function getItemAnswerOptionValue(option: QuestionnaireItemAnswerOption): TypedValue; export declare function getItemEnableWhenValueAnswer(enableWhen: QuestionnaireItemEnableWhen): TypedValue; export declare function getItemInitialValue(initial: QuestionnaireItemInitial | undefined): TypedValue; export declare function getNewMultiSelectValues(selected: string[], propertyName: string, item: QuestionnaireItem): QuestionnaireResponseItemAnswer[]; /** * Returns a string representing the operation. * @param op - The operation code. * @returns A display string for the operation. */ export declare function getOpString(op: Operator): string; /** * Returns control properties for pagination controls. * This is specifically for the Mantine Pagination component. * See: https://v7.mantine.dev/core/pagination/?t=props * @param controlName - The name of the pagination control (e.g., 'previous', 'next'). * @returns The properties for the pagination control. */ export declare function getPaginationControlProps(controlName: string): Record; export { getPreferredPharmaciesFromPatient } /** * Returns the reference filter for the given questionnaire item. * @see https://build.fhir.org/ig/HL7/fhir-extensions/StructureDefinition-questionnaire-referenceFilter-definitions.html * @param item - The questionnaire item to get the reference filter for. * @param subject - Optional subject reference. * @param encounter - Optional encounter reference. * @returns The reference filter as a map of key/value pairs. */ export declare function getQuestionnaireItemReferenceFilter(item: QuestionnaireItem, subject: Reference | undefined, encounter: Reference | undefined): Record | undefined; export declare function getQuestionnaireItemReferenceTargetTypes(item: QuestionnaireItem): ResourceType[] | undefined; /** * Starts a request to generate a recapcha token. * @param siteKey - The reCAPTCHA site key, available from the reCAPTCHA admin page. * @returns Promise to a recaptcha token for the current user. */ export declare function getRecaptcha(siteKey: string): Promise; export declare function getResponseItemAnswerValue(answer: QuestionnaireResponseItemAnswer): TypedValue | undefined; /** * Returns a list of operators for a search parameter. * @param searchParam - The search parameter. * @returns The list of operators that can be used for the search parameter. */ export declare function getSearchOperators(searchParam: SearchParameter): Operator[] | undefined; /** * Builds grouped Select options (Fields, then Metadata) for choosing a search parameter. * @param searchParams - The resource type's search parameters, keyed by code. * @returns The grouped Select data. */ export declare function getSearchParamSelectData(searchParams: Record): ComboboxData; /** * Sort direction labels by search parameter type: dates oldest/newest, numbers smallest/largest, else A/Z. * @param type - The search parameter type. * @returns The ascending and descending labels. */ export declare function getSortDirectionLabels(type: string | undefined): { asc: string; desc: string; }; export declare function getSortField(definition: SearchRequest): string | undefined; export declare function getValuePath(elementPath: string, valuePath: string | undefined, arrayIndex?: number): string; /** Goals section — searches for Goal resources. */ export declare const GoalsSection: PatientSummarySectionConfig; export declare function Header(props: HeaderProps): JSX.Element; export declare interface HeaderProps { readonly pathname?: string; readonly searchParams?: URLSearchParams; readonly headerSearchDisabled?: boolean; readonly logo: ReactNode; readonly version?: string; readonly navbarOpen?: boolean; readonly navbarToggle: () => void; readonly notifications?: ReactNode; readonly announcements?: AppShellAnnouncement[]; readonly onDismissAnnouncement?: (announcement: AppShellAnnouncement) => void; } export declare type HeaderSearchTypes = Patient | ServiceRequest; export declare function HumanNameDisplay(props: HumanNameDisplayProps): JSX.Element | null; export declare interface HumanNameDisplayProps { readonly value?: HumanName; readonly options?: HumanNameFormatOptions; } export declare function HumanNameInput(props: HumanNameInputProps): JSX.Element; export declare type HumanNameInputProps = ComplexTypeInputProps; export declare function IdentifierDisplay(props: IdentifierDisplayProps): JSX.Element; export declare interface IdentifierDisplayProps { readonly value?: Identifier; } export declare function IdentifierInput(props: IdentifierInputProps): JSX.Element; export declare type IdentifierInputProps = ComplexTypeInputProps; /** Immunizations section — searches for Immunization resources. */ export declare const ImmunizationsSection: PatientSummarySectionConfig; export declare function InfoBar(props: InfoBarProps): JSX.Element; export declare namespace InfoBar { var Entry: (props: InfoBarEntryProps) => JSX.Element; var Key: (props: InfoBarKeyProps) => JSX.Element; var Value: (props: InfoBarValueProps) => JSX.Element; } export declare interface InfoBarEntryProps { readonly children: ReactNode; } export declare interface InfoBarKeyProps { readonly children: ReactNode; } export declare interface InfoBarProps { readonly children: ReactNode; } /** * Loading placeholder that mirrors the InfoBar layout: an optional avatar followed by * key/value entries of varying width. * @param props - The skeleton props. * @returns The InfoBarSkeleton React node. */ export declare function InfoBarSkeleton(props: InfoBarSkeletonProps): JSX.Element; export declare interface InfoBarSkeletonProps { readonly withAvatar?: boolean; readonly entries?: number; } export declare interface InfoBarValueProps { readonly children: ReactNode; } /** * Dynamically loads the recaptcha script. * We do not want to load the script on page load unless the user needs it. * @param siteKey - The reCAPTCHA site key, available from the reCAPTCHA admin page. */ export declare function initRecaptcha(siteKey: string): void; /** Insurance section — searches for Coverage resources. */ export declare const InsuranceSection: PatientSummarySectionConfig; export declare type IntervalGroup = { id: string; filters: Record; intervals: ObservationDefinitionQualifiedInterval[]; }; export { isAddPharmacyResponse } /** * Returns true if the event is an auxiliary click. * @param e - The event. * @returns True if the event is an auxiliary click. */ export declare function isAuxClick(e: MouseEvent_2): boolean; /** * Returns true if the element is a checkbox or a table cell containing a checkbox. * Table cells containing checkboxes are commonly accidentally clicked. * @param el - The HTML DOM element. * @returns True if the element is a checkbox or a table cell containing a checkbox. */ export declare function isCheckboxCell(el: Element): boolean; /** * Returns true if the item is a choice question. * @param item - The questionnaire item to check. * @returns True if the item is a choice question, false otherwise. */ export declare function isChoiceQuestion(item: QuestionnaireItem): boolean; /** * Returns true if the given search parameter code refers to a resource metadata field. * @param code - The search parameter code. * @returns True if the code is a meta search parameter. */ export declare function isMetaSearchParam(code: string): boolean; export { isOrganizationArray } /** * Returns true if the questionnaire item is enabled based on the enableWhen conditions or expression. * @param item - The questionnaire item to check. * @param questionnaireResponse - The questionnaire response to check against. * @returns True if the question is enabled, false otherwise. */ export declare function isQuestionEnabled(item: QuestionnaireItem, questionnaireResponse: QuestionnaireResponse | undefined): boolean; /** * Returns true when two lists of sort rules sort the same way. A missing `descending` counts as ascending. * @param a - The first sort rules. * @param b - The second sort rules. * @returns True if both lists have the same codes and directions in the same order. */ export declare function isSameSort(a: readonly SortRule[], b: readonly SortRule[]): boolean; export declare function isSortDescending(definition: SearchRequest): boolean; export declare function isSupportedProfileStructureDefinition(profile?: StructureDefinition): profile is SupportedProfileStructureDefinition; /** * Returns true if an error thrown while expanding a ValueSet means the value set itself is * unavailable — a permanent 400/404 (e.g. "ValueSet not found"). Transient failures (429 rate * limit, 401, 5xx, network) return false so a blip never disables a field. * @param err - The error thrown by `valueSetExpand`. * @returns True for a permanent 400/404, false for a transient failure. */ export declare function isValueSetUnavailableError(err: unknown): boolean; /** * Kills a browser event. * Prevents default behavior. * Stops event propagation. * @param e - The event. */ export declare function killEvent(e: Event | SyntheticEvent): void; export declare type LabItem = WithId | WithId; export declare function LabOrderDetails(props: LabOrderDetailsProps): JSX.Element; export declare interface LabOrderDetailsProps { order: ServiceRequest; onChange?: (order: WithId) => void; onResume?: () => void; selectedReport?: Reference; } export declare function LabOrdersPanel(props: LabOrdersPanelProps): JSX.Element; export declare interface LabOrdersPanelOrderModalProps { readonly opened: boolean; readonly draftOrder: WithId | undefined; readonly onClose: () => void; readonly onSaved: () => void; } /** * LabOrdersPanel lists a patient's lab orders and results, and shows the selected one. * It does no routing: the caller derives the search and selection from the URL and navigates. * @param patient - The patient whose labs are listed. * @param search - The normalized search for the active tab (status, sort, count, offset). * @param activeTab - The active tab. * @param selectedId - The id of the selected order or result. * @param getItemUri - A function to build the URI of a list item. * @param onChange - Called with the new search when the page changes. * @param completedUri - The URI for the completed tab. * @param openUri - The URI for the open tab. * @param revokedUri - The URI for the revoked tab. * @param onNew - Called after an order is submitted or a draft is saved. * @param renderOrderModal - Renders the order modal. Without it, ordering and resuming drafts are hidden. */ export declare interface LabOrdersPanelProps { readonly patient: Patient | Reference | undefined; readonly search: SearchRequest; readonly activeTab: LabTab; readonly selectedId: string | undefined; readonly getItemUri: (item: LabItem) => string; readonly onChange: (search: SearchRequest) => void; readonly completedUri: string; readonly openUri: string; readonly revokedUri: string; readonly onNew?: () => void; readonly renderOrderModal?: (props: LabOrdersPanelOrderModalProps) => ReactNode; } export declare function LabResultDetails(props: LabResultDetailsProps): JSX.Element; export declare interface LabResultDetailsProps { result: DiagnosticReport; } /** Default Labs section constant (no onRequestLabs callback). */ export declare const LabsSection: PatientSummarySectionConfig; export declare type LabTab = 'open' | 'completed' | 'revoked'; export declare function LinkTabs(props: LinkTabsProps): JSX.Element; export declare interface LinkTabsProps extends Omit { readonly baseUrl: string; readonly tabs: string[] | TabDefinition[]; readonly children?: React.ReactNode; } /** * ListWithDetailPane is a generic, presentational master-detail shell: a left sidebar * with optional pill tabs, header actions, a scrollable list, and pagination, plus a * detail area for the selected item. It does no data fetching — it renders what it is * given, navigates via links, and emits `onPageChange` / `onSelectFirst` callbacks. * @param props - The ListWithDetailPane React props. * @returns The ListWithDetailPane React node. */ export declare function ListWithDetailPane(props: ListWithDetailPaneProps): JSX.Element; export declare interface ListWithDetailPaneDetailContext { readonly refresh?: () => Promise; } /** The sidebar header is plain text or pill tabs, never both. */ export declare type ListWithDetailPaneHeaderProps = ListWithDetailPaneTextHeaderProps | ListWithDetailPaneTabsHeaderProps; export declare interface ListWithDetailPaneItemContext { readonly selected: boolean; readonly index: number; readonly items: T[]; } export declare type ListWithDetailPaneProps = ListWithDetailPanePropsBase & ListWithDetailPaneHeaderProps; /** * Props shared by every ListWithDetailPane, independent of the header style. * @param items - The current page of items to render in the list. * @param loading - When true, the list area shows the skeleton instead of items. * @param selectedKey - Id of the highlighted row. * @param renderItem - Renders one row of the list sidebar. * @param emptyList - Shown when the list is empty. Default: dimmed "No items found". * @param skeleton - Shown while loading. Default: built-in skeleton rows. * @param listWidth - Sidebar width in pixels. Default 350. * @param listVisible - Whether the list sidebar is shown. Default true. When false the sidebar collapses * (animated) and is removed from the accessibility tree. Controlled — consumers render their own toggle * buttons (typically a collapse icon in `headerActions` and an expand icon somewhere in the detail pane). * @param headerActions - Right-aligned slot in the sidebar header row: action buttons, filter popovers. * @param selected - The resolved selected item, or undefined when nothing is selected. * @param renderDetail - Renders the detail pane for the selected item. * @param emptyDetail - Shown when nothing is selected. Default: dimmed prompt. * @param listFooter - Pinned below the scrolling list and above the pagination row, e.g. bulk actions * for the current list. Rendered only when the list has finished loading. * @param refresh - Optional. Passed through to the detail render context so the detail pane can refetch the list. * @param onSelectFirst - Auto-select escape hatch. Fired with the first item when the list has finished loading * (`loading` false) with items while nothing is selected (`selectedKey` undefined). The consumer decides how to * navigate (typically with history replace). Pass an id-driven `selectedKey` (e.g. the URL route param) so a * selection that is still resolving does not read as "nothing selected", and keep `loading` true from the render a * new search starts on, so this never fires against a stale list. * @param page - Current 1-based page. Pagination is hidden unless this, `pageCount`, and `onPageChange` are set. * @param pageCount - Total number of pages. Pagination is hidden when this is less than or equal to 1. * @param onPageChange - Fired by the built-in pagination with the new 1-based page. */ export declare interface ListWithDetailPanePropsBase { readonly items: T[]; readonly loading: boolean; readonly selectedKey?: string; readonly renderItem: (item: T, ctx: ListWithDetailPaneItemContext) => ReactNode; readonly emptyList?: ReactNode; readonly skeleton?: ReactNode; readonly listWidth?: number; readonly listVisible?: boolean; readonly headerActions?: ReactNode; readonly selected: T | undefined; readonly renderDetail: (selected: T, ctx: ListWithDetailPaneDetailContext) => ReactNode; readonly emptyDetail?: ReactNode; readonly listFooter?: ReactNode; readonly refresh?: () => Promise; readonly onSelectFirst?: (item: T) => void; readonly page?: number; readonly pageCount?: number; readonly onPageChange?: (page: number) => void; } export declare interface ListWithDetailPaneTab { readonly value: string; readonly label: ReactNode; readonly uri: string; } /** * Pill-tab header. Declares `headerText` as `never` so tabs can't be mixed with a title. * Each tab renders as a link to its `uri`, so tab switching needs no change callback. * @param tabs - Sidebar header tabs. Selecting a tab navigates to its URI. * @param activeTab - Controlled active tab value; consumers derive it from the URL. */ export declare interface ListWithDetailPaneTabsHeaderProps { readonly tabs: ListWithDetailPaneTab[]; readonly activeTab?: string; readonly headerText?: never; } /** * Plain-text header (or no header at all). Declares the tab fields as `never` so a title * can't be mixed with tabs. * @param headerText - Plain title shown at the left of the header. */ export declare interface ListWithDetailPaneTextHeaderProps { readonly headerText?: ReactNode; readonly tabs?: never; readonly activeTab?: never; } export declare function Loading(): JSX.Element; export declare function Logo(props: LogoProps): JSX.Element; export declare interface LogoProps { readonly size: number; readonly fill?: string; } export declare function MeasureReportDisplay(props: MeasureReportDisplayProps): JSX.Element | null; export declare interface MeasureReportDisplayProps { readonly measureReport: MeasureReport | Reference; } /** Thrown by {@link UseMedicationCartReturn.checkout} when an {@link UseMedicationCartReturn.addToCart} call is still in flight. */ export declare const MEDICATION_CART_ADD_IN_PROGRESS = "Cannot checkout while a medication is still being added to the cart"; export declare interface MedicationIFrameOptions { readonly patientId?: string; /** Selected practice location for multi-practice deployments. */ readonly organization?: Reference; readonly onPatientSyncSuccess?: () => void; readonly onIframeSuccess?: (url: string) => void; readonly onError?: (err: unknown) => void; } /** Medications section — searches for MedicationRequest and MedicationStatement resources. */ export declare const MedicationsSection: PatientSummarySectionConfig; export declare interface MedplumContext { medplum: MedplumClient; navigate: MedplumNavigateFunction; profile?: ProfileResource; loading: boolean; } export declare function MedplumLink(props: MedplumLinkProps): JSX.Element; export declare interface MedplumLinkProps extends AnchorProps, ElementProps<'a', keyof AnchorProps> { readonly to?: Resource | Reference | string; readonly suffix?: string; readonly label?: string; readonly onClick?: MouseEventHandler; readonly children: ReactNode; } export declare type MedplumNavigateFunction = (path: string) => void; /** * The MedplumProvider component provides Medplum context state. * * Medplum context includes: * 1) medplum - Medplum client library * 2) profile - The current user profile (if signed in) * @param props - The MedplumProvider React props. * @returns The MedplumProvider React node. */ export declare function MedplumProvider(props: MedplumProviderProps): JSX.Element; export declare interface MedplumProviderProps { readonly medplum: MedplumClient; readonly navigate?: MedplumNavigateFunction; readonly children: ReactNode; } export declare const MemoizedFhirPathTable: MemoExoticComponent; /** * Shared MFA enrollment UI used during sign-in and on the MFA settings page. * When the user is allowed to enroll in more than one method it leads with a * chooser; an email-only project shows a single "enable" prompt; otherwise it * shows the authenticator (TOTP) QR code. The chooser and email-only screens * are identical across contexts, while the TOTP step's wording is supplied by * the caller. * @param props - The MfaEnrollForm React props. * @returns The MfaEnrollForm React node. */ export declare function MfaEnrollForm(props: MfaEnrollFormProps): JSX.Element; export declare interface MfaEnrollFormProps { /** The MFA methods the user is allowed to enroll in. */ readonly allowedMethods: MfaMethod[]; /** The TOTP QR code data URL, shown when enrolling an authenticator app. */ readonly qrCodeUrl?: string; /** Enroll the email factor (the server emails a code on subsequent sign-ins). */ readonly onEnrollEmail: () => void; /** Enroll the TOTP factor with the code from the user's authenticator app. */ readonly onEnrollTotp: (token: string) => void | Promise; /** Title for the authenticator (TOTP) QR enrollment step. */ readonly totpTitle: string; /** Optional description shown alongside the TOTP QR code. */ readonly totpDescription?: ReactNode; /** Submit button label for the TOTP step. */ readonly totpButtonText?: string; } export declare function MfaForm(props: MfaFormProps): JSX.Element; export declare type MfaFormFields = 'token'; export declare interface MfaFormProps { readonly title: string; readonly buttonText: string; readonly description?: ReactNode; readonly qrCodeUrl?: string; readonly onSubmit: (formData: Record) => void | Promise; /** Optional content rendered below the submit button (e.g. an alternate MFA method action). */ readonly footer?: ReactNode; } /** An MFA factor a user can enroll in or verify with. */ export declare type MfaMethod = 'totp' | 'email'; /** * Shared MFA verification UI used during sign-in and when changing MFA * settings. It leads with the authenticator code and, when email is also an * available method, offers a "Get a code by email instead" action. Once in * email mode it shows the emailed-code entry with a "Resend code" action. * @param props - The MfaVerificationForm React props. * @returns The MfaVerificationForm React node. */ export declare function MfaVerificationForm(props: MfaVerificationFormProps): JSX.Element; export declare interface MfaVerificationFormProps { /** The MFA methods the user can verify with. */ readonly methods: MfaMethod[]; /** The user's email, shown when entering an emailed code. */ readonly email?: string; /** * Whether to start in email-code-entry mode. Use when email is the only * method (and a code has already been sent), so the user goes straight to * entering the code instead of an authenticator code. */ readonly initialEmailMode?: boolean; /** Sends (or resends) a verification code to the user's email. */ readonly onRequestEmailCode: () => void | Promise; /** Called with the entered token (an authenticator code or an emailed code). */ readonly onSubmit: (token: string) => void | Promise; /** Optional override for the submit button label. */ readonly buttonText?: string; } /** * A modal with the standard Medplum chrome: a bold title above a border, one scrolling body, and * action buttons pinned to the bottom edge. Owns the layout so call sites pass content and actions * rather than assembling a shell out of `Stack`, `Divider` and `styles` overrides. * * All other Mantine `Modal` props pass through. `scrollAreaComponent` does not, because it inserts * an element between the content and the body that breaks the flex chain the pinned footer needs. * @param props - The Modal React props. * @returns The Modal React node. */ export declare function Modal(props: ModalProps): JSX.Element; /** * Props for {@link Modal}. */ export declare interface ModalProps extends Omit { /** Modal body, rendered in the scrolling region between the header and the footer. */ readonly children: ReactNode; /** * Buttons pinned to the bottom edge of the modal above a full-bleed border. * They stretch to the full width with the primary action first; wrap them in a * `Group justify="flex-end"` for a right-aligned row instead. Omit for modals that only display * content - the footer and its border are then not rendered. */ readonly actions?: ReactNode; /** * Wraps the body and the footer in a {@link Form}, so a `SubmitButton` in * `actions` submits the named inputs in `children`. A `SubmitButton` without this has no form to * submit and does nothing. */ readonly onSubmit?: (formData: Record) => Promise | void; /** * Fixed body height as a CSS length, e.g. `'60vh'`, for modals whose content * is a fixed layout rather than a form that should size to its fields. Omit to size to the content. */ readonly bodyHeight?: string; } export declare function MoneyDisplay(props: MoneyDisplayProps): JSX.Element | null; export declare interface MoneyDisplayProps { readonly value?: Money; } export declare function MoneyInput(props: MoneyInputProps): JSX.Element; export declare interface MoneyInputProps extends ComplexTypeInputProps { readonly label?: string; readonly placeholder?: string; } export declare function MultiResourceInput(props: MultiResourceInputProps): JSX.Element | null; export declare interface MultiResourceInputProps { readonly resourceType: T['resourceType']; readonly name: string; /** * Initial selected values. Each entry may be a full resource or a reference that will be * resolved on mount. Treated as uncontrolled — changes after mount are ignored. */ readonly defaultValue?: (T | Reference)[]; readonly searchCriteria?: Record; /** The search parameter, with any modifier, that the typed text is sent as (e.g. `name:contains`). Defaults to one chosen by resource type. */ readonly searchParam?: string; readonly placeholder?: string; readonly required?: boolean; readonly itemComponent?: (props: AsyncAutocompleteOption) => JSX.Element | ReactNode; /** Called whenever the selection changes. Receives the full array of selected resources. */ readonly onChange?: (value: T[]) => void; readonly disabled?: boolean; readonly label?: AsyncAutocompleteProps['label']; /** * Names the field for assistive technology, for use instead of a visible `label` (don't pass both). The name * goes on the search box and on a group around the whole field, which keeps the chosen resources named while the * search box is hidden (disabled or at `maxValues`). */ readonly 'aria-label'?: AsyncAutocompleteProps['aria-label']; readonly error?: AsyncAutocompleteProps['error']; /** Maximum number of resources that can be selected. Defaults to uncapped. */ readonly maxValues?: number; /** Render the options dropdown inside the DOM tree (not a portal); defaults to portalled. */ readonly withinPortal?: boolean; /** Whether to show a button that clears the whole selection. Defaults to true. */ readonly clearable?: boolean; } export declare function Navbar(props: NavbarProps): JSX.Element; export declare interface NavbarLink { readonly icon?: JSX.Element; readonly label?: string; readonly href: string; /** Static count to display. Ignored if notificationCount is provided. */ readonly count?: number; /** If true, shows red alert styling (red dot on collapsed icon, red count text when expanded). */ readonly alert?: boolean; /** Live subscription-based count. Overrides static `count` when provided. */ readonly notificationCount?: { readonly resourceType: ResourceType; readonly countCriteria: string; readonly subscriptionCriteria: string; }; /** Callback fired when the dismiss button is clicked. When provided, a dismiss (X) button appears on hover. */ readonly onDismiss?: () => void; } export declare interface NavbarMenu { readonly title?: string; readonly links?: NavbarLink[]; } export declare interface NavbarProps { readonly pathname?: string; readonly searchParams?: URLSearchParams; readonly logo?: ReactNode; readonly menus?: NavbarMenu[]; readonly navbarToggle: () => void; readonly closeNavbar: () => void; readonly spotlightEnabled?: boolean; readonly patientsOnly?: boolean; readonly spotlightActions?: SpotlightLinkAction[]; readonly userMenuEnabled?: boolean; readonly displayAddBookmark?: boolean; readonly resourceTypeSearchDisabled?: boolean; readonly opened?: boolean; readonly version?: string; readonly showLayoutVersionToggle?: boolean; } export declare const NewTopicDialog: (props: NewTopicDialogProps) => JSX.Element; /** * Props for the NewTopicDialog component. * @param subject - The patient to associate with the new thread. When provided and `allowPatientSelection` is false, the patient field is pre-filled and disabled. * @param opened - Whether the dialog is open. * @param onClose - Callback fired when the dialog is closed. * @param onSubmit - Callback fired with the created Communication resource after successful submission. * @param allowPatientSelection - When true, the patient field is an editable search input. When false (default), the field is pre-filled from `subject` and disabled. Use true for provider-facing contexts, false for patient-facing apps. */ export declare interface NewTopicDialogProps { subject: Reference | Patient | undefined; opened: boolean; onClose: () => void; onSubmit?: (communication: Communication) => void; allowPatientSelection?: boolean; } export declare function NoteDisplay({ value }: NoteDisplayProps): JSX.Element | null; export declare interface NoteDisplayProps { readonly value?: Annotation[]; } export declare function NotificationIcon(props: NotificationIconProps): JSX.Element; export declare interface NotificationIconProps { readonly iconComponent: JSX.Element; readonly label?: string; readonly tooltip?: string; readonly resourceType: ResourceType; readonly countCriteria: string; readonly subscriptionCriteria: string; readonly onClick?: () => void; } export declare function ObservationTable(props: ObservationTableProps): JSX.Element; export declare interface ObservationTableProps { readonly value?: Observation[] | Reference[]; readonly ancestorIds?: string[]; readonly hideObservationNotes?: boolean; } export declare function OperationOutcomeAlert(props: OperationOutcomeAlertProps): JSX.Element | null; export declare interface OperationOutcomeAlertProps extends AlertProps { readonly outcome?: OperationOutcome; readonly issues?: OperationOutcomeIssue[]; readonly displayOkOutcomes?: boolean; } export declare function Panel(props: PanelProps): JSX.Element; export declare interface PanelProps extends PaperProps { readonly width?: number; readonly fill?: boolean; readonly children?: ReactNode; } /** * Parses an HTML form and returns the result as a JavaScript object. * @param form - The HTML form element. * @returns Form values in key value pairs. */ export declare function parseForm(form: HTMLFormElement): Record; export declare function ParticipantFilter(props: ParticipantFilterProps): JSX.Element; export declare interface ParticipantFilterProps { readonly selectedParticipants: Reference[]; readonly onFilterChange: (participants: Reference[]) => void; } /** * Splits search parameter codes into resource fields and `_`-prefixed metadata, each sorted by label. * @param codes - The search parameter codes. * @returns The field and metadata codes. */ export declare function partitionSearchParams(codes: string[]): { fields: string[]; metadata: string[]; }; /** * Mantine's `PasswordInput` sets `tabIndex={-1}` and `aria-hidden` on the visibility toggle button * unless `visibilityToggleButtonProps` is provided, which removes it from the keyboard tab order and * hides it from assistive technology. This wrapper defaults the toggle to be keyboard accessible. * @param props - The password input props. * @returns The password input component. */ export declare function PasswordInput(props: PasswordInputProps): JSX.Element; export { PATIENT_PREFERRED_PHARMACY_URL } export declare function PatientAccountsForm(props: PatientAccountsFormProps): JSX.Element; export declare interface PatientAccountsFormProps { readonly patient: Patient; readonly onSaved?: () => void; } export declare function PatientExportForm(props: PatientExportFormProps): JSX.Element; export declare interface PatientExportFormProps { readonly patient: Patient | Reference; } export declare function PatientHeader(props: PatientHeaderProps): JSX.Element | null; export declare interface PatientHeaderProps { readonly patient: Patient | Reference; } export declare function PatientSummary(props: PatientSummaryProps): JSX.Element | null; export declare interface PatientSummaryData { /** One SectionResults map per section, indexed to match the sections array. */ readonly sectionData: SectionResults[]; readonly loading: boolean; readonly error: Error | undefined; readonly refresh: () => void; } export declare interface PatientSummaryProps { readonly patient: Patient | Reference; readonly onClickResource?: (resource: Resource) => void; readonly onRequestLabs?: () => void; readonly sections?: PatientSummarySectionConfig[]; readonly headerMenuItems?: ReactNode; readonly headerLink?: Resource | Reference | string; readonly onEditPatient?: () => void; } /** * Configuration for a single section in the PatientSummary. * The `searches` field is an array to support sections like Labs which need multiple resource types. */ export declare interface PatientSummarySectionConfig { readonly key: string; readonly title: string; readonly searches?: FhirSearchDescriptor[]; /** * React component that renders this section. * Using ComponentType (rather than a render-prop function) ensures React treats it as a real * component, so hooks inside custom sections work correctly. */ readonly component: ComponentType; } /** * Loading placeholder that mirrors the PatientSummary layout: the patient header followed by * demographic rows and a set of collapsible sections with their items. * @param props - The skeleton props. * @returns The PatientSummarySkeleton React node. */ export declare function PatientSummarySkeleton(props: PatientSummarySkeletonProps): JSX.Element; export declare interface PatientSummarySkeletonProps { readonly sections?: number; } export declare function PatientTimeline(props: PatientTimelineProps): JSX.Element; export declare interface PatientTimelineProps extends Pick, 'getMenu'> { readonly patient: Patient | Reference; } export declare function Pharmacies(props: PharmaciesProps): JSX.Element; export declare interface PharmaciesProps { readonly patient: Patient; readonly pharmacies?: Organization[]; readonly onClickResource?: (resource: Organization) => void; readonly pharmacyDialogComponent?: ComponentType; } /** Default Pharmacies section constant (no pharmacy dialog component). */ export declare const PharmaciesSection: PatientSummarySectionConfig; export { PHARMACY_PREFERENCE_TYPE_SYSTEM } export { PHARMACY_TYPE_PREFERRED } export { PHARMACY_TYPE_PRIMARY } /** * Renders a dialog for searching and adding pharmacies to a patient's favorites. * This is a generic component that accepts search and add callbacks. * @param props - The dialog props. * @returns The pharmacy dialog component. */ export declare function PharmacyDialog(props: PharmacyDialogProps): JSX.Element; /** * Base props that any pharmacy dialog component must accept. */ export declare interface PharmacyDialogBaseProps { readonly patient: Patient; readonly onSubmit: (pharmacy: Organization) => void; readonly onClose: () => void; } export declare interface PharmacyDialogProps { readonly patient: Patient; readonly onSubmit: (pharmacy: Organization) => void; readonly onClose: () => void; readonly onSearch: (params: PharmacySearchParams & Record) => Promise; readonly onAddToFavorites: (params: AddFavoriteParams) => Promise; /** Optional fields rendered inside the search form above the submit button. */ readonly renderBeforeSearchButton?: ReactNode; /** * Extra search parameters merged into the bot request (e.g. vendor-specific filters). * `handleSearch` depends on this callback, so callers should memoize it (e.g. `useCallback`) * to avoid re-creating the search handler on every render. */ readonly getExtraSearchParams?: () => Record; /** Optional per-field placeholder overrides for the search form. */ readonly searchPlaceholders?: PharmacySearchFieldPlaceholders; } /** * Placeholder text for each pharmacy search field. Vendors can override these to * reflect their own API constraints (e.g. DoseSpot requires a 3-character minimum * on text searches, whereas ScriptSure expects a 2-letter state and 5-digit ZIP). */ export declare interface PharmacySearchFieldPlaceholders { readonly name?: string; readonly city?: string; readonly state?: string; readonly zip?: string; readonly phoneOrFax?: string; readonly address?: string; readonly ncpdpID?: string; } export { PharmacySearchParams } export declare function PlanDefinitionBuilder(props: PlanDefinitionBuilderProps): JSX.Element | null; export declare interface PlanDefinitionBuilderProps { readonly value: Partial | Reference; readonly onSubmit: (result: PlanDefinition) => void; } export { PreferredPharmacy } export declare interface PrimitiveTypeInputProps { readonly id?: string; readonly name: string; readonly 'data-testid'?: string; readonly defaultValue?: any; readonly required?: boolean; readonly error?: string; readonly disabled?: boolean; } /** Problem List section — searches for Condition resources. */ export declare const ProblemListSection: PatientSummarySectionConfig; export declare function QrCodeScanner({ onScan, onError, scanOnce }: QrCodeScannerProps): JSX.Element; export declare interface QrCodeScannerProps { readonly onScan: (data: string) => void; readonly onError?: (error: Error) => void; readonly scanOnce?: boolean; } export declare function QuantityDisplay(props: QuantityDisplayProps): JSX.Element | null; export declare interface QuantityDisplayProps { readonly value?: Quantity; readonly precision?: number; } export declare function QuantityInput(props: QuantityInputProps): JSX.Element; export declare interface QuantityInputProps extends ComplexTypeInputProps { readonly autoFocus?: boolean; readonly required?: boolean; readonly disableWheel?: boolean; } export declare const QUESTIONNAIRE_CALCULATED_EXPRESSION_URL = "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-calculatedExpression"; export declare const QUESTIONNAIRE_ENABLED_WHEN_EXPRESSION_URL = "http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-enableWhenExpression"; export declare const QUESTIONNAIRE_HIDDEN_URL = "http://hl7.org/fhir/StructureDefinition/questionnaire-hidden"; export declare const QUESTIONNAIRE_ITEM_CONTROL_URL = "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl"; export declare const QUESTIONNAIRE_OPTION_EXCLUSIVE_URL = "http://hl7.org/fhir/StructureDefinition/questionnaire-optionExclusive"; export declare const QUESTIONNAIRE_REFERENCE_FILTER_URL = "http://hl7.org/fhir/StructureDefinition/questionnaire-referenceFilter"; export declare const QUESTIONNAIRE_REFERENCE_RESOURCE_URL = "http://hl7.org/fhir/StructureDefinition/questionnaire-referenceResource"; export declare const QUESTIONNAIRE_SIGNATURE_REQUIRED_URL = "http://hl7.org/fhir/StructureDefinition/questionnaire-signatureRequired"; export declare const QUESTIONNAIRE_SIGNATURE_RESPONSE_URL = "http://hl7.org/fhir/StructureDefinition/questionnaireresponse-signature"; export declare const QUESTIONNAIRE_VALIDATION_ERROR_URL = "http://hl7.org/fhir/StructureDefinition/questionnaire-validationError"; export declare function QuestionnaireBuilder(props: QuestionnaireBuilderProps): JSX.Element | null; export declare interface QuestionnaireBuilderProps { readonly questionnaire: Partial | Reference; readonly onSubmit: (result: Questionnaire) => void; readonly autoSave?: boolean; } export declare function QuestionnaireForm(props: QuestionnaireFormProps): JSX.Element | null; export declare interface QuestionnaireFormLoadedState { /** Not loading */ readonly loading: false; /** The loaded questionnaire */ questionnaire: Questionnaire; /** The current draft questionnaire response */ questionnaireResponse: QuestionnaireResponse; /** Optional questionnaire subject */ subject?: Reference; /** Optional questionnaire encounter */ encounter?: Reference; /** The top level items for the current page */ items: QuestionnaireItem[]; /** The response items for the current page */ responseItems: QuestionnaireResponseItem[]; /** * Adds a new group item to the current context. * @param context - The current context of the questionnaire response items. * @param item - The questionnaire item that is being added to the group. */ onAddGroup: (context: QuestionnaireResponseItem[], item: QuestionnaireItem) => void; /** * Adds an answer to a repeating item. * @param context - The current context of the questionnaire response items. * @param item - The questionnaire item that is being answered. */ onAddAnswer: (context: QuestionnaireResponseItem[], item: QuestionnaireItem) => void; /** * Changes an answer value. * @param context - The current context of the questionnaire response items. * @param item - The questionnaire item that is being answered. * @param answer - The answer(s) provided by the user for the questionnaire item. */ onChangeAnswer: (context: QuestionnaireResponseItem[], item: QuestionnaireItem, answer: QuestionnaireResponseItemAnswer[]) => void; /** * Sets or updates the signature for the questionnaire response. * @param signature - The signature to set, or undefined to clear the signature. */ onChangeSignature: (signature: Signature | undefined) => void; } export declare interface QuestionnaireFormLoadingState { /** Currently loading data such as the Questionnaire or the QuestionnaireResponse default value */ readonly loading: true; } export declare interface QuestionnaireFormPage { readonly linkId: string; readonly title: string; readonly group: QuestionnaireItem & { type: 'group'; }; } export declare interface QuestionnaireFormPaginationState extends QuestionnaireFormLoadedState { readonly pagination: true; pages: QuestionnaireFormPage[]; activePage: number; onNextPage: () => void; onPrevPage: () => void; } export declare interface QuestionnaireFormProps { readonly questionnaire: Questionnaire | Reference; readonly questionnaireResponse?: QuestionnaireResponse | Reference; readonly subject?: Reference; readonly encounter?: Reference; readonly source?: QuestionnaireResponse['source']; readonly disablePagination?: boolean; readonly excludeButtons?: boolean; readonly submitButtonText?: string; /** Optional content rendered immediately below the header row, before the form items. */ readonly afterHeader?: ReactNode; readonly onChange?: (response: QuestionnaireResponse) => void; readonly onSubmit?: (response: QuestionnaireResponse) => void; } export declare interface QuestionnaireFormSinglePageState extends QuestionnaireFormLoadedState { readonly pagination: false; } export declare type QuestionnaireFormState = QuestionnaireFormLoadingState | QuestionnaireFormSinglePageState | QuestionnaireFormPaginationState; export declare const QuestionnaireItemType: { readonly group: "group"; readonly display: "display"; readonly question: "question"; readonly boolean: "boolean"; readonly decimal: "decimal"; readonly integer: "integer"; readonly date: "date"; readonly dateTime: "dateTime"; readonly time: "time"; readonly string: "string"; readonly text: "text"; readonly url: "url"; readonly choice: "choice"; readonly openChoice: "open-choice"; readonly attachment: "attachment"; readonly reference: "reference"; readonly quantity: "quantity"; }; export declare type QuestionnaireItemType = (typeof QuestionnaireItemType)[keyof typeof QuestionnaireItemType]; export declare function QuestionnaireResponseDisplay(props: QuestionnaireResponseDisplayProps): JSX.Element; export declare interface QuestionnaireResponseDisplayProps { readonly questionnaireResponse: QuestionnaireResponse | Reference; } export declare function RangeDisplay(props: RangeDisplayProps): JSX.Element | null; export declare interface RangeDisplayProps { readonly value?: Range_2; readonly precision?: number; readonly exclusive?: boolean; } /** * Renders a Range input. * See: https://www.hl7.org/fhir/datatypes.html#Range * @param props - Range input properties. * @returns Range input element. */ export declare function RangeInput(props: RangeInputProps): JSX.Element; export declare interface RangeInputProps extends ComplexTypeInputProps { } /** * Renders a Ratio input. * See: https://www.hl7.org/fhir/datatypes.html#Ratio * @param props - Ratio input properties. * @returns Ratio input element. */ export declare function RatioInput(props: RatioInputProps): JSX.Element; export declare interface RatioInputProps extends ComplexTypeInputProps { } export declare const reactContext: Context; export declare function ReferenceDisplay(props: ReferenceDisplayProps): JSX.Element | null; export declare interface ReferenceDisplayProps { readonly value?: Reference; readonly link?: boolean; } export declare function ReferenceInput(props: ReferenceInputProps): JSX.Element; export declare interface ReferenceInputProps { readonly name: string; readonly placeholder?: string; readonly defaultValue?: Reference; readonly targetTypes?: string[]; readonly searchCriteria?: Record; readonly autoFocus?: boolean; readonly required?: boolean; readonly onChange?: (value: Reference | undefined) => void; readonly disabled?: boolean; /** Render the dropdowns inside the DOM tree (not a portal); defaults to portalled. */ readonly withinPortal?: boolean; } export declare function ReferenceRangeEditor(props: ReferenceRangeEditorProps): JSX.Element; export declare interface ReferenceRangeEditorProps { readonly definition: ObservationDefinition; readonly onSubmit: (result: ObservationDefinition) => void; } export declare function ReferenceRangeGroupEditor(props: ReferenceRangeGroupEditorProps): JSX.Element; /** * Helper component that renders an "interval group", which is a set of ObservationDefinitionQualifiedIntervals * that have the same filter values */ export declare interface ReferenceRangeGroupEditorProps { readonly intervalGroup: IntervalGroup; readonly unit: string | undefined; readonly onChange: (groupId: string, changed: ObservationDefinitionQualifiedInterval) => void; readonly onAdd: (groupId: string, added: ObservationDefinitionQualifiedInterval) => void; readonly onRemove: (groupId: string, removed: ObservationDefinitionQualifiedInterval) => void; readonly onRemoveGroup: (removedGroup: IntervalGroup) => void; } export declare function RegisterForm(props: RegisterFormProps): JSX.Element; export declare interface RegisterFormProps { readonly type: 'patient' | 'project'; readonly login?: string; readonly projectId?: string; readonly clientId?: string; readonly googleClientId?: string; readonly recaptchaSiteKey?: string; readonly children?: ReactNode; readonly onSuccess: () => void; readonly onSignIn?: () => void; } /** * Returns a copy of the questionnaire response with response items for disabled * questionnaire items removed. * * Per the FHIR R4 spec, a QuestionnaireResponse should not include answers for items * whose `enableWhen` evaluates to false or whose `questionnaire-hidden` extension is * true. The form preserves answers in local state so that re-enabling an item * restores its previous value, so callers must strip disabled items before * persisting or transmitting the response. * * @param questionnaire - The questionnaire defining the items. * @param response - The current questionnaire response. * @returns A new questionnaire response with disabled items removed. */ export declare function removeDisabledItems(questionnaire: Questionnaire, response: QuestionnaireResponse): QuestionnaireResponse; export { removePreferredPharmacyFromPatient } /** * Returns a fragment to be displayed in the search table for the value. * @param resource - The parent resource. * @param field - The search code or FHIRPath expression. * @returns The fragment to display. */ export declare function renderValue(resource: Resource, field: SearchControlField): string | JSX.Element | null | undefined; export declare function RequestGroupDisplay(props: RequestGroupDisplayProps): JSX.Element | null; export declare interface RequestGroupDisplayProps { readonly value?: RequestGroup | Reference; readonly onStart: (task: Task, input: Reference) => void; readonly onEdit: (task: Task, input: Reference, output: Reference) => void; } export declare function ResetPasswordForm(props: ResetPasswordFormProps): JSX.Element; export declare interface ResetPasswordFormProps { readonly projectId?: string; readonly recaptchaSiteKey?: string; readonly onSuccess?: () => void; readonly onSignIn?: () => void; readonly onRegister?: () => void; } export declare function ResourceArrayDisplay(props: ResourceArrayDisplayProps): JSX.Element | null; export declare interface ResourceArrayDisplayProps { /** The path identifies the element and is expressed as a "."-separated list of ancestor elements, beginning with the name of the resource or extension. */ readonly path?: string; readonly property: InternalSchemaElement; readonly propertyType: string; readonly values: any[]; readonly ignoreMissingValues?: boolean; readonly link?: boolean; readonly includeDescriptionListEntry?: boolean; } export declare function ResourceArrayInput(props: ResourceArrayInputProps): JSX.Element | null; export declare interface ResourceArrayInputProps extends BaseInputProps { readonly property: ExtendedInternalSchemaElement; readonly name: string; readonly defaultValue?: any[]; readonly indent?: boolean; readonly onChange?: (value: any[]) => void; readonly hideNonSliceValues?: boolean; } export declare function ResourceAvatar(props: ResourceAvatarProps): JSX.Element; export declare interface ResourceAvatarProps extends AvatarProps { readonly value?: Reference | Resource; readonly link?: boolean; } export declare function ResourceBadge(props: ResourceBadgeProps): JSX.Element; export declare interface ResourceBadgeProps { readonly value?: Reference | Resource; readonly link?: boolean; } export declare function ResourceBlame(props: ResourceBlameProps): JSX.Element | null; export declare interface ResourceBlameProps { readonly history?: Bundle; readonly resourceType?: ResourceType; readonly id?: string; } /** * ResourceBoard is a generic master-detail board: it owns data fetching (list search, * selection resolution, background refresh via useResourceBoard) and renders the * presentational shell with ListWithDetailPane. Escape hatches allow custom loading * and selection resolution. * @param props - The ResourceBoard React props. * @returns The ResourceBoard React node. */ export declare function ResourceBoard(props: ResourceBoardProps): JSX.Element; export declare type ResourceBoardDetailContext = ListWithDetailPaneDetailContext; export declare type ResourceBoardItemContext = ListWithDetailPaneItemContext>; export declare interface ResourceBoardLoadResult { readonly items: WithId[]; readonly total?: number; } /** * Props for the ResourceBoard component. * @param search - The search definition (resourceType + filters + count/offset), like SearchControl. Default * fetching searches with `_total=accurate` and `cache: 'no-cache'`. Deep-equality memoized internally, so parents * may pass object literals. * @param selectedId - Selected resource id, typically driven by the URL route param. * @param loadItems - Custom fetcher replacing the default search (e.g. GraphQL batching, client-side filtering). * Re-runs whenever its identity or the search changes — wrap in useCallback. * @param resolveSelected - Selected-resource resolution. Default: find in items by id, else * `medplum.readResource(search.resourceType, id)`. * @param reloadKey - Manual refresh trigger: change this value (e.g. a counter) to re-run the load without changing * the search. Reloads in place — no skeleton. * @param headerText - Plain title shown at the left of the header when no `tabs` are provided. * @param tabs - Sidebar header tabs. Selecting a tab navigates to its URI. * @param activeTab - Controlled active tab value; consumers derive it from the URL. * @param headerActions - Right-aligned slot in the sidebar header row: action buttons, filter popovers. * @param renderItem - Renders one row of the list sidebar. * @param emptyList - Shown when the list loads empty. Default: dimmed "No items found". * @param skeleton - Shown while the initial or search-change load is in flight. Default: built-in skeleton rows. * @param listWidth - Sidebar width in pixels. Default 350. * @param renderDetail - Renders the detail pane for the resolved selection. * @param emptyDetail - Shown when nothing is selected or the selection cannot be resolved. * @param listFooter - Pinned below the list and above the pagination row, e.g. bulk actions for the current list. * @param onChange - Fired by the built-in pagination with the updated offset. * @param onSelectFirst - Auto-select escape hatch. Fired with the first item when a load for the current search * settles with items while nothing is selected (owned by ListWithDetailPane). The consumer decides how to navigate * (e.g. with history replace). * @param onLoad - Fired after every successful load. * @param onError - List-load and selection-resolution errors. Default: console.error. */ export declare interface ResourceBoardProps { readonly search: SearchRequest; readonly selectedId?: string; readonly loadItems?: (search: SearchRequest, medplum: MedplumClient) => Promise>; readonly resolveSelected?: (id: string, items: WithId[], medplum: MedplumClient) => Promise | undefined>; readonly reloadKey?: unknown; readonly headerText?: ReactNode; readonly tabs?: ResourceBoardTab[]; readonly activeTab?: string; readonly headerActions?: ReactNode; readonly renderItem: (item: WithId, ctx: ResourceBoardItemContext) => ReactNode; readonly emptyList?: ReactNode; readonly skeleton?: ReactNode; readonly listWidth?: number; readonly renderDetail: (selected: WithId, ctx: ResourceBoardDetailContext) => ReactNode; readonly emptyDetail?: ReactNode; readonly listFooter?: ReactNode; readonly onChange?: (search: SearchRequest) => void; readonly onSelectFirst?: (item: WithId) => void; readonly onLoad?: (items: WithId[], total: number | undefined) => void; readonly onError?: (error: unknown) => void; } export declare type ResourceBoardTab = ListWithDetailPaneTab; export declare function ResourceDiff(props: ResourceDiffProps): JSX.Element; export declare interface ResourceDiffProps { readonly original: Resource; readonly revised: Resource; readonly ignoreMeta?: boolean; } export declare function ResourceDiffTable(props: ResourceDiffTableProps): JSX.Element | null; export declare interface ResourceDiffTableProps { readonly original: Resource; readonly revised: Resource; } export declare function ResourceForm(props: ResourceFormProps): JSX.Element; export declare interface ResourceFormProps { readonly defaultValue: Partial | Reference; readonly outcome?: OperationOutcome; readonly onSubmit: (resource: Resource) => void; readonly onPatch?: (resource: Resource) => void; readonly onDelete?: (resource: Resource) => void; /** (optional) URL of the resource profile used to display the form. Takes priority over schemaName. */ readonly profileUrl?: string; /** (optional) `id` for the form element, so a submit button rendered outside the form can target it via `form={formId}`. */ readonly formId?: string; /** (optional) Hide the built-in submit row; pair with `formId` to supply your own submit control. */ readonly hideSubmitButton?: boolean; } export declare function ResourceHistoryTable(props: ResourceHistoryTableProps): JSX.Element; export declare interface ResourceHistoryTableProps { readonly history?: Bundle; readonly resourceType?: string; readonly id?: string; } /** * @param props - The props for the ResourceInput component. * @returns The ResourceInput component. */ export declare function ResourceInput(props: ResourceInputProps): JSX.Element | null; export declare interface ResourceInputProps { readonly resourceType: T['resourceType']; readonly name: string; readonly defaultValue?: T | Reference; readonly searchCriteria?: Record; /** The search parameter, with any modifier, that the typed text is sent as (e.g. `name:contains`). Defaults to one chosen by resource type. */ readonly searchParam?: string; readonly placeholder?: string; readonly required?: boolean; readonly itemComponent?: (props: AsyncAutocompleteOption) => JSX.Element | ReactNode; readonly onChange?: (value: T | undefined) => void; readonly disabled?: boolean; readonly label?: AsyncAutocompleteProps['label']; /** * Names the field for assistive technology, for use instead of a visible `label` (don't pass both). The name * goes on the search box and on a group around the whole field, which keeps the chosen resource named while the * search box is hidden (disabled or once a resource is chosen). */ readonly 'aria-label'?: AsyncAutocompleteProps['aria-label']; readonly error?: AsyncAutocompleteProps['error']; /** Render the options dropdown inside the DOM tree (not a portal); defaults to portalled. */ readonly withinPortal?: boolean; /** Whether to show a button that clears the whole selection. Defaults to true. */ readonly clearable?: boolean; } export declare function ResourceName(props: ResourceNameProps): JSX.Element | null; export declare interface ResourceNameProps extends TextProps { readonly value?: Reference | Resource; readonly link?: boolean; } /** * Low-level component that renders a property from a given resource, given type information. * @param props - The ResourcePropertyDisplay React props. * @returns The ResourcePropertyDisplay React node. */ export declare function ResourcePropertyDisplay(props: ResourcePropertyDisplayProps): JSX.Element | null; export declare interface ResourcePropertyDisplayProps { readonly property?: InternalSchemaElement; /** The path identifies the element and is expressed as a "."-separated list of ancestor elements, beginning with the name of the resource or extension. */ readonly path?: string; readonly propertyType: string; readonly value: any; readonly arrayElement?: boolean; readonly maxWidth?: number; readonly ignoreMissingValues?: boolean; readonly link?: boolean; /** (Optional) The `ElemendDefinitionType` to display the property against. Used when displaying extensions. */ readonly elementDefinitionType?: ElementDefinitionType; /** (Optional) If true and `property` is an array, output is wrapped with a DescriptionListEntry */ readonly includeArrayDescriptionListEntry?: boolean; } export declare function ResourcePropertyInput(props: ResourcePropertyInputProps): JSX.Element; export declare interface ResourcePropertyInputProps extends BaseInputProps { readonly property: ExtendedInternalSchemaElement; readonly name: string; readonly defaultPropertyType?: string; readonly defaultValue: any; readonly arrayElement?: boolean; readonly onChange?: (value: any, propName?: string) => void; } export declare function ResourceTable(props: ResourceTableProps): JSX.Element | null; export declare interface ResourceTableProps { /** * The input value either as a resource or a reference. */ readonly value: Resource | Reference; /** * Optional flag to ignore missing values. * By default, missing values are displayed as empty strings. */ readonly ignoreMissingValues?: boolean; /** * Optional flag to force use the input value. * This is useful when you want to display a specific version of the resource, * and not use the latest version. */ readonly forceUseInput?: boolean; /** (optional) URL of the resource profile used to display the form. */ readonly profileUrl?: string; } export declare function ResourceTimeline(props: ResourceTimelineProps): JSX.Element; export declare interface ResourceTimelineMenuItemContext { readonly primaryResource: Resource; readonly currentResource: Resource; readonly reloadTimeline: () => void; } export declare interface ResourceTimelineProps { readonly value: T | Reference; readonly loadTimelineResources: (medplum: MedplumClient, resourceType: ResourceType, id: string) => Promise[]>; readonly createCommunication?: (resource: T, sender: ProfileResource, text: string) => Communication; readonly createMedia?: (resource: T, operator: ProfileResource, attachment: Attachment) => Media; readonly getMenu?: (context: ResourceTimelineMenuItemContext) => ReactNode; } declare function Scheduler_2(props: SchedulerProps): JSX.Element | null; export { Scheduler_2 as Scheduler } export declare interface SchedulerProps { readonly schedule?: Schedule | Reference | Schedule[] | Reference[]; fetchSlots?: SlotSearchFunction; onSelectSlot?: (slot: Slot) => void; children?: React.ReactNode; } export declare type SchedulingOption = [T, Date]; /** * Component that scrolls the window to the top when the route changes. * This is useful for maintaining a good user experience when navigating between pages. * @returns Empty JSX fragment as this is a utility component with no visual representation */ export declare function ScrollToTop(): null; export declare class SearchChangeEvent extends Event { readonly definition: SearchRequest; constructor(definition: SearchRequest); } export declare class SearchClickEvent extends Event { readonly resource: Resource; readonly browserEvent: MouseEvent_2; constructor(resource: Resource, browserEvent: MouseEvent_2); } /** * Embeddable FHIR search table with a toolbar (column, filter and sort popovers, result count, * actions menu, New button), sortable/filterable column headers, optional row checkboxes and * pagination. Controlled: every change is emitted through `onChange` for the caller to apply. * @param props - The SearchControl React props. * @returns The SearchControl React node. */ export declare function SearchControl(props: SearchControlProps): JSX.Element; /** * An additional, computed column appended after the search-result columns. It is not backed by a * search parameter, so it has no sort/filter menu and renders arbitrary content per row. */ export declare interface SearchControlAdditionalColumn { /** The column header text. */ readonly name: string; /** Renders the cell contents for the given row resource. */ readonly renderCell: (resource: Resource) => ReactNode; } /** * The SearchControlField type describes a field in the search control. * * In a SearchRequest, a field is a simple string. Strings can be one of the following: * 1) Simple property names, which refer to InternalSchemaElement objects * 2) Search parameter names, which refer to SearchParameter resources * * Consider a few examples of how this becomes complicated. * * "name" (easy) * - element definition path="Patient.name" * - search parameter code="name" * * "birthDate" (medium) * - refers to the element definition path="Patient.birthDate" * - refers to the search parameter code="birthdate" (note the capitalization) * * "email" (hard) * - refers to the search parameter code="email" * - refers to the element definition path="Patient.telecom" * * In the last case, we start with the search parameter, and walk backwards to the * element definition in order to get type details for rendering. * * Overall, we want columns, fields, properties, and search parameters to feel seamless, * so we try our darndest to make this work. */ export declare interface SearchControlField { readonly name: string; readonly elementDefinition?: InternalSchemaElement; readonly searchParams?: SearchParameter[]; } export declare interface SearchControlProps { readonly search: SearchRequest; readonly checkboxesEnabled?: boolean; /** Additional computed columns rendered after the search-result columns. */ readonly additionalColumns?: readonly SearchControlAdditionalColumn[]; readonly hideToolbar?: boolean; /** Hides the per-column filter description row under the column headers. */ readonly hideFilters?: boolean; readonly onLoad?: (e: SearchLoadEvent) => void; readonly onChange?: (e: SearchChangeEvent) => void; readonly onClick?: (e: SearchClickEvent) => void; readonly onAuxClick?: (e: SearchClickEvent) => void; readonly onNew?: () => void; readonly onExport?: () => void; readonly onExportCsv?: () => void; readonly onExportTransactionBundle?: () => void; /** * Deletes the checked rows after confirmation. A returned Promise keeps the modal open with a * loading button until it settles; a rejection leaves the modal open for the caller to report. */ readonly onDelete?: (ids: string[]) => void | Promise; readonly onBulk?: (ids: string[]) => void; } export declare function SearchFieldEditor(props: SearchFieldEditorProps): JSX.Element | null; export declare interface SearchFieldEditorProps { readonly visible: boolean; readonly search: SearchRequest; readonly onOk: (search: SearchRequest) => void; readonly onCancel: () => void; } export declare function SearchFilterEditor(props: SearchFilterEditorProps): JSX.Element | null; export declare interface SearchFilterEditorProps { readonly visible: boolean; readonly search: SearchRequest; readonly onOk: (search: SearchRequest) => void; readonly onCancel: () => void; } export declare class SearchLoadEvent extends Event { readonly response: Bundle; constructor(response: Bundle); } export declare type SearchOptions = { debounceMs?: number; enabled?: boolean; }; /** Context passed to every section's component. */ export declare interface SectionRenderContext { readonly patient: Patient; readonly onClickResource?: (resource: Resource) => void; readonly onEditPatient?: () => void; /** Named results for each search in the section's `searches` array, keyed by `FhirSearchDescriptor.key`. */ readonly results: SectionResults; } /** Named map of FHIR results for a section: `results[searchKey]` returns the Resource[] for that search. */ export declare type SectionResults = Record; /** * Sends a structured command to the iframe using postMessage. * * Normally postMessage implies global event listeners. This method uses * MessageChannel to create a message channel between the iframe and the parent. * @param frame - The receiving IFrame. * @param command - The command to send. * @returns Promise to the response from the IFrame. * @see https://advancedweb.hu/how-to-use-async-await-with-postmessage/ */ export declare function sendCommand(frame: HTMLIFrameElement, command: Command): Promise; export declare function ServiceRequestTimeline(props: ServiceRequestTimelineProps): JSX.Element; export declare interface ServiceRequestTimelineProps extends Pick, 'getMenu'> { readonly serviceRequest: ServiceRequest | Reference; } /** * Sets the array of filters. * @param definition - The original search request. * @param filters - The new filters. * @returns The updated search request. */ export declare function setFilters(definition: SearchRequest, filters: Filter[]): SearchRequest; /** * Sets the offset (starting at zero). * @param definition - The original search request. * @param offset - The offset number. * @returns The updated search request. */ export declare function setOffset(definition: SearchRequest, offset: number): SearchRequest; /** * Creates a new search request with the search offset at the specified page. * @param definition - The search definition. * @param page - The new page number * @returns The new search definition. */ export declare function setPage(definition: SearchRequest, page: number): SearchRequest; export declare function SetPasswordForm(props: SetPasswordFormProps): JSX.Element; export declare interface SetPasswordFormProps { readonly id: string; readonly secret: string; readonly onSuccess?: () => void; readonly onSignIn?: () => void; } export declare function setPropertyValue(obj: any, key: string, propName: string, elementDefinition: InternalSchemaElement, value: any): any; export declare function setQuestionnaireItemReferenceTargetTypes(item: QuestionnaireItem, targetTypes: ResourceType[] | undefined): QuestionnaireItem; /** * Sorts the search by the specified key, and optional direction. * Direction defaults to ascending ('asc') if not specified. * @param definition - The original search request. * @param sort - The sort key. * @param desc - Optional descending flag. Default is false. * @returns The updated search request. */ export declare function setSort(definition: SearchRequest, sort: string, desc?: boolean): SearchRequest; /** Sexual Orientation section — searches for Observation resources by LOINC 76690-7. */ export declare const SexualOrientationSection: PatientSummarySectionConfig; export declare function SignatureInput(props: SignatureInputProps): JSX.Element; export declare interface SignatureInputProps extends PaperProps { readonly width?: number; readonly height?: number; readonly defaultValue?: Signature; readonly who?: Reference; readonly onChange: ((value: Signature | undefined) => void) | undefined; } /** * The SignInForm component allows users to sign in to Medplum. * * "Signing in" is a multi-step process: * 1) Authentication - identify the user * 2) MFA - If MFA is enabled, prompt for MFA code * 3) Choose profile - If the user has multiple profiles, prompt to choose one * 4) Choose scope - If the user has multiple scopes, prompt to choose one * 5) Success - Return to the caller with either a code or a redirect * @param props - The SignInForm React props. * @returns The SignInForm React node. */ export declare function SignInForm(props: SignInFormProps): JSX.Element; export declare interface SignInFormProps extends BaseLoginRequest { readonly login?: string; readonly chooseScopes?: boolean; readonly disableEmailAuth?: boolean; readonly disableGoogleAuth?: boolean; readonly onSuccess?: () => void; readonly onForgotPassword?: () => void; readonly onRegister?: () => void; readonly onCode?: (code: string) => void; readonly children?: ReactNode; readonly chooseScopeFormProps?: Omit; } /** * Custom function to search for available slots within a given time period * @param period - The time period to search within * @returns Promise resolving to an array of available slots */ export declare type SlotSearchFunction = (period: Period) => Promise; export declare function SmartAppLaunchLink(props: Readonly): JSX.Element | null; export declare interface SmartAppLaunchLinkProps extends AnchorProps { readonly client: ClientApplication; readonly patient?: Reference; readonly encounter?: Reference; readonly fhirContext?: Reference[]; readonly children?: ReactNode; } export declare interface SmartSearchResponse { readonly data: { ResourceList: Resource[]; }; } /** Smoking Status section — searches for Observation resources by LOINC 72166-2. */ export declare const SmokingStatusSection: PatientSummarySectionConfig; /** * Sorts an array of resources in place by meta.lastUpdated ascending. * @param resources - Array of resources. * @param timelineResource - Optional primary resource of a timeline view. If specified, the primary resource will be sorted by meta.lastUpdated descending. */ export declare function sortByDateAndPriority(resources: Resource[], timelineResource?: Resource): void; export declare function Spotlight({ patientsOnly, staticActions }: SpotlightProps): JSX.Element; /** * A Spotlight entry. Setting `href` renders it as an anchor rather than a button, so the browser's * "Open link in new tab" context menu and Cmd/Ctrl+click both work. A plain click is handed to the * SPA router instead of triggering a full page load; pass `onClick` to do something other than * navigate to `href`. */ export declare interface SpotlightLinkAction extends SpotlightActionData { readonly href?: string; } export declare interface SpotlightProps { readonly patientsOnly?: boolean; readonly staticActions?: SpotlightLinkAction[]; } export declare function StatusBadge(props: StatusBadgeProps): JSX.Element; export declare interface StatusBadgeProps extends Omit { readonly status: string; } export declare function SubmitButton(props: ButtonProps): JSX.Element; export declare type SubmitButtonProps = Omit; export declare interface SummaryResourceListOptions { /** Unique key for React reconciliation. */ readonly key: string; /** Section title displayed in the collapsible header. */ readonly title: string; /** FHIR search configuration. */ readonly search: { readonly resourceType: ResourceType; /** Which search param references the patient. Defaults to 'subject'. */ readonly patientParam?: string; /** Additional search params. */ readonly query?: Record; }; /** Override the default display string for each resource. */ readonly getDisplayString?: (resource: Resource) => string; /** Return a status badge config, or undefined to show no badge. */ readonly getStatus?: (resource: Resource) => { label: string; color: string; } | undefined; /** Return secondary text (shown dimmed below the primary text). */ readonly getSecondaryText?: (resource: Resource) => string | undefined; /** Filter resources before display. */ readonly filter?: (resource: Resource) => boolean; /** Sort resources before display. */ readonly sort?: (a: Resource, b: Resource) => number; /** Callback for the "+" add button. If omitted, no add button is shown. */ readonly onAdd?: () => void; } /** * Creates a `PatientSummarySectionConfig` that renders a list of resources * using the same visual pattern as built-in sections (CollapsibleSection + SummaryItem + StatusBadge). * @param options - Configuration for the resource list section. * @returns A section config that renders a generic resource list. */ export declare function summaryResourceListSection(options: SummaryResourceListOptions): PatientSummarySectionConfig; export declare type SupportedProfileStructureDefinition = StructureDefinition & { url: NonNullable; name: NonNullable; }; export declare interface TabDefinition { readonly label: string; readonly value: string; } export declare function ThreadChat(props: ThreadChatProps): JSX.Element | null; export declare interface ThreadChatProps { readonly thread: Communication; readonly title?: string; readonly onMessageSent?: (message: Communication) => void; readonly inputDisabled?: boolean; readonly excludeHeader?: boolean; readonly uploadEnabled?: boolean; readonly onError?: (err: Error) => void; readonly onViewInDocuments?: (reference: Reference) => void; } export declare function ThreadInbox(props: ThreadInboxProps): JSX.Element; /** * ThreadInbox is a component that displays a list of threads and allows the user to select a thread to view. * @param query - The query to fetch all communications. * @param threadId - The id of the thread to select. * @param subject - The default subject when creating a new thread. * @param showPatientSummary - Whether to show the patient summary. * @param sections - Optional sections configuration for the patient summary. * @param patientHeaderLink - Where the patient summary header navigates when clicked. Omit for a static header. * @param onNew - A function to handle a new thread. * @param onSelectFirst - Fired with the first thread when the list loads with nothing selected; use it to navigate to that thread (with replace) so the inbox auto-selects it. * @param getThreadUri - A function to build thread URIs. * @param onChange - A function to handle search changes. * @param inProgressUri - The URI for in-progress threads. * @param completedUri - The URI for completed threads. * @param newTopicOpened - Controlled open state for the new topic dialog. When provided, use `onNewTopicOpen` and `onNewTopicClose` to update it. * @param onNewTopicOpen - Called when the user clicks the new message button. Required when `newTopicOpened` is provided. * @param onNewTopicClose - Called when the new topic dialog is closed. Required when `newTopicOpened` is provided. */ export declare interface ThreadInboxProps { readonly query: string; readonly threadId: string | undefined; readonly subject?: Reference | Patient; readonly showPatientSummary?: boolean; readonly sections?: PatientSummarySectionConfig[]; readonly patientHeaderMenuItems?: ReactNode; readonly patientHeaderLink?: Resource | Reference | string; readonly onEditPatient?: () => void; readonly onPatientChange?: (patient: Reference | undefined) => void; readonly onNew: (message: Communication) => void; readonly onSelectFirst?: (thread: Communication) => void; readonly getThreadUri: (topic: Communication) => string; readonly onChange: (search: SearchRequest) => void; readonly inProgressUri: string; readonly completedUri: string; readonly uploadEnabled?: boolean; readonly onViewInDocuments?: (reference: Reference) => void; readonly allowPatientSelection?: boolean; readonly newTopicOpened?: boolean; readonly onNewTopicOpen?: () => void; readonly onNewTopicClose?: () => void; } export declare function Timeline(props: TimelineProps): JSX.Element; export declare function TimelineItem(props: TimelineItemProps): JSX.Element; export declare interface TimelineItemProps extends PanelProps { readonly resource: T; readonly profile?: Reference; readonly dateTime?: string; readonly padding?: boolean; readonly popupMenuItems?: ReactNode; } /** * Loading placeholder that mirrors the TimelineItem layout: an avatar with name and date lines * in the header, followed by a title bar and full-width body rows. * @param props - The skeleton props. * @returns The TimelineItemSkeleton React node. */ export declare function TimelineItemSkeleton(props: TimelineItemSkeletonProps): JSX.Element; export declare interface TimelineItemSkeletonProps { readonly lines?: number; } export declare interface TimelineProps { readonly children?: ReactNode; } export declare function TimingInput(props: TimingInputProps): JSX.Element; export declare interface TimingInputProps extends ComplexTypeInputProps { readonly defaultModalOpen?: boolean; } /** * Toggles the sort of the search by key. * If the search is already sorted by the key, reverses the direction. * If the search is not sorted by the key, sort in ascending order. * @param definition - The original search request. * @param key - The field key name. * @returns The updated search request. */ export declare function toggleSort(definition: SearchRequest, key: string): SearchRequest; export declare type TranscriptItem = { text: string; timestamp: string; }; export declare function typedValueToResponseItem(item: QuestionnaireItem, value: TypedValue): QuestionnaireResponseItemAnswer | undefined; export declare function UnavailableNote({ text, severity, color, message }: UnavailableNoteProps): JSX.Element; export declare interface UnavailableNoteProps { readonly text: string; /** Defaults to `warning`. */ readonly severity?: UnavailableNoteSeverity; /** When set, overrides the color `severity` would pick. */ readonly color?: string; readonly message: string; } /** * How badly the missing dependency degrades the field: `warning` when the field is still usable * (e.g. it accepts free text and has only lost its suggestions), `error` when it is not. */ export declare type UnavailableNoteSeverity = 'warning' | 'error'; export declare const useCachedBinaryUrl: (binaryUrl: string | undefined) => string | undefined; /** * Vendor-neutral hook for the full **medication cart** lifecycle: add a draft * line (`createResource`), check out a set of drafts into the vendor's batch * approval queue (`$checkout-medications`), remove/clear cart lines * (`$remove-cart-medication` / `$clear-cart`), and read the vendor's own view of * the cart (`$get-cart`). * * Cart checkout / remove / clear hit project-scoped **FHIR custom operations** * whose backing Bot is chosen at deploy time via an `OperationDefinition` * carrying the `operationDefinition-implementation` extension — see * [bot operations docs](https://www.medplum.com/docs/bots/custom-fhir-operations). * The server's `tryCustomOperation` dispatch handles the OD → Bot lookup, so * projects swap vendors by deploying a different bot under the same code. * * `addToCart` is plain FHIR `createResource` (no `$add-cart` operation): the * Medplum-side cart is the set of draft `MedicationRequest`s. Vendor staging * (e.g. ScriptSure MedCart) happens at checkout. Vendors without a batch * approval queue (e.g. DoseSpot iframe-first) simply never call `checkout` / * `removeFromCart` / `clearCart`. * * Requests for the custom operations are encoded as `Parameters` bodies and * decoded by the matching `@medplum/core` helpers. Per-line outcomes arrive in * `response.items`. * * @returns Cart add / checkout / remove / clear / read callbacks plus `adding` state. */ export declare function useMedicationCart(): UseMedicationCartReturn; export declare interface UseMedicationCartReturn { /** * Persist a draft `MedicationRequest` as a cart line via plain FHIR * `createResource` (no custom operation). Vendor staging happens later at * {@link UseMedicationCartReturn.checkout}. */ addToCart: (medicationRequest: MedicationRequest) => Promise; /** True while one or more {@link UseMedicationCartReturn.addToCart} calls are in flight. */ adding: boolean; /** * Submit draft cart lines to the vendor's batch approval queue and return an * embeddable approval-widget URL. Refuses while {@link UseMedicationCartReturn.adding} is true. */ checkout: (input: MedicationCheckoutRequest) => Promise; /** Remove a single draft `MedicationRequest` from the patient's vendor cart. */ removeFromCart: (input: MedicationCartRemoveRequest) => Promise; /** Remove every item from the patient's vendor cart. */ clearCart: (input: MedicationCartClearRequest) => Promise; /** * Read the patient's cart as the **vendor** holds it, reconciled against the * local draft lines. Use this rather than counting drafts whenever the number * is shown to a prescriber: drafts alone are a lower bound. */ getCart: (input: MedicationCartContentsRequest) => Promise; } /** * Generic React hook that syncs a patient to a medication-order vendor and * returns the chart iframe URL. * * Executes the patient-sync bot first (if patientId is provided), then * the iframe bot to obtain the prescribing UI URL. * * Uses an effect cleanup flag so React 18 Strict Mode double-mount does not * trigger duplicate bot executions. * * @param syncBotIdentifier - Bot identifier for the patient sync bot. * @param iframeBotIdentifier - Bot identifier for the iframe URL bot. * @param options - Configuration and callback options. * @returns The medication-order iframe URL, or undefined while loading. */ export declare function useMedicationIFrame(syncBotIdentifier: Identifier, iframeBotIdentifier: Identifier, options: MedicationIFrameOptions): string | undefined; /** * Vendor-neutral hook for e-prescribing drug search and order-medication via * **FHIR custom operations** (no Bot identifiers required). * * Hits two project-scoped operations whose backing Bot is chosen at deploy time * via an `OperationDefinition` resource carrying the * `operationDefinition-implementation` extension — see * [bot operations docs](https://www.medplum.com/docs/bots/custom-fhir-operations). * The server's `tryCustomOperation` dispatch handles the OD → Bot lookup, so * projects can swap vendors (ScriptSure today, DoseSpot tomorrow) by deploying * a different bot under the same operation code. * * - `searchMedications`: `POST /fhir/R4/Medication/$drug-search` — expects the * bot to return a `Bundle` (single-Resource `return` shortcut on * the OperationDefinition). * - `orderMedication`: `POST /fhir/R4/MedicationRequest/$order-medication` — * expects the bot to return a `Parameters` envelope with named primitives; * `parametersToMedicationOrderResponse` decodes it. * * @returns Callbacks to search medications and submit an order request. */ export declare function useMedicationOrder(): UseMedicationOrderReturn; export declare interface UseMedicationOrderReturn { searchMedications: (params: MedicationSearchParams) => Promise; orderMedication: (input: MedicationOrderRequest) => Promise; } /** * Vendor-neutral React hook that calls the `$order-set-url` custom FHIR * operation and exposes the resulting iframe URL plus refresh/loading/error * state. * * Hits the project-scoped operation whose backing bot is chosen at deploy time * via an `OperationDefinition` resource carrying the * `operationDefinition-implementation` extension — see * [bot operations docs](https://www.medplum.com/docs/bots/custom-fhir-operations). * The server's `tryCustomOperation` dispatch handles the OD → Bot lookup, so * projects can swap vendors (ScriptSure today, DoseSpot tomorrow) by deploying * a different bot under the same operation code. * * - URL: `POST /fhir/R4/PlanDefinition/$order-set-url` * - Body: `Parameters` with `patientId` + (`planDefinitionId` XOR `vendorOrderSetId`) + optional `appId`. * - Returns: `Parameters` whose `launchUrl` is exposed as `url` on the hook. * * The hook is a "build a URL" hook (mirrors {@link useMedicationIFrame}); it * does not stamp Medplum resources or create vendor-side resources, so * `refresh` is safe to call repeatedly (the operation is naturally idempotent). * * Re-runs whenever the input options change. In-flight calls are cancelled on * input change and on unmount via a per-effect `cancelled` flag, so React 18 * Strict Mode double-mount does not surface stale URLs. * * @param options - Patient, picker (PD or vendor id), and optional appId. * @returns `{ url, loading, error, refresh }`. */ export declare function useMedicationOrderSet(options: UseMedicationOrderSetOptions): UseMedicationOrderSetReturn; export declare interface UseMedicationOrderSetOptions { /** Patient to prescribe against. Hook stays idle (no operation call) until set. */ readonly patientId: string | undefined; /** Medplum PlanDefinition id (vendor-neutral). Bot resolves it to the vendor's order set id. */ readonly planDefinitionId?: string; /** Vendor-side order set id, when picked directly (escape hatch when no synced PD exists yet). */ readonly vendorOrderSetId?: number | string; readonly appId?: string; /** Selected practice location for multi-practice deployments. */ readonly organization?: Reference; } export declare interface UseMedicationOrderSetReturn { /** Most recent successful URL from the order-set operation, or undefined while loading / on error. */ readonly url: string | undefined; /** True while a request is in flight. */ readonly loading: boolean; /** Last error from the operation call, or undefined. */ readonly error: unknown; /** * Force a re-fetch using the current options. Useful when wiring * `PrescriptionIFrameModal.onRefreshLaunchUrl` so the session token in * the returned widget URL is fresh on every modal open. */ readonly refresh: () => Promise; } /** * Returns the MedplumClient instance. * This is a shortcut for useMedplumContext().medplum. * @returns The MedplumClient instance. */ export declare function useMedplum(): MedplumClient; /** * Returns the MedplumContext instance. * @returns The MedplumContext instance. */ export declare function useMedplumContext(): MedplumContext; /** * Returns the Medplum navigate function. * @returns The Medplum navigate function. */ export declare function useMedplumNavigate(): MedplumNavigateFunction; /** * Returns the current Medplum user profile (if signed in). * This is a shortcut for useMedplumContext().profile. * @returns The current user profile. */ export declare function useMedplumProfile(): ProfileResource | undefined; /** * Returns a live notification count for a given resource type. * * Uses `medplum.search()` for the initial count (with default cache policy) and * subscribes to real-time updates via `useSubscription()`, re-fetching with * `cache: 'reload'` whenever a matching event arrives. * * @param options - The resource type, count search criteria, and subscription criteria. * @returns The current notification count. */ export declare function useNotificationCount(options: UseNotificationCountOptions): number; export declare interface UseNotificationCountOptions { readonly resourceType: ResourceType; readonly countCriteria: string; readonly subscriptionCriteria: string; } /** * Hook that collects all FHIR searches from section configs, deduplicates them, * executes them in parallel, and routes results back to each section. * Uses Promise.allSettled so a single failing search does not block all sections — * sections whose searches fail gracefully receive empty arrays. * @param patient - The patient or patient reference to fetch data for. * @param sections - The section configs defining which searches to execute. * @returns Section data, loading state, any error, and a refresh callback. */ export declare function usePatientSummaryData(patient: Patient | Reference, sections: { readonly key: string; readonly searches?: FhirSearchDescriptor[]; }[]): PatientSummaryData; /** * Generic React hook that provides pharmacy search and add-to-favorites * functionality for any e-prescribing integration. * * Encapsulates calls to a search-pharmacy bot and an add-patient-pharmacy bot, * and can be composed with the generic `PharmacyDialog` component from `@medplum/react`. * * The search param type is generic so vendor hooks can widen it with their own * filters (e.g. ScriptSure `specialties`); the extra keys are passed through to * the bot as-is at runtime. * * @param searchBotIdentifier - Bot identifier for the pharmacy search bot. * @param addPharmacyBotIdentifier - Bot identifier for the add-patient-pharmacy bot. * @returns An object with `searchPharmacies` and `addToFavorites` callbacks. */ export declare function usePharmacySearch(searchBotIdentifier: Identifier, addPharmacyBotIdentifier: Identifier): UsePharmacySearchReturn; export declare interface UsePharmacySearchReturn { searchPharmacies: (params: T) => Promise; addToFavorites: (params: AddFavoriteParams) => Promise; } /** * React Hook to keep track of the passed-in value from the previous render of the containing component. * @param value - The value to track. * @returns The value passed in from the previous render. */ export declare function usePrevious(value: T): T | undefined; export declare function useQuestionnaireForm(props: UseQuestionnaireFormProps): Readonly; export declare interface UseQuestionnaireFormProps { readonly questionnaire: Questionnaire | Reference; readonly defaultValue?: QuestionnaireResponse | Reference; readonly subject?: Reference; readonly encounter?: Reference; readonly source?: QuestionnaireResponse['source']; readonly disablePagination?: boolean; readonly onChange?: (response: QuestionnaireResponse) => void; } /** * React Hook to use a FHIR reference. * Handles the complexity of resolving references and caching resources. * @param value - The resource or reference to resource. * @param setOutcome - Optional callback to set the OperationOutcome. * @returns The resolved resource. */ export declare function useResource(value: Reference | Partial | undefined, setOutcome?: (outcome: OperationOutcome) => void): WithId | undefined; /** * useResourceBoard manages the data layer for the ResourceBoard component: * fetching the resource list, resolving the selected resource, and supporting * background refresh. * @param options - The data options, a subset of the ResourceBoard props. * @returns The loaded resources, total, loading state, resolved selection, and refresh helper. */ export declare function useResourceBoard(options: UseResourceBoardProps): UseResourceBoardResult; export declare interface UseResourceBoardProps { readonly search: SearchRequest; readonly selectedId?: string; readonly loadItems?: (search: SearchRequest, medplum: MedplumClient) => Promise>; readonly resolveSelected?: (id: string, items: WithId[], medplum: MedplumClient) => Promise | undefined>; /** * Manual refresh trigger: change this value (e.g. a counter) to re-run the load * without changing the search. Reloads in place — no skeleton — like `refresh()`. */ readonly reloadKey?: unknown; readonly onLoad?: (items: WithId[], total: number | undefined) => void; readonly onError?: (error: unknown) => void; } export declare interface UseResourceBoardResult { readonly items: WithId[]; readonly total: number | undefined; readonly loading: boolean; readonly selected: WithId | undefined; /** * The search currently in effect. Tracks the input `search`, but only updates when it * changes by deep equality — so this identity is stable across renders and safe to use * in dependency arrays or to derive pagination from. */ readonly search: SearchRequest; readonly refresh: () => Promise; } /** * React hook for observing FHIR resource modifications made through the Medplum client. * * The callback is invoked whenever this client instance creates, updates, patches, or deletes * a resource of one of the given types, including modifications announced with * `MedplumClient.notifyResourceModified`. Use it to keep local component state in sync with * mutations made elsewhere in the application. Subscribing to a single resource type narrows * the event so `event.resource` is typed to that resource, no type guard required: * * ```tsx * useResourceModified('Slot', (event) => { * // event.resource is `WithId | undefined` * }); * useResourceModified(['Slot', 'Appointment'], () => refreshSchedule()); * ``` * * Modifications made by other clients (or other users) are not observed; * use `useSubscription` for server-side change notifications. * * @param resourceType - The resource type or types to observe. * @param callback - Invoked with the event payload for each matching modification. */ export declare function useResourceModified(resourceType: K | K[], callback: (event: ResourceModifiedEvent>) => void): void; /** * React hook for searching FHIR resources. * * This is a convenience hook for calling the MedplumClient.search() method. * * @param resourceType - The FHIR resource type to search. * @param query - Optional search parameters. * @param options - Optional options for configuring the search. * @returns A 3-element tuple containing the search result, loading flag, and operation outcome. */ export declare function useSearch(resourceType: K, query?: QueryTypes, options?: SearchOptions): [Bundle>> | undefined, boolean, OperationOutcome | undefined]; /** * React hook for searching for a single FHIR resource. * * This is a convenience hook for calling the MedplumClient.searchOne() method. * * @param resourceType - The FHIR resource type to search. * @param query - Optional search parameters. * @param options - Optional options for configuring the search. * @returns A 3-element tuple containing the search result, loading flag, and operation outcome. */ export declare function useSearchOne(resourceType: K, query?: QueryTypes, options?: SearchOptions): [WithId> | undefined, boolean, OperationOutcome | undefined]; /** * React hook for searching for an array of FHIR resources. * * This is a convenience hook for calling the MedplumClient.searchResources() method. * * @param resourceType - The FHIR resource type to search. * @param query - Optional search parameters. * @param options - Optional options for configuring the search. * @returns A 3-element tuple containing the search result, loading flag, and operation outcome. */ export declare function useSearchResources(resourceType: K, query?: QueryTypes, options?: SearchOptions): [ResourceArray>> | undefined, boolean, OperationOutcome | undefined]; /** * Returns a referentially stable wrapper around `callback` that always invokes the most recent * value passed in. This allows consumers to pass inline callbacks without invalidating effects * that depend on them. * * The returned function is always defined, even when `callback` is undefined; in that case it * is a no-op returning undefined. Do not use the result as a "was a handler provided?" signal. * * The returned function may not be current during rendering. Synchronous usage in renders * should invoke the original function instead of the stabilized wrapper. * * In React v19.2+, when the callback is only used in effects, this can be replaced with * `useEffectEvent`. This package supports embedding in applications using React 18.0, so that * technique can not be used in this library yet. * * @param callback - The callback to stabilize. May be undefined. * @returns A stable function that forwards to the latest `callback`. */ export declare function useStabilizedCallback(callback: ((...args: Args) => R) | undefined): (...args: Args) => R | undefined; /** * Creates an in-memory `Subscription` resource with the given criteria on the Medplum server and calls the given callback when an event notification is triggered by a resource interaction over a WebSocket connection. * * Subscriptions created with this hook are lightweight, share a single WebSocket connection, and are automatically untracked and cleaned up when the containing component is no longer mounted. * * @param criteria - The FHIR search criteria to subscribe to. * @param callback - The callback to call when a notification event `Bundle` for this `Subscription` is received. * @param options - Optional options used to configure the created `Subscription`. See {@link UseSubscriptionOptions} * * -------------------------------------------------------------------------------------------------------------------------------- * * `options` contains the following properties, all of which are optional: * - `subscriptionProps` - Allows the caller to pass a `Partial` to use as part of the creation * of the `Subscription` resource for this subscription. It enables the user namely to pass things like the `extension` property and to create * the `Subscription` with extensions such the {@link https://www.medplum.com/docs/subscriptions/subscription-extensions#interactions | Supported Interaction} extension which would enable to listen for `create` or `update` only events. * - `onWebsocketOpen` - Called when the WebSocket connection is established with Medplum server. * - `onWebsocketClose` - Called when the WebSocket connection disconnects. * - `onSubscriptionConnect` - Called when the corresponding subscription starts to receive updates after the subscription has been initialized and connected to. * - `onSubscriptionDisconnect` - Called when the corresponding subscription is destroyed and stops receiving updates from the server. * - `onError` - Called whenever an error occurs during the lifecycle of the managed subscription. */ export declare function useSubscription(criteria: string | undefined, callback: (bundle: Bundle) => void, options?: UseSubscriptionOptions): void; export declare type UseSubscriptionOptions = { subscriptionProps?: Partial; onWebSocketOpen?: () => void; onWebSocketClose?: () => void; onSubscriptionConnect?: (subscriptionId: string) => void; onSubscriptionDisconnect?: (subscriptionId: string) => void; onError?: (err: Error) => void; }; /** * Vendor-neutral React hook that syncs a Medplum `PlanDefinition` (type=order-set) * to the configured e-prescribing vendor via the `$sync-orderset` custom FHIR operation * (`POST /fhir/R4/PlanDefinition/$sync-orderset`). * * Resolves with the decoded `OrderSetSyncResponse` so callers can surface * per-action failures (`results[i].status === 'failed'` / `failedCount > 0`) — * without this, an order set that only partially synced would silently apply * with fewer meds than the PlanDefinition requested. * * Resolves with `undefined` when the operation is not deployed (i.e. no * e-prescribing vendor is configured for the project), so callers do not need to * guard against missing integrations. * * @returns A stable `syncOrderSet(planDefinitionId, organization?)` callback. */ export declare function useSyncOrderSet(): (planDefinitionId: string, organization?: Reference) => Promise; export declare function useThreadInbox({ query, threadId }: UseThreadInboxOptions): UseThreadInboxReturn; export declare interface UseThreadInboxOptions { query: string; threadId: string | undefined; } export declare interface UseThreadInboxReturn { loading: boolean; error: Error | null; threadMessages: [Communication, Communication | undefined][]; selectedThread: Communication | undefined; total: number | undefined; addThreadMessage: (message: Communication) => void; handleThreadStatusChange: (newStatus: Communication['status']) => void; refreshThreadMessages: () => Promise; } /** * Probes a set of ValueSet URLs for availability, each with a filter-free, count-limited expansion. * * A "filter-free probe" means that without any user filters, if we get back a 400/404, it means the * value set itself is unavailable. We only mark a field as truly unavailable if we get back a 400/404; * transient failures (429/5xx/network) will be resolved as available so something like a network blip * will not disable a field and create bad UI behavior. * * Repeated probes of the same URL are deduplicated by the `MedplumClient` request cache, which caches * rejections too, so many fields bound to the same missing value set cost one request in the TTL window. * Recovery after a value set is imported happens on the first mount after that cache entry expires (60s in * the browser by default) — there is no live subscription. * * @param urls - The ValueSet URLs to probe. Falsy entries are ignored, and duplicates collapse to a * single probe. * @returns The availability verdict, with `loading` true until every requested URL has settled. */ export declare function useValueSetAvailabilities(urls: readonly (string | undefined)[]): ValueSetAvailability; /** * Probes a single ValueSet's availability once on mount. A thin wrapper around * {@link useValueSetAvailabilities} for the common single-value-set case. * @param url - The ValueSet URL, or undefined for unbound inputs (always available). * @returns undefined while the probe is in flight, true if available, false if unavailable. */ export declare function useValueSetAvailability(url: string | undefined): boolean | undefined; export declare function useWhisper({ language, model, onTranscript, idleTimeoutMs, }: UseWhisperOptions): UseWhisperResult; export declare type UseWhisperOptions = { language?: string; model?: string; onTranscript?: (text: string) => void; /** * How long to keep the WebSocket warm after stop() before fully closing it, in milliseconds. * Defaults to 120000 (2 minutes). Set to 0 or a non-finite value to keep the socket warm * until unmount (the previous behavior). */ idleTimeoutMs?: number; }; export declare type UseWhisperResult = { status: WhisperStatus; error: unknown; transcripts: TranscriptItem[]; start: () => Promise; stop: () => void; isListening: boolean; muted: boolean; setMuted: (value: boolean) => void; }; /** * A low-level component to autocomplete based on a FHIR Valueset. * This is the base component for CodeableConceptInput, CodingInput, and CodeInput. * @param props - The ValueSetAutocomplete React props. * @returns The ValueSetAutocomplete React node. */ export declare function ValueSetAutocomplete(props: ValueSetAutocompleteProps): JSX.Element; export declare interface ValueSetAutocompleteProps extends Omit, 'loadOptions' | 'toKey' | 'toOption'> { readonly binding: string | undefined; readonly creatable?: boolean; readonly clearable?: boolean; readonly expandParams?: Partial; readonly withHelpText?: boolean; } /** * The result of probing one or more ValueSet URLs for availability. */ export declare interface ValueSetAvailability { /** True while at least one requested URL is still being probed. */ readonly loading: boolean; /** The subset of requested URLs known to be available. */ readonly available: string[]; /** The subset of requested URLs known to be unavailable (a permanent 400/404). */ readonly unavailable: string[]; } export declare function valueSetElementToCoding(element: ValueSetExpansionContains): Coding; /** Vitals section — searches for Observation resources with category vital-signs. */ export declare const VitalsSection: PatientSummarySectionConfig; export declare type WhisperStatus = 'idle' | 'requesting_microphone' | 'connecting' | 'connected' | 'listening' | 'speech_started' | 'speech_stopped' | 'disconnected' | 'error'; export { }