@medplum/react 0.9.28 → 0.9.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/AddressDisplay.d.ts +6 -0
- package/dist/cjs/AddressInput.d.ts +8 -0
- package/dist/cjs/AnnotationInput.d.ts +8 -0
- package/dist/cjs/AttachmentArrayDisplay.d.ts +7 -0
- package/dist/cjs/AttachmentArrayInput.d.ts +9 -0
- package/dist/cjs/AttachmentDisplay.d.ts +7 -0
- package/dist/cjs/AttachmentInput.d.ts +9 -0
- package/dist/cjs/Autocomplete.d.ts +20 -0
- package/dist/cjs/Avatar.d.ts +12 -0
- package/dist/cjs/BackboneElementDisplay.d.ts +9 -0
- package/dist/cjs/BackboneElementInput.d.ts +9 -0
- package/dist/cjs/Button.d.ts +15 -0
- package/dist/cjs/CalendarInput.d.ts +16 -0
- package/dist/cjs/Checkbox.d.ts +12 -0
- package/dist/cjs/CheckboxFormSection.d.ts +9 -0
- package/dist/cjs/CodeInput.d.ts +9 -0
- package/dist/cjs/CodeableConceptDisplay.d.ts +6 -0
- package/dist/cjs/CodeableConceptInput.d.ts +9 -0
- package/dist/cjs/CodingDisplay.d.ts +6 -0
- package/dist/cjs/CodingInput.d.ts +9 -0
- package/dist/cjs/ContactDetailDisplay.d.ts +6 -0
- package/dist/cjs/ContactDetailInput.d.ts +8 -0
- package/dist/cjs/ContactPointDisplay.d.ts +6 -0
- package/dist/cjs/ContactPointInput.d.ts +8 -0
- package/dist/cjs/DateTimeInput.d.ts +23 -0
- package/dist/cjs/DefaultResourceTimeline.d.ts +6 -0
- package/dist/cjs/DescriptionList.d.ts +12 -0
- package/dist/cjs/DiagnosticReportDisplay.d.ts +12 -0
- package/dist/cjs/Dialog.d.ts +10 -0
- package/dist/cjs/Document.d.ts +7 -0
- package/dist/cjs/EncounterTimeline.d.ts +6 -0
- package/dist/cjs/ErrorBoundary.d.ts +18 -0
- package/dist/cjs/ExtensionInput.d.ts +8 -0
- package/dist/cjs/FhirPathDisplay.d.ts +9 -0
- package/dist/cjs/FhirPathTable.d.ts +29 -0
- package/dist/cjs/FooterLinks.d.ts +6 -0
- package/dist/cjs/Form.d.ts +8 -0
- package/dist/cjs/FormSection.d.ts +11 -0
- package/dist/cjs/FormUtils.d.ts +5 -0
- package/dist/cjs/GoogleButton.d.ts +8 -0
- package/dist/cjs/Header.d.ts +12 -0
- package/dist/cjs/HeaderSearchInput.d.ts +10 -0
- package/dist/cjs/HumanNameDisplay.d.ts +8 -0
- package/dist/cjs/HumanNameInput.d.ts +8 -0
- package/dist/cjs/IdentifierDisplay.d.ts +6 -0
- package/dist/cjs/IdentifierInput.d.ts +8 -0
- package/dist/cjs/Input.d.ts +22 -0
- package/dist/cjs/InputRow.d.ts +7 -0
- package/dist/cjs/Loading.d.ts +3 -0
- package/dist/cjs/Logo.d.ts +6 -0
- package/dist/cjs/MedplumLink.d.ts +13 -0
- package/dist/cjs/MedplumProvider.d.ts +34 -0
- package/dist/cjs/MenuItem.d.ts +9 -0
- package/dist/cjs/MenuSeparator.d.ts +3 -0
- package/dist/cjs/PatientTimeline.d.ts +6 -0
- package/dist/cjs/PeriodInput.d.ts +8 -0
- package/dist/cjs/PlanDefinitionBuilder.d.ts +7 -0
- package/dist/cjs/Popup.d.ts +14 -0
- package/dist/cjs/QuantityDisplay.d.ts +7 -0
- package/dist/cjs/QuantityInput.d.ts +8 -0
- package/dist/cjs/QuestionnaireBuilder.d.ts +8 -0
- package/dist/cjs/QuestionnaireForm.d.ts +14 -0
- package/dist/cjs/QuestionnaireUtils.d.ts +30 -0
- package/dist/cjs/RangeDisplay.d.ts +7 -0
- package/dist/cjs/RangeInput.d.ts +14 -0
- package/dist/cjs/RatioDisplay.d.ts +6 -0
- package/dist/cjs/RatioInput.d.ts +14 -0
- package/dist/cjs/ReferenceDisplay.d.ts +7 -0
- package/dist/cjs/ReferenceInput.d.ts +9 -0
- package/dist/cjs/RegisterForm.d.ts +18 -0
- package/dist/cjs/RequestGroupDisplay.d.ts +9 -0
- package/dist/cjs/ResourceArrayDisplay.d.ts +11 -0
- package/dist/cjs/ResourceArrayInput.d.ts +11 -0
- package/dist/cjs/ResourceBadge.d.ts +9 -0
- package/dist/cjs/ResourceBlame.d.ts +10 -0
- package/dist/cjs/ResourceDiff.d.ts +9 -0
- package/dist/cjs/ResourceDiffTable.d.ts +9 -0
- package/dist/cjs/ResourceForm.d.ts +10 -0
- package/dist/cjs/ResourceHistoryTable.d.ts +9 -0
- package/dist/cjs/ResourceInput.d.ts +12 -0
- package/dist/cjs/ResourceName.d.ts +7 -0
- package/dist/cjs/ResourcePropertyDisplay.d.ts +24 -0
- package/dist/cjs/ResourcePropertyInput.d.ts +21 -0
- package/dist/cjs/ResourceTable.d.ts +7 -0
- package/dist/cjs/ResourceTimeline.d.ts +11 -0
- package/dist/cjs/Scheduler.d.ts +7 -0
- package/dist/cjs/Scrollable.d.ts +9 -0
- package/dist/cjs/SearchControl.d.ts +40 -0
- package/dist/cjs/SearchControlField.d.ts +41 -0
- package/dist/cjs/SearchFieldEditor.d.ts +11 -0
- package/dist/cjs/SearchFilterEditor.d.ts +11 -0
- package/dist/cjs/SearchFilterValueDialog.d.ts +15 -0
- package/dist/cjs/SearchFilterValueDisplay.d.ts +7 -0
- package/dist/cjs/SearchFilterValueInput.d.ts +12 -0
- package/dist/cjs/SearchPopupMenu.d.ts +15 -0
- package/dist/cjs/SearchUtils.d.ts +174 -0
- package/dist/cjs/Select.d.ts +16 -0
- package/dist/cjs/ServiceRequestTimeline.d.ts +6 -0
- package/dist/cjs/SignInForm.d.ts +17 -0
- package/dist/cjs/StatusBadge.d.ts +6 -0
- package/dist/cjs/SubMenu.d.ts +7 -0
- package/dist/cjs/Tab.d.ts +12 -0
- package/dist/cjs/TabList.d.ts +10 -0
- package/dist/cjs/TabPanel.d.ts +6 -0
- package/dist/cjs/TabSwitch.d.ts +6 -0
- package/dist/cjs/TextArea.d.ts +18 -0
- package/dist/cjs/Timeline.d.ts +17 -0
- package/dist/cjs/TimingInput.d.ts +8 -0
- package/dist/cjs/TitleBar.d.ts +6 -0
- package/dist/cjs/UploadButton.d.ts +7 -0
- package/dist/cjs/constants.d.ts +1 -0
- package/dist/cjs/index.d.ts +86 -0
- package/dist/cjs/index.js +75 -41
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/index.min.js +1 -1
- package/dist/cjs/index.min.js.map +1 -1
- package/dist/cjs/stories/AddressInput.stories.d.ts +6 -0
- package/dist/cjs/stories/AttachmentArrayInput.stories.d.ts +6 -0
- package/dist/cjs/stories/AttachmentInput.stories.d.ts +6 -0
- package/dist/cjs/stories/Autocomplete.stories.d.ts +9 -0
- package/dist/cjs/stories/Avatar.stories.d.ts +10 -0
- package/dist/cjs/stories/Button.stories.d.ts +9 -0
- package/dist/cjs/stories/CodeableConceptDisplay.stories.d.ts +8 -0
- package/dist/cjs/stories/DiagnosticReportDisplay.stories.d.ts +5 -0
- package/dist/cjs/stories/Dialog.stories.d.ts +5 -0
- package/dist/cjs/stories/EncounterTimeline.stories.d.ts +5 -0
- package/dist/cjs/stories/FhirPathDisplay.stories.d.ts +7 -0
- package/dist/cjs/stories/FormSection.stories.d.ts +6 -0
- package/dist/cjs/stories/Header.stories.d.ts +8 -0
- package/dist/cjs/stories/Input.stories.d.ts +6 -0
- package/dist/cjs/stories/Loading.stories.d.ts +5 -0
- package/dist/cjs/stories/Logo.stories.d.ts +5 -0
- package/dist/cjs/stories/PatientTimeline.stories.d.ts +5 -0
- package/dist/cjs/stories/PlanDefinitionBuilder.stories.d.ts +5 -0
- package/dist/cjs/stories/QuestionnaireBuilder.stories.d.ts +7 -0
- package/dist/cjs/stories/QuestionnaireForm.stories.d.ts +11 -0
- package/dist/cjs/stories/ReferenceInput.stories.d.ts +6 -0
- package/dist/cjs/stories/RegisterForm.stories.d.ts +7 -0
- package/dist/cjs/stories/RequestGroupDisplay.stories.d.ts +5 -0
- package/dist/cjs/stories/ResourceBlame.stories.d.ts +5 -0
- package/dist/cjs/stories/ResourceForm.stories.d.ts +12 -0
- package/dist/cjs/stories/ResourceHistoryTable.stories.d.ts +5 -0
- package/dist/cjs/stories/ResourceTable.stories.d.ts +7 -0
- package/dist/cjs/stories/Scheduler.stories.d.ts +5 -0
- package/dist/cjs/stories/SearchControl.stories.d.ts +13 -0
- package/dist/cjs/stories/Select.stories.d.ts +6 -0
- package/dist/cjs/stories/SignInForm.stories.d.ts +8 -0
- package/dist/cjs/stories/StatusBadge.stories.d.ts +5 -0
- package/dist/cjs/stories/Tabs.stories.d.ts +6 -0
- package/dist/cjs/stories/Timeline.stories.d.ts +5 -0
- package/dist/cjs/stories/TimingInput.stories.d.ts +6 -0
- package/dist/cjs/stories/UploadButton.stories.d.ts +6 -0
- package/dist/cjs/styles.css +52 -51
- package/dist/cjs/test.setup.d.ts +1 -0
- package/dist/cjs/useResource.d.ts +8 -0
- package/dist/cjs/utils/blame.d.ts +8 -0
- package/dist/cjs/utils/date.d.ts +6 -0
- package/dist/cjs/utils/diff.d.ts +16 -0
- package/dist/cjs/utils/dom.d.ts +15 -0
- package/dist/cjs/utils/outcomes.d.ts +2 -0
- package/dist/cjs/utils/recaptcha.d.ts +12 -0
- package/dist/cjs/utils.d.ts +5 -0
- package/dist/esm/CalendarInput.d.ts +1 -0
- package/dist/esm/CalendarInput.js +6 -5
- package/dist/esm/CalendarInput.js.map +1 -1
- package/dist/esm/FhirPathTable.js +5 -2
- package/dist/esm/FhirPathTable.js.map +1 -1
- package/dist/esm/GoogleButton.js +1 -1
- package/dist/esm/GoogleButton.js.map +1 -1
- package/dist/esm/Header.js +7 -3
- package/dist/esm/Header.js.map +1 -1
- package/dist/esm/PlanDefinitionBuilder.js +1 -1
- package/dist/esm/PlanDefinitionBuilder.js.map +1 -1
- package/dist/esm/QuestionnaireBuilder.js +1 -1
- package/dist/esm/QuestionnaireBuilder.js.map +1 -1
- package/dist/esm/QuestionnaireForm.js +2 -1
- package/dist/esm/QuestionnaireForm.js.map +1 -1
- package/dist/esm/RegisterForm.js +2 -2
- package/dist/esm/RegisterForm.js.map +1 -1
- package/dist/esm/RequestGroupDisplay.js +1 -1
- package/dist/esm/RequestGroupDisplay.js.map +1 -1
- package/dist/esm/ResourceBlame.js +1 -1
- package/dist/esm/ResourceBlame.js.map +1 -1
- package/dist/esm/ResourceDiffTable.js +1 -1
- package/dist/esm/ResourceDiffTable.js.map +1 -1
- package/dist/esm/ResourceForm.js +1 -1
- package/dist/esm/ResourceForm.js.map +1 -1
- package/dist/esm/ResourceHistoryTable.js +4 -1
- package/dist/esm/ResourceHistoryTable.js.map +1 -1
- package/dist/esm/ResourceTable.js +1 -1
- package/dist/esm/ResourceTable.js.map +1 -1
- package/dist/esm/ResourceTimeline.js +13 -7
- package/dist/esm/ResourceTimeline.js.map +1 -1
- package/dist/esm/Scheduler.js +13 -6
- package/dist/esm/Scheduler.js.map +1 -1
- package/dist/esm/SearchControl.js +5 -2
- package/dist/esm/SearchControl.js.map +1 -1
- package/dist/esm/SignInForm.js +2 -1
- package/dist/esm/SignInForm.js.map +1 -1
- package/dist/esm/index.min.js +1 -1
- package/dist/esm/index.min.js.map +1 -1
- package/dist/esm/styles.css +52 -51
- package/dist/esm/utils/recaptcha.js +10 -4
- package/dist/esm/utils/recaptcha.js.map +1 -1
- package/package.json +6 -6
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Address } from '@medplum/fhirtypes';
|
|
3
|
+
export interface AddressInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: Address;
|
|
6
|
+
onChange?: (value: Address) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function AddressInput(props: AddressInputProps): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Annotation } from '@medplum/fhirtypes';
|
|
3
|
+
export interface AnnotationInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: Annotation;
|
|
6
|
+
onChange?: (value: Annotation) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function AnnotationInput(props: AnnotationInputProps): JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Attachment } from '@medplum/fhirtypes';
|
|
3
|
+
export interface AttachmentArrayDisplayProps {
|
|
4
|
+
values?: Attachment[];
|
|
5
|
+
maxWidth?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare function AttachmentArrayDisplay(props: AttachmentArrayDisplayProps): JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Attachment } from '@medplum/fhirtypes';
|
|
3
|
+
export interface AttachmentArrayInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: Attachment[];
|
|
6
|
+
arrayElement?: boolean;
|
|
7
|
+
onChange?: (value: Attachment[]) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare function AttachmentArrayInput(props: AttachmentArrayInputProps): JSX.Element;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Attachment } from '@medplum/fhirtypes';
|
|
3
|
+
export interface AttachmentDisplayProps {
|
|
4
|
+
value?: Attachment;
|
|
5
|
+
maxWidth?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare function AttachmentDisplay(props: AttachmentDisplayProps): JSX.Element | null;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Attachment } from '@medplum/fhirtypes';
|
|
3
|
+
export interface AttachmentInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: Attachment;
|
|
6
|
+
arrayElement?: boolean;
|
|
7
|
+
onChange?: (value: Attachment | undefined) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare function AttachmentInput(props: AttachmentInputProps): JSX.Element;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import './Autocomplete.css';
|
|
3
|
+
export interface AutocompleteProps<T> {
|
|
4
|
+
name: string;
|
|
5
|
+
multiple?: boolean;
|
|
6
|
+
autofocus?: boolean;
|
|
7
|
+
defaultValue?: T[];
|
|
8
|
+
className?: string;
|
|
9
|
+
placeholder?: string;
|
|
10
|
+
loadOnFocus?: boolean;
|
|
11
|
+
loadOptions: (input: string, signal: AbortSignal) => Promise<T[]>;
|
|
12
|
+
buildUnstructured?: (input: string) => T;
|
|
13
|
+
getId: (item: T) => string;
|
|
14
|
+
getIcon?: (item: T) => JSX.Element;
|
|
15
|
+
getDisplay: (item: T) => JSX.Element;
|
|
16
|
+
getHelpText?: (item: T) => string | undefined;
|
|
17
|
+
onChange?: (values: T[]) => void;
|
|
18
|
+
onCreateNew?: () => void;
|
|
19
|
+
}
|
|
20
|
+
export declare function Autocomplete<T>(props: AutocompleteProps<T>): JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Reference, Resource } from '@medplum/fhirtypes';
|
|
3
|
+
import './Avatar.css';
|
|
4
|
+
export interface AvatarProps {
|
|
5
|
+
size?: 'xsmall' | 'small' | 'medium' | 'large';
|
|
6
|
+
value?: Reference | Resource;
|
|
7
|
+
src?: string;
|
|
8
|
+
alt?: string;
|
|
9
|
+
color?: string;
|
|
10
|
+
link?: boolean;
|
|
11
|
+
}
|
|
12
|
+
export declare function Avatar(props: AvatarProps): JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { TypedValue } from '@medplum/core';
|
|
3
|
+
export interface BackboneElementDisplayProps {
|
|
4
|
+
value: TypedValue;
|
|
5
|
+
compact?: boolean;
|
|
6
|
+
ignoreMissingValues?: boolean;
|
|
7
|
+
link?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare function BackboneElementDisplay(props: BackboneElementDisplayProps): JSX.Element | null;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { OperationOutcome } from '@medplum/fhirtypes';
|
|
3
|
+
export interface BackboneElementInputProps {
|
|
4
|
+
typeName: string;
|
|
5
|
+
defaultValue?: any;
|
|
6
|
+
outcome?: OperationOutcome;
|
|
7
|
+
onChange?: (value: any) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare function BackboneElementInput(props: BackboneElementInputProps): JSX.Element;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './Button.css';
|
|
3
|
+
export interface ButtonProps {
|
|
4
|
+
type?: 'button' | 'submit';
|
|
5
|
+
style?: React.CSSProperties;
|
|
6
|
+
primary?: boolean;
|
|
7
|
+
danger?: boolean;
|
|
8
|
+
borderless?: boolean;
|
|
9
|
+
size?: 'small' | 'medium' | 'large';
|
|
10
|
+
onClick?: (e: React.MouseEvent) => void;
|
|
11
|
+
children: React.ReactNode;
|
|
12
|
+
label?: string;
|
|
13
|
+
testid?: string;
|
|
14
|
+
}
|
|
15
|
+
export declare function Button(props: ButtonProps): JSX.Element;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Slot } from '@medplum/fhirtypes';
|
|
3
|
+
import './CalendarInput.css';
|
|
4
|
+
export interface CalendarInputProps {
|
|
5
|
+
slots: Slot[];
|
|
6
|
+
onChangeMonth: (date: Date) => void;
|
|
7
|
+
onClick: (date: Date) => void;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Returns a month display string (e.g. "January 2020").
|
|
11
|
+
* @param date Any date within the month.
|
|
12
|
+
* @returns The month display string (e.g. "January 2020")
|
|
13
|
+
*/
|
|
14
|
+
export declare function getMonthString(date: Date): string;
|
|
15
|
+
export declare function CalendarInput(props: CalendarInputProps): JSX.Element;
|
|
16
|
+
export declare function getStartMonth(): Date;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
|
+
import './Checkbox.css';
|
|
3
|
+
export interface CheckboxProps {
|
|
4
|
+
name?: string;
|
|
5
|
+
defaultValue?: boolean | number;
|
|
6
|
+
required?: boolean;
|
|
7
|
+
inputRef?: RefObject<HTMLInputElement>;
|
|
8
|
+
testid?: string;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
onChange?: (newValue: boolean) => void;
|
|
11
|
+
}
|
|
12
|
+
export declare function Checkbox(props: CheckboxProps): JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './CheckboxFormSection.css';
|
|
3
|
+
export interface CheckboxFormSectionProps {
|
|
4
|
+
htmlFor?: string;
|
|
5
|
+
title?: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
}
|
|
9
|
+
export declare function CheckboxFormSection(props: CheckboxFormSectionProps): JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ElementDefinition } from '@medplum/fhirtypes';
|
|
3
|
+
export interface CodeInputProps {
|
|
4
|
+
property: ElementDefinition;
|
|
5
|
+
name: string;
|
|
6
|
+
defaultValue?: string;
|
|
7
|
+
onChange?: (value: string) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare function CodeInput(props: CodeInputProps): JSX.Element;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { CodeableConcept } from '@medplum/fhirtypes';
|
|
3
|
+
export interface CodeableConceptDisplayProps {
|
|
4
|
+
value?: CodeableConcept;
|
|
5
|
+
}
|
|
6
|
+
export declare function CodeableConceptDisplay(props: CodeableConceptDisplayProps): JSX.Element | null;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { CodeableConcept, ElementDefinition } from '@medplum/fhirtypes';
|
|
3
|
+
export interface CodeableConceptInputProps {
|
|
4
|
+
property: ElementDefinition;
|
|
5
|
+
name: string;
|
|
6
|
+
defaultValue?: CodeableConcept;
|
|
7
|
+
onChange?: (value: CodeableConcept) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare function CodeableConceptInput(props: CodeableConceptInputProps): JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Coding, ElementDefinition } from '@medplum/fhirtypes';
|
|
3
|
+
export interface CodingInputProps {
|
|
4
|
+
property: ElementDefinition;
|
|
5
|
+
name: string;
|
|
6
|
+
defaultValue?: Coding;
|
|
7
|
+
onChange?: (value: Coding) => void;
|
|
8
|
+
}
|
|
9
|
+
export declare function CodingInput(props: CodingInputProps): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ContactDetail } from '@medplum/fhirtypes';
|
|
3
|
+
export interface ContactDetailInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: ContactDetail;
|
|
6
|
+
onChange?: (value: ContactDetail) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function ContactDetailInput(props: ContactDetailInputProps): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { ContactPoint } from '@medplum/fhirtypes';
|
|
3
|
+
export interface ContactPointInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: ContactPoint;
|
|
6
|
+
onChange?: (value: ContactPoint | undefined) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function ContactPointInput(props: ContactPointInputProps): JSX.Element;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { InputProps } from './Input';
|
|
3
|
+
/**
|
|
4
|
+
* The DateTimeInput component is a wrapper around the HTML5 input type="datetime-local".
|
|
5
|
+
* The main purpose is to reconcile time zones.
|
|
6
|
+
* Most of our date/time values are in ISO-8601, which includes a time zone offset.
|
|
7
|
+
* The datetime-local input does not support the time zone offset.
|
|
8
|
+
* @param props The Input props.
|
|
9
|
+
* @returns The JSX element to render.
|
|
10
|
+
*/
|
|
11
|
+
export declare function DateTimeInput(props: InputProps): JSX.Element;
|
|
12
|
+
/**
|
|
13
|
+
* Converts an ISO-8601 date/time string to a local date/time string.
|
|
14
|
+
* @param isoString The ISO-8601 date/time string to convert.
|
|
15
|
+
* @returns The local date/time string.
|
|
16
|
+
*/
|
|
17
|
+
export declare function convertIsoToLocal(isoString: string | undefined): string;
|
|
18
|
+
/**
|
|
19
|
+
* Converts a local date/time string to an ISO-8601 date/time string.
|
|
20
|
+
* @param localString The local date/time string to convert.
|
|
21
|
+
* @returns The ISO-8601 date/time string.
|
|
22
|
+
*/
|
|
23
|
+
export declare function convertLocalToIso(localString: string | undefined): string;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Reference, Resource } from '@medplum/fhirtypes';
|
|
3
|
+
export interface DefaultResourceTimelineProps {
|
|
4
|
+
resource: Resource | Reference;
|
|
5
|
+
}
|
|
6
|
+
export declare function DefaultResourceTimeline(props: DefaultResourceTimelineProps): JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './DescriptionList.css';
|
|
3
|
+
export interface DescriptionListProps {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
compact?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export declare function DescriptionList(props: DescriptionListProps): JSX.Element;
|
|
8
|
+
export interface DescriptionListEntryProps {
|
|
9
|
+
term: string;
|
|
10
|
+
children: React.ReactNode;
|
|
11
|
+
}
|
|
12
|
+
export declare function DescriptionListEntry(props: DescriptionListEntryProps): JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { DiagnosticReport, Observation, Reference } from '@medplum/fhirtypes';
|
|
3
|
+
import './DiagnosticReportDisplay.css';
|
|
4
|
+
import './Table.css';
|
|
5
|
+
export interface DiagnosticReportDisplayProps {
|
|
6
|
+
value?: DiagnosticReport | Reference<DiagnosticReport>;
|
|
7
|
+
}
|
|
8
|
+
export declare function DiagnosticReportDisplay(props: DiagnosticReportDisplayProps): JSX.Element | null;
|
|
9
|
+
export interface ObservationTableProps {
|
|
10
|
+
value?: Observation[] | Reference<Observation>[];
|
|
11
|
+
}
|
|
12
|
+
export declare function ObservationTable(props: ObservationTableProps): JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './Dialog.css';
|
|
3
|
+
export interface DialogProps {
|
|
4
|
+
visible: boolean;
|
|
5
|
+
title: string;
|
|
6
|
+
children?: React.ReactNode;
|
|
7
|
+
onOk: () => void;
|
|
8
|
+
onCancel: () => void;
|
|
9
|
+
}
|
|
10
|
+
export declare function Dialog(props: DialogProps): JSX.Element | null;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Encounter, Reference } from '@medplum/fhirtypes';
|
|
3
|
+
export interface EncounterTimelineProps {
|
|
4
|
+
encounter: Encounter | Reference<Encounter>;
|
|
5
|
+
}
|
|
6
|
+
export declare function EncounterTimeline(props: EncounterTimelineProps): JSX.Element;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React, { ErrorInfo, ReactNode } from 'react';
|
|
2
|
+
export interface ErrorBoundaryProps {
|
|
3
|
+
children: ReactNode;
|
|
4
|
+
}
|
|
5
|
+
export interface ErrorBoundaryState {
|
|
6
|
+
error?: any;
|
|
7
|
+
}
|
|
8
|
+
/**
|
|
9
|
+
* ErrorBoundary is a React component that handles errors in its child components.
|
|
10
|
+
* See: https://reactjs.org/docs/error-boundaries.html
|
|
11
|
+
*/
|
|
12
|
+
export declare class ErrorBoundary extends React.Component<ErrorBoundaryProps, ErrorBoundaryState> {
|
|
13
|
+
state: ErrorBoundaryState;
|
|
14
|
+
constructor(props: ErrorBoundaryProps);
|
|
15
|
+
static getDerivedStateFromError(error: any): ErrorBoundaryState;
|
|
16
|
+
componentDidCatch(error: Error, errorInfo: ErrorInfo): void;
|
|
17
|
+
render(): ReactNode;
|
|
18
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Extension } from '@medplum/fhirtypes';
|
|
3
|
+
export interface ExtensionInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: Extension;
|
|
6
|
+
onChange?: (value: Extension) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function ExtensionInput(props: ExtensionInputProps): JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { PropertyType } from '@medplum/core';
|
|
3
|
+
import { Resource } from '@medplum/fhirtypes';
|
|
4
|
+
export interface FhirPathDisplayProps {
|
|
5
|
+
resource: Resource;
|
|
6
|
+
path: string;
|
|
7
|
+
propertyType: PropertyType;
|
|
8
|
+
}
|
|
9
|
+
export declare function FhirPathDisplay(props: FhirPathDisplayProps): JSX.Element | null;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { PropertyType } from '@medplum/core';
|
|
2
|
+
import { Resource } from '@medplum/fhirtypes';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import { SearchClickEvent } from './SearchControl';
|
|
5
|
+
import './SearchControl.css';
|
|
6
|
+
export interface SmartSearchField {
|
|
7
|
+
readonly propertyType: PropertyType;
|
|
8
|
+
readonly name: string;
|
|
9
|
+
readonly fhirPath: string;
|
|
10
|
+
}
|
|
11
|
+
export interface FhirPathTableProps {
|
|
12
|
+
resourceType: string;
|
|
13
|
+
query: string;
|
|
14
|
+
fields: SmartSearchField[];
|
|
15
|
+
checkboxesEnabled?: boolean;
|
|
16
|
+
onClick?: (e: SearchClickEvent) => void;
|
|
17
|
+
onAuxClick?: (e: SearchClickEvent) => void;
|
|
18
|
+
onBulk?: (ids: string[]) => void;
|
|
19
|
+
}
|
|
20
|
+
export interface SmartSearchResponse {
|
|
21
|
+
data: {
|
|
22
|
+
ResourceList: Resource[];
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* The FhirPathTable component represents the embeddable search table control.
|
|
27
|
+
*/
|
|
28
|
+
export declare function FhirPathTable(props: FhirPathTableProps): JSX.Element;
|
|
29
|
+
export declare const MemoizedFhirPathTable: React.MemoExoticComponent<typeof FhirPathTable>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React, { CSSProperties } from 'react';
|
|
2
|
+
export interface FormProps {
|
|
3
|
+
onSubmit?: (formData: Record<string, string>) => void;
|
|
4
|
+
style?: CSSProperties;
|
|
5
|
+
children?: React.ReactNode;
|
|
6
|
+
testid?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare function Form(props: FormProps): JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { OperationOutcome } from '@medplum/fhirtypes';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import './FormSection.css';
|
|
4
|
+
export interface FormSectionProps {
|
|
5
|
+
title?: string;
|
|
6
|
+
htmlFor?: string;
|
|
7
|
+
description?: string;
|
|
8
|
+
outcome?: OperationOutcome;
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
export declare function FormSection(props: FormSectionProps): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { GoogleCredentialResponse } from '@medplum/core';
|
|
3
|
+
export interface GoogleButtonProps {
|
|
4
|
+
readonly googleClientId?: string;
|
|
5
|
+
readonly handleGoogleCredential: (response: GoogleCredentialResponse) => void;
|
|
6
|
+
}
|
|
7
|
+
export declare function GoogleButton(props: GoogleButtonProps): JSX.Element | null;
|
|
8
|
+
export declare function getGoogleClientId(clientId: string | undefined): string | undefined;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { UserConfiguration } from '@medplum/fhirtypes';
|
|
3
|
+
import './Header.css';
|
|
4
|
+
export interface HeaderProps {
|
|
5
|
+
readonly title?: string;
|
|
6
|
+
readonly bgColor?: string;
|
|
7
|
+
readonly onLogo?: () => void;
|
|
8
|
+
readonly onProfile?: () => void;
|
|
9
|
+
readonly onSignOut?: () => void;
|
|
10
|
+
readonly config?: UserConfiguration;
|
|
11
|
+
}
|
|
12
|
+
export declare function Header(props: HeaderProps): JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Patient, ServiceRequest } from '@medplum/fhirtypes';
|
|
3
|
+
export declare type HeaderSearchTypes = Patient | ServiceRequest;
|
|
4
|
+
export interface HeaderSearchInputProps {
|
|
5
|
+
readonly name: string;
|
|
6
|
+
readonly className?: string;
|
|
7
|
+
readonly placeholder?: string;
|
|
8
|
+
readonly onChange: (value: HeaderSearchTypes) => void;
|
|
9
|
+
}
|
|
10
|
+
export declare function HeaderSearchInput(props: HeaderSearchInputProps): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { HumanNameFormatOptions } from '@medplum/core';
|
|
3
|
+
import { HumanName } from '@medplum/fhirtypes';
|
|
4
|
+
export interface HumanNameDisplayProps {
|
|
5
|
+
value?: HumanName;
|
|
6
|
+
options?: HumanNameFormatOptions;
|
|
7
|
+
}
|
|
8
|
+
export declare function HumanNameDisplay(props: HumanNameDisplayProps): JSX.Element | null;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { HumanName } from '@medplum/fhirtypes';
|
|
3
|
+
export interface HumanNameInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: HumanName;
|
|
6
|
+
onChange?: (value: HumanName) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function HumanNameInput(props: HumanNameInputProps): JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { Identifier } from '@medplum/fhirtypes';
|
|
3
|
+
export interface IdentifierInputProps {
|
|
4
|
+
name: string;
|
|
5
|
+
defaultValue?: Identifier;
|
|
6
|
+
onChange?: (value: Identifier) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function IdentifierInput(props: IdentifierInputProps): JSX.Element;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { OperationOutcome } from '@medplum/fhirtypes';
|
|
2
|
+
import React, { RefObject } from 'react';
|
|
3
|
+
import './Input.css';
|
|
4
|
+
export interface InputProps {
|
|
5
|
+
name?: string;
|
|
6
|
+
type?: string;
|
|
7
|
+
size?: number;
|
|
8
|
+
step?: number | 'any';
|
|
9
|
+
style?: React.CSSProperties;
|
|
10
|
+
defaultValue?: string | number;
|
|
11
|
+
required?: boolean;
|
|
12
|
+
autoCapitalize?: string;
|
|
13
|
+
autoComplete?: string;
|
|
14
|
+
autoFocus?: boolean;
|
|
15
|
+
inputRef?: RefObject<HTMLInputElement>;
|
|
16
|
+
outcome?: OperationOutcome;
|
|
17
|
+
placeholder?: string;
|
|
18
|
+
testid?: string;
|
|
19
|
+
disabled?: boolean;
|
|
20
|
+
onChange?: (newValue: string) => void;
|
|
21
|
+
}
|
|
22
|
+
export declare function Input(props: InputProps): JSX.Element;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Reference, Resource } from '@medplum/fhirtypes';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
export interface MedplumLinkProps {
|
|
4
|
+
to?: Resource | Reference | string;
|
|
5
|
+
suffix?: string;
|
|
6
|
+
label?: string;
|
|
7
|
+
id?: string;
|
|
8
|
+
testid?: string;
|
|
9
|
+
className?: string;
|
|
10
|
+
onClick?: () => void;
|
|
11
|
+
children: React.ReactNode;
|
|
12
|
+
}
|
|
13
|
+
export declare function MedplumLink(props: MedplumLinkProps): JSX.Element;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { MedplumClient, ProfileResource } from '@medplum/core';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
export interface MedplumProviderProps {
|
|
4
|
+
medplum: MedplumClient;
|
|
5
|
+
children: React.ReactNode;
|
|
6
|
+
}
|
|
7
|
+
export interface MedplumContext {
|
|
8
|
+
medplum: MedplumClient;
|
|
9
|
+
profile?: ProfileResource;
|
|
10
|
+
loading: boolean;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* The MedplumProvider component provides Medplum context state.
|
|
14
|
+
*
|
|
15
|
+
* Medplum context includes:
|
|
16
|
+
* 1) medplum - Medplum client library
|
|
17
|
+
* 2) profile - The current user profile (if signed in)
|
|
18
|
+
*/
|
|
19
|
+
export declare function MedplumProvider(props: MedplumProviderProps): JSX.Element;
|
|
20
|
+
/**
|
|
21
|
+
* Returns the MedplumContext instance.
|
|
22
|
+
*/
|
|
23
|
+
export declare function useMedplumContext(): MedplumContext;
|
|
24
|
+
/**
|
|
25
|
+
* Returns the MedplumClient instance.
|
|
26
|
+
* This is a shortcut for useMedplumContext().medplum.
|
|
27
|
+
*/
|
|
28
|
+
export declare function useMedplum(): MedplumClient;
|
|
29
|
+
/**
|
|
30
|
+
* Returns the current Medplum user profile (if signed in).
|
|
31
|
+
* This is a shortcut for useMedplumContext().profile.
|
|
32
|
+
* @returns The current user profile.
|
|
33
|
+
*/
|
|
34
|
+
export declare function useMedplumProfile(): ProfileResource | undefined;
|