@medplum/react 4.0.3 → 4.0.4

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.
@@ -640,7 +640,7 @@ export declare interface FhirPathTableProps {
640
640
  export declare function Form(props: FormProps): JSX.Element;
641
641
 
642
642
  export declare interface FormProps {
643
- readonly onSubmit?: (formData: Record<string, string>) => void;
643
+ readonly onSubmit?: (formData: Record<string, string>) => Promise<void> | void;
644
644
  readonly style?: CSSProperties;
645
645
  readonly children?: ReactNode;
646
646
  readonly testid?: string;
@@ -803,6 +803,13 @@ export declare type IntervalGroup = {
803
803
  intervals: ObservationDefinitionQualifiedInterval[];
804
804
  };
805
805
 
806
+ /**
807
+ * Returns true if the event is an auxiliary click.
808
+ * @param e - The event.
809
+ * @returns True if the event is an auxiliary click.
810
+ */
811
+ export declare function isAuxClick(e: MouseEvent_2): boolean;
812
+
806
813
  /**
807
814
  * Returns true if the element is a checkbox or a table cell containing a checkbox.
808
815
  * Table cells containing checkboxes are commonly accidentally clicked.
@@ -1069,25 +1076,27 @@ export declare interface QuestionnaireFormProps {
1069
1076
  readonly onSubmit?: (response: QuestionnaireResponse) => void;
1070
1077
  }
1071
1078
 
1072
- export declare enum QuestionnaireItemType {
1073
- group = "group",
1074
- display = "display",
1075
- question = "question",
1076
- boolean = "boolean",
1077
- decimal = "decimal",
1078
- integer = "integer",
1079
- date = "date",
1080
- dateTime = "dateTime",
1081
- time = "time",
1082
- string = "string",
1083
- text = "text",
1084
- url = "url",
1085
- choice = "choice",
1086
- openChoice = "open-choice",
1087
- attachment = "attachment",
1088
- reference = "reference",
1089
- quantity = "quantity"
1090
- }
1079
+ export declare const QuestionnaireItemType: {
1080
+ readonly group: "group";
1081
+ readonly display: "display";
1082
+ readonly question: "question";
1083
+ readonly boolean: "boolean";
1084
+ readonly decimal: "decimal";
1085
+ readonly integer: "integer";
1086
+ readonly date: "date";
1087
+ readonly dateTime: "dateTime";
1088
+ readonly time: "time";
1089
+ readonly string: "string";
1090
+ readonly text: "text";
1091
+ readonly url: "url";
1092
+ readonly choice: "choice";
1093
+ readonly openChoice: "open-choice";
1094
+ readonly attachment: "attachment";
1095
+ readonly reference: "reference";
1096
+ readonly quantity: "quantity";
1097
+ };
1098
+
1099
+ export declare type QuestionnaireItemType = (typeof QuestionnaireItemType)[keyof typeof QuestionnaireItemType];
1091
1100
 
1092
1101
  export declare function RangeDisplay(props: RangeDisplayProps): JSX.Element | null;
1093
1102
 
@@ -640,7 +640,7 @@ export declare interface FhirPathTableProps {
640
640
  export declare function Form(props: FormProps): JSX.Element;
641
641
 
642
642
  export declare interface FormProps {
643
- readonly onSubmit?: (formData: Record<string, string>) => void;
643
+ readonly onSubmit?: (formData: Record<string, string>) => Promise<void> | void;
644
644
  readonly style?: CSSProperties;
645
645
  readonly children?: ReactNode;
646
646
  readonly testid?: string;
@@ -803,6 +803,13 @@ export declare type IntervalGroup = {
803
803
  intervals: ObservationDefinitionQualifiedInterval[];
804
804
  };
805
805
 
806
+ /**
807
+ * Returns true if the event is an auxiliary click.
808
+ * @param e - The event.
809
+ * @returns True if the event is an auxiliary click.
810
+ */
811
+ export declare function isAuxClick(e: MouseEvent_2): boolean;
812
+
806
813
  /**
807
814
  * Returns true if the element is a checkbox or a table cell containing a checkbox.
808
815
  * Table cells containing checkboxes are commonly accidentally clicked.
@@ -1069,25 +1076,27 @@ export declare interface QuestionnaireFormProps {
1069
1076
  readonly onSubmit?: (response: QuestionnaireResponse) => void;
1070
1077
  }
1071
1078
 
1072
- export declare enum QuestionnaireItemType {
1073
- group = "group",
1074
- display = "display",
1075
- question = "question",
1076
- boolean = "boolean",
1077
- decimal = "decimal",
1078
- integer = "integer",
1079
- date = "date",
1080
- dateTime = "dateTime",
1081
- time = "time",
1082
- string = "string",
1083
- text = "text",
1084
- url = "url",
1085
- choice = "choice",
1086
- openChoice = "open-choice",
1087
- attachment = "attachment",
1088
- reference = "reference",
1089
- quantity = "quantity"
1090
- }
1079
+ export declare const QuestionnaireItemType: {
1080
+ readonly group: "group";
1081
+ readonly display: "display";
1082
+ readonly question: "question";
1083
+ readonly boolean: "boolean";
1084
+ readonly decimal: "decimal";
1085
+ readonly integer: "integer";
1086
+ readonly date: "date";
1087
+ readonly dateTime: "dateTime";
1088
+ readonly time: "time";
1089
+ readonly string: "string";
1090
+ readonly text: "text";
1091
+ readonly url: "url";
1092
+ readonly choice: "choice";
1093
+ readonly openChoice: "open-choice";
1094
+ readonly attachment: "attachment";
1095
+ readonly reference: "reference";
1096
+ readonly quantity: "quantity";
1097
+ };
1098
+
1099
+ export declare type QuestionnaireItemType = (typeof QuestionnaireItemType)[keyof typeof QuestionnaireItemType];
1091
1100
 
1092
1101
  export declare function RangeDisplay(props: RangeDisplayProps): JSX.Element | null;
1093
1102