@openmrs/esm-framework 8.0.1-pre.3585 → 8.0.1-pre.3592

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/docs/API.md CHANGED
@@ -195,7 +195,9 @@
195
195
  - [usePagination](functions/usePagination.md)
196
196
  - [useFhirPagination](functions/useFhirPagination.md)
197
197
  - [getFhirServerPaginationHandlers](functions/getFhirServerPaginationHandlers.md)
198
- - [ResponsiveWrapperProps](interfaces/ResponsiveWrapperProps.md)
198
+ - [CustomOverflowMenu](functions/CustomOverflowMenu.md)
199
+ - [PageHeaderContentProps](interfaces/PageHeaderContentProps.md)
200
+ - [PageHeaderWrapperProps](interfaces/PageHeaderWrapperProps.md)
199
201
  - [PatientBannerPatientInfo](functions/PatientBannerPatientInfo.md)
200
202
  - [PatientBannerPatientIdentifiers](functions/PatientBannerPatientIdentifiers.md)
201
203
  - [PatientBannerActionsMenu](functions/PatientBannerActionsMenu.md)
@@ -207,24 +209,22 @@
207
209
  - [PatientPhotoProps](interfaces/PatientPhotoProps.md)
208
210
  - [usePatientPhoto](functions/usePatientPhoto.md)
209
211
  - [UsePatientPhotoResult](interfaces/UsePatientPhotoResult.md)
210
- - [CustomOverflowMenu](functions/CustomOverflowMenu.md)
211
- - [PageHeaderContentProps](interfaces/PageHeaderContentProps.md)
212
- - [PageHeaderWrapperProps](interfaces/PageHeaderWrapperProps.md)
212
+ - [ResponsiveWrapperProps](interfaces/ResponsiveWrapperProps.md)
213
213
  - [useOpenmrsPagination](functions/useOpenmrsPagination.md)
214
214
  - [UseServerPaginationOptions](interfaces/UseServerPaginationOptions.md)
215
215
  - [useOpenmrsInfinite](functions/useOpenmrsInfinite.md)
216
216
  - [UseServerInfiniteOptions](interfaces/UseServerInfiniteOptions.md)
217
217
  - [useOpenmrsFetchAll](functions/useOpenmrsFetchAll.md)
218
218
  - [UseServerFetchAllOptions](interfaces/UseServerFetchAllOptions.md)
219
+ - [showModal](functions/showModal.md)
219
220
  - [showNotification](functions/showNotification.md)
220
221
  - [showActionableNotification](functions/showActionableNotification.md)
221
- - [showToast](functions/showToast.md)
222
- - [showModal](functions/showModal.md)
223
- - [ToastDescriptor](interfaces/ToastDescriptor.md)
224
- - [ToastNotificationMeta](interfaces/ToastNotificationMeta.md)
225
222
  - [showSnackbar](functions/showSnackbar.md)
226
223
  - [SnackbarDescriptor](interfaces/SnackbarDescriptor.md)
227
224
  - [SnackbarMeta](interfaces/SnackbarMeta.md)
225
+ - [showToast](functions/showToast.md)
226
+ - [ToastDescriptor](interfaces/ToastDescriptor.md)
227
+ - [ToastNotificationMeta](interfaces/ToastNotificationMeta.md)
228
228
 
229
229
  ## Config
230
230
 
@@ -0,0 +1,19 @@
1
+ [O3 Framework](../API.md) / CardHeader
2
+
3
+ # Function: CardHeader()
4
+
5
+ > **CardHeader**(`__namedParameters`): `Element`
6
+
7
+ Defined in: [packages/framework/esm-styleguide/src/cards/card-header.component.tsx:16](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/cards/card-header.component.tsx#L16)
8
+
9
+ Re-usable header component for O3-style cards, like those found on the patient chart
10
+
11
+ ## Parameters
12
+
13
+ ### \_\_namedParameters
14
+
15
+ [`CardHeaderProps`](../interfaces/CardHeaderProps.md)
16
+
17
+ ## Returns
18
+
19
+ `Element`
@@ -17,7 +17,7 @@ invalid key to this function will result in a type error.
17
17
 
18
18
  ### key
19
19
 
20
- `"error"` | `"delete"` | `"actions"` | `"actionableNotification"` | `"address"` | `"age"` | `"cancel"` | `"change"` | `"Clinic"` | `"close"` | `"closesActionableNotification"` | `"closeSnackbar"` | `"confirm"` | `"contactAdministratorIfIssuePersists"` | `"contactDetails"` | `"discardChanges"` | `"edit"` | `"errorCopy"` | `"errorLoadingLoginLocations"` | `"female"` | `"leftNavigation"` | `"loading"` | `"male"` | `"noResultsToDisplay"` | `"other"` | `"patientAvatarAlt"` | `"patientIdentifierSticker"` | `"patientLists"` | `"patientPhotoAlt"` | `"patientPhotoPlaceholder"` | `"print"` | `"printError"` | `"printErrorExplainer"` | `"printIdentifierSticker"` | `"printing"` | `"relationships"` | `"resetOverrides"` | `"save"` | `"scriptLoadingFailed"` | `"scriptLoadingError"` | `"searchForLocation"` | `"seeMoreLists"` | `"sex"` | `"showLess"` | `"showMore"` | `"snackbarNotification"` | `"toggleDevTools"` | `"unknown"` | `"yearAbbreviation"` | `"yearsAbbreviation"` | `"closeWorkspaces2PromptTitle"` | `"closeWorkspaces2PromptBody"` | `"closeAllOpenedWorkspaces"` | `"closingAllWorkspacesPromptBody"` | `"closingAllWorkspacesPromptTitle"` | `"discard"` | `"hide"` | `"maximize"` | `"minimize"` | `"openAnyway"` | `"unsavedChangesInOpenedWorkspace"` | `"unsavedChangesInWorkspace"` | `"unsavedChangesTitleText"` | `"workspaceHeader"` | `"address1"` | `"address2"` | `"address3"` | `"address4"` | `"address5"` | `"address6"` | `"city"` | `"cityVillage"` | `"country"` | `"countyDistrict"` | `"district"` | `"postalCode"` | `"state"` | `"stateProvince"`
20
+ `"error"` | `"delete"` | `"actions"` | `"actionableNotification"` | `"address"` | `"age"` | `"cancel"` | `"change"` | `"Clinic"` | `"close"` | `"closesActionableNotification"` | `"closeSnackbar"` | `"confirm"` | `"contactAdministratorIfIssuePersists"` | `"contactDetails"` | `"discardChanges"` | `"edit"` | `"emptyStateText"` | `"errorCopy"` | `"errorLoadingLoginLocations"` | `"female"` | `"leftNavigation"` | `"loading"` | `"male"` | `"noResultsToDisplay"` | `"other"` | `"paginationItemsCount"` | `"paginationOfPages"` | `"patientAvatarAlt"` | `"patientIdentifierSticker"` | `"patientLists"` | `"patientPhotoAlt"` | `"patientPhotoPlaceholder"` | `"print"` | `"printError"` | `"printErrorExplainer"` | `"printIdentifierSticker"` | `"printing"` | `"recordNewEntry"` | `"relationships"` | `"resetOverrides"` | `"save"` | `"scriptLoadingFailed"` | `"scriptLoadingError"` | `"searchForLocation"` | `"seeAll"` | `"seeMoreLists"` | `"sex"` | `"showLess"` | `"showMore"` | `"snackbarNotification"` | `"toggleDevTools"` | `"unknown"` | `"yearAbbreviation"` | `"yearsAbbreviation"` | `"closeWorkspaces2PromptTitle"` | `"closeWorkspaces2PromptBody"` | `"closeAllOpenedWorkspaces"` | `"closingAllWorkspacesPromptBody"` | `"closingAllWorkspacesPromptTitle"` | `"discard"` | `"hide"` | `"maximize"` | `"minimize"` | `"openAnyway"` | `"unsavedChangesInOpenedWorkspace"` | `"unsavedChangesInWorkspace"` | `"unsavedChangesTitleText"` | `"workspaceHeader"` | `"address1"` | `"address2"` | `"address3"` | `"address4"` | `"address5"` | `"address6"` | `"city"` | `"cityVillage"` | `"country"` | `"countyDistrict"` | `"district"` | `"postalCode"` | `"state"` | `"stateProvince"`
21
21
 
22
22
  ### defaultText?
23
23
 
@@ -4,7 +4,7 @@
4
4
 
5
5
  > **showSnackbar**(`snackbar`): `void`
6
6
 
7
- Defined in: [packages/framework/esm-styleguide/src/snackbars/index.tsx:32](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/snackbars/index.tsx#L32)
7
+ Defined in: [packages/framework/esm-styleguide/src/snackbars/index.tsx:34](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/snackbars/index.tsx#L34)
8
8
 
9
9
  Displays a snack bar notification in the UI.
10
10
 
@@ -4,7 +4,7 @@
4
4
 
5
5
  > **showToast**(`toast`): `void`
6
6
 
7
- Defined in: [packages/framework/esm-styleguide/src/toasts/index.tsx:36](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/toasts/index.tsx#L36)
7
+ Defined in: [packages/framework/esm-styleguide/src/toasts/index.tsx:38](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/toasts/index.tsx#L38)
8
8
 
9
9
  Displays a toast notification in the UI.
10
10
 
@@ -0,0 +1,25 @@
1
+ [O3 Framework](../API.md) / CardHeaderProps
2
+
3
+ # Interface: CardHeaderProps
4
+
5
+ Defined in: [packages/framework/esm-styleguide/src/cards/card-header.component.tsx:6](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/cards/card-header.component.tsx#L6)
6
+
7
+ ## Properties
8
+
9
+ ### children?
10
+
11
+ > `optional` **children**: `ReactNode`
12
+
13
+ Defined in: [packages/framework/esm-styleguide/src/cards/card-header.component.tsx:10](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/cards/card-header.component.tsx#L10)
14
+
15
+ The contents of the card header to render if any.
16
+
17
+ ***
18
+
19
+ ### title
20
+
21
+ > **title**: `string`
22
+
23
+ Defined in: [packages/framework/esm-styleguide/src/cards/card-header.component.tsx:8](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/cards/card-header.component.tsx#L8)
24
+
25
+ The title for this card. This must be a pre-translated string.
@@ -0,0 +1,39 @@
1
+ [O3 Framework](../API.md) / EmptyCardProps
2
+
3
+ # Interface: EmptyCardProps
4
+
5
+ Defined in: [packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx:9](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx#L9)
6
+
7
+ ## Properties
8
+
9
+ ### displayText
10
+
11
+ > **displayText**: `string`
12
+
13
+ Defined in: [packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx:11](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx#L11)
14
+
15
+ The name of the type of item that would be displayed here if not empty. This must be a pre-translated string.
16
+
17
+ ***
18
+
19
+ ### headerTitle
20
+
21
+ > **headerTitle**: `string`
22
+
23
+ Defined in: [packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx:13](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx#L13)
24
+
25
+ The title to use for this empty component. This must be a pre-translated string.
26
+
27
+ ## Methods
28
+
29
+ ### launchForm()?
30
+
31
+ > `optional` **launchForm**(): `void`
32
+
33
+ Defined in: [packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx:15](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx#L15)
34
+
35
+ A callback to invoke when the user tries to record a new item.
36
+
37
+ #### Returns
38
+
39
+ `void`
@@ -0,0 +1,25 @@
1
+ [O3 Framework](../API.md) / ErrorCardProps
2
+
3
+ # Interface: ErrorCardProps
4
+
5
+ Defined in: [packages/framework/esm-styleguide/src/error-card/error-card.component.tsx:7](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/error-card/error-card.component.tsx#L7)
6
+
7
+ ## Properties
8
+
9
+ ### error
10
+
11
+ > **error**: `any`
12
+
13
+ Defined in: [packages/framework/esm-styleguide/src/error-card/error-card.component.tsx:9](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/error-card/error-card.component.tsx#L9)
14
+
15
+ This is the error that triggered rendering the card. It is expected to be the error returned from `openmrsFetch()`
16
+
17
+ ***
18
+
19
+ ### headerTitle
20
+
21
+ > **headerTitle**: `string`
22
+
23
+ Defined in: [packages/framework/esm-styleguide/src/error-card/error-card.component.tsx:11](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/error-card/error-card.component.tsx#L11)
24
+
25
+ The title for this card. This must be a pre-translated string.
@@ -0,0 +1,95 @@
1
+ [O3 Framework](../API.md) / PaginationProps
2
+
3
+ # Interface: PaginationProps
4
+
5
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:8](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L8)
6
+
7
+ ## Properties
8
+
9
+ ### currentItems
10
+
11
+ > **currentItems**: `number`
12
+
13
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:10](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L10)
14
+
15
+ The count of current items displayed
16
+
17
+ ***
18
+
19
+ ### dashboardLinkLabel?
20
+
21
+ > `optional` **dashboardLinkLabel**: `string`
22
+
23
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:22](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L22)
24
+
25
+ Optional text to display instead of the default "See all"
26
+
27
+ ***
28
+
29
+ ### dashboardLinkUrl?
30
+
31
+ > `optional` **dashboardLinkUrl**: `string`
32
+
33
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:20](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L20)
34
+
35
+ An optional URL the user should be directed to if they click on the link to see all results
36
+
37
+ ***
38
+
39
+ ### onPageNumberChange()?
40
+
41
+ > `optional` **onPageNumberChange**: (`data`) => `void`
42
+
43
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:18](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L18)
44
+
45
+ A callback to be called when the page changes
46
+
47
+ #### Parameters
48
+
49
+ ##### data
50
+
51
+ ###### page
52
+
53
+ `number`
54
+
55
+ ###### pageSize
56
+
57
+ `number`
58
+
59
+ ###### ref?
60
+
61
+ `RefObject`\<`any`\>
62
+
63
+ #### Returns
64
+
65
+ `void`
66
+
67
+ ***
68
+
69
+ ### pageNumber
70
+
71
+ > **pageNumber**: `number`
72
+
73
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:14](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L14)
74
+
75
+ The current page number
76
+
77
+ ***
78
+
79
+ ### pageSize
80
+
81
+ > **pageSize**: `number`
82
+
83
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:16](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L16)
84
+
85
+ The size of each page
86
+
87
+ ***
88
+
89
+ ### totalItems
90
+
91
+ > **totalItems**: `number`
92
+
93
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:12](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L12)
94
+
95
+ The count of total items displayed
@@ -0,0 +1,9 @@
1
+ [O3 Framework](../API.md) / EmptyCard
2
+
3
+ # Variable: EmptyCard
4
+
5
+ > `const` **EmptyCard**: `React.FC`\<[`EmptyCardProps`](../interfaces/EmptyCardProps.md)\>
6
+
7
+ Defined in: [packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx:29](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/empty-card/empty-card.component.tsx#L29)
8
+
9
+ Re-usable card for displaying an empty state
@@ -0,0 +1,9 @@
1
+ [O3 Framework](../API.md) / ErrorCard
2
+
3
+ # Variable: ErrorCard
4
+
5
+ > `const` **ErrorCard**: `React.FC`\<[`ErrorCardProps`](../interfaces/ErrorCardProps.md)\>
6
+
7
+ Defined in: [packages/framework/esm-styleguide/src/error-card/error-card.component.tsx:17](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/error-card/error-card.component.tsx#L17)
8
+
9
+ Re-usable card for displaying a fetch error
@@ -0,0 +1,9 @@
1
+ [O3 Framework](../API.md) / Pagination
2
+
3
+ # Variable: Pagination
4
+
5
+ > `const` **Pagination**: `React.FC`\<[`PaginationProps`](../interfaces/PaginationProps.md)\>
6
+
7
+ Defined in: [packages/framework/esm-styleguide/src/pagination/pagination.component.tsx:28](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/pagination/pagination.component.tsx#L28)
8
+
9
+ Re-usable pagination bar
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openmrs/esm-framework",
3
- "version": "8.0.1-pre.3585",
3
+ "version": "8.0.1-pre.3592",
4
4
  "license": "MPL-2.0",
5
5
  "type": "module",
6
6
  "module": "dist/openmrs-esm-framework.js",
@@ -60,24 +60,24 @@
60
60
  "access": "public"
61
61
  },
62
62
  "dependencies": {
63
- "@openmrs/esm-api": "8.0.1-pre.3585",
64
- "@openmrs/esm-config": "8.0.1-pre.3585",
65
- "@openmrs/esm-context": "8.0.1-pre.3585",
66
- "@openmrs/esm-dynamic-loading": "8.0.1-pre.3585",
67
- "@openmrs/esm-emr-api": "8.0.1-pre.3585",
68
- "@openmrs/esm-error-handling": "8.0.1-pre.3585",
69
- "@openmrs/esm-expression-evaluator": "8.0.1-pre.3585",
70
- "@openmrs/esm-extensions": "8.0.1-pre.3585",
71
- "@openmrs/esm-feature-flags": "8.0.1-pre.3585",
72
- "@openmrs/esm-globals": "8.0.1-pre.3585",
73
- "@openmrs/esm-navigation": "8.0.1-pre.3585",
74
- "@openmrs/esm-offline": "8.0.1-pre.3585",
75
- "@openmrs/esm-react-utils": "8.0.1-pre.3585",
76
- "@openmrs/esm-routes": "8.0.1-pre.3585",
77
- "@openmrs/esm-state": "8.0.1-pre.3585",
78
- "@openmrs/esm-styleguide": "8.0.1-pre.3585",
79
- "@openmrs/esm-translations": "8.0.1-pre.3585",
80
- "@openmrs/esm-utils": "8.0.1-pre.3585"
63
+ "@openmrs/esm-api": "8.0.1-pre.3592",
64
+ "@openmrs/esm-config": "8.0.1-pre.3592",
65
+ "@openmrs/esm-context": "8.0.1-pre.3592",
66
+ "@openmrs/esm-dynamic-loading": "8.0.1-pre.3592",
67
+ "@openmrs/esm-emr-api": "8.0.1-pre.3592",
68
+ "@openmrs/esm-error-handling": "8.0.1-pre.3592",
69
+ "@openmrs/esm-expression-evaluator": "8.0.1-pre.3592",
70
+ "@openmrs/esm-extensions": "8.0.1-pre.3592",
71
+ "@openmrs/esm-feature-flags": "8.0.1-pre.3592",
72
+ "@openmrs/esm-globals": "8.0.1-pre.3592",
73
+ "@openmrs/esm-navigation": "8.0.1-pre.3592",
74
+ "@openmrs/esm-offline": "8.0.1-pre.3592",
75
+ "@openmrs/esm-react-utils": "8.0.1-pre.3592",
76
+ "@openmrs/esm-routes": "8.0.1-pre.3592",
77
+ "@openmrs/esm-state": "8.0.1-pre.3592",
78
+ "@openmrs/esm-styleguide": "8.0.1-pre.3592",
79
+ "@openmrs/esm-translations": "8.0.1-pre.3592",
80
+ "@openmrs/esm-utils": "8.0.1-pre.3592"
81
81
  },
82
82
  "peerDependencies": {
83
83
  "dayjs": "1.x",
@@ -90,7 +90,7 @@
90
90
  "swr": "2.x"
91
91
  },
92
92
  "devDependencies": {
93
- "@openmrs/typedoc-plugin-file-categories": "8.0.1-pre.3585",
93
+ "@openmrs/typedoc-plugin-file-categories": "8.0.1-pre.3592",
94
94
  "@rspack/cli": "^1.3.11",
95
95
  "@rspack/core": "^1.3.11",
96
96
  "@vitest/coverage-v8": "^4.0.7",