@openmrs/esm-framework 8.0.1-pre.3757 → 8.0.1-pre.3762
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/.turbo/turbo-build.log +1 -1
- package/docs/functions/CustomOverflowMenu.md +6 -1
- package/docs/functions/CustomOverflowMenuItem.md +1 -1
- package/docs/functions/PatientBannerActionsMenu.md +8 -3
- package/docs/functions/useCustomOverflowMenu.md +1 -1
- package/mock-jest.tsx +5 -0
- package/mock.tsx +5 -0
- package/package.json +20 -20
package/.turbo/turbo-build.log
CHANGED
|
@@ -4,7 +4,12 @@
|
|
|
4
4
|
|
|
5
5
|
> **CustomOverflowMenu**(`__namedParameters`): `Element`
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx:
|
|
7
|
+
Defined in: [packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx:45](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx#L45)
|
|
8
|
+
|
|
9
|
+
A custom overflow menu that supports a text/icon trigger button instead of
|
|
10
|
+
Carbon's icon-only OverflowMenu trigger. Uses CSS-based show/hide rather
|
|
11
|
+
than Carbon's FloatingMenu portal, so keyboard behavior (Escape, arrow keys,
|
|
12
|
+
auto-focus) is implemented here to match the WAI-ARIA menu button pattern.
|
|
8
13
|
|
|
9
14
|
## Parameters
|
|
10
15
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
> **CustomOverflowMenuItem**(`props`): `Element`
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx:
|
|
7
|
+
Defined in: [packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx:162](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx#L162)
|
|
8
8
|
|
|
9
9
|
## Parameters
|
|
10
10
|
|
|
@@ -2,9 +2,14 @@
|
|
|
2
2
|
|
|
3
3
|
# Function: PatientBannerActionsMenu()
|
|
4
4
|
|
|
5
|
-
> **PatientBannerActionsMenu**(`__namedParameters`): `Element`
|
|
5
|
+
> **PatientBannerActionsMenu**(`__namedParameters`): `null` \| `Element`
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/framework/esm-styleguide/src/patient-banner/actions-menu/patient-banner-actions-menu.component.tsx:
|
|
7
|
+
Defined in: [packages/framework/esm-styleguide/src/patient-banner/actions-menu/patient-banner-actions-menu.component.tsx:27](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/patient-banner/actions-menu/patient-banner-actions-menu.component.tsx#L27)
|
|
8
|
+
|
|
9
|
+
Overflow menu for the patient banner whose items come from an ExtensionSlot
|
|
10
|
+
rather than direct React children. Because cloneElement cannot inject props
|
|
11
|
+
into extension-rendered components, arrow key navigation is handled at the
|
|
12
|
+
container level via onKeyDown instead of delegating to Carbon's OverflowMenuItem.
|
|
8
13
|
|
|
9
14
|
## Parameters
|
|
10
15
|
|
|
@@ -14,4 +19,4 @@ Defined in: [packages/framework/esm-styleguide/src/patient-banner/actions-menu/p
|
|
|
14
19
|
|
|
15
20
|
## Returns
|
|
16
21
|
|
|
17
|
-
`Element`
|
|
22
|
+
`null` \| `Element`
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
> **useCustomOverflowMenu**(): `CustomOverflowMenuContextValue`
|
|
6
6
|
|
|
7
|
-
Defined in: [packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx:
|
|
7
|
+
Defined in: [packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx:26](https://github.com/openmrs/openmrs-esm-core/blob/main/packages/framework/esm-styleguide/src/custom-overflow-menu/custom-overflow-menu.component.tsx#L26)
|
|
8
8
|
|
|
9
9
|
## Returns
|
|
10
10
|
|
package/mock-jest.tsx
CHANGED
|
@@ -74,6 +74,11 @@ export const CustomOverflowMenu = jest.fn(({ menuTitle, children }) => (
|
|
|
74
74
|
{children}
|
|
75
75
|
</div>
|
|
76
76
|
));
|
|
77
|
+
export const CustomOverflowMenuItem = jest.fn(({ itemText, ...props }) => (
|
|
78
|
+
<button role="menuitem" {...props}>
|
|
79
|
+
{itemText}
|
|
80
|
+
</button>
|
|
81
|
+
));
|
|
77
82
|
export const PatientBannerActionsMenu = jest.fn(() => <div>Patient Banner Actions Menu</div>);
|
|
78
83
|
export const PatientBannerContactDetails = jest.fn(() => <div>Patient Banner Contact Details</div>);
|
|
79
84
|
export const PatientBannerPatientInfo = jest.fn(() => <div>Patient Banner Patient Info</div>);
|
package/mock.tsx
CHANGED
|
@@ -75,6 +75,11 @@ export const CustomOverflowMenu = vi.fn(({ menuTitle, children }) => (
|
|
|
75
75
|
{children}
|
|
76
76
|
</div>
|
|
77
77
|
));
|
|
78
|
+
export const CustomOverflowMenuItem = vi.fn(({ itemText, ...props }) => (
|
|
79
|
+
<button role="menuitem" {...props}>
|
|
80
|
+
{itemText}
|
|
81
|
+
</button>
|
|
82
|
+
));
|
|
78
83
|
export const PatientBannerActionsMenu = vi.fn(() => <div>Patient Banner Actions Menu</div>);
|
|
79
84
|
export const PatientBannerContactDetails = vi.fn(() => <div>Patient Banner Contact Details</div>);
|
|
80
85
|
export const PatientBannerPatientInfo = vi.fn(() => <div>Patient Banner Patient Info</div>);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openmrs/esm-framework",
|
|
3
|
-
"version": "8.0.1-pre.
|
|
3
|
+
"version": "8.0.1-pre.3762",
|
|
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.
|
|
64
|
-
"@openmrs/esm-config": "8.0.1-pre.
|
|
65
|
-
"@openmrs/esm-context": "8.0.1-pre.
|
|
66
|
-
"@openmrs/esm-dynamic-loading": "8.0.1-pre.
|
|
67
|
-
"@openmrs/esm-emr-api": "8.0.1-pre.
|
|
68
|
-
"@openmrs/esm-error-handling": "8.0.1-pre.
|
|
69
|
-
"@openmrs/esm-expression-evaluator": "8.0.1-pre.
|
|
70
|
-
"@openmrs/esm-extensions": "8.0.1-pre.
|
|
71
|
-
"@openmrs/esm-feature-flags": "8.0.1-pre.
|
|
72
|
-
"@openmrs/esm-globals": "8.0.1-pre.
|
|
73
|
-
"@openmrs/esm-navigation": "8.0.1-pre.
|
|
74
|
-
"@openmrs/esm-offline": "8.0.1-pre.
|
|
75
|
-
"@openmrs/esm-react-utils": "8.0.1-pre.
|
|
76
|
-
"@openmrs/esm-routes": "8.0.1-pre.
|
|
77
|
-
"@openmrs/esm-state": "8.0.1-pre.
|
|
78
|
-
"@openmrs/esm-styleguide": "8.0.1-pre.
|
|
79
|
-
"@openmrs/esm-translations": "8.0.1-pre.
|
|
80
|
-
"@openmrs/esm-utils": "8.0.1-pre.
|
|
63
|
+
"@openmrs/esm-api": "8.0.1-pre.3762",
|
|
64
|
+
"@openmrs/esm-config": "8.0.1-pre.3762",
|
|
65
|
+
"@openmrs/esm-context": "8.0.1-pre.3762",
|
|
66
|
+
"@openmrs/esm-dynamic-loading": "8.0.1-pre.3762",
|
|
67
|
+
"@openmrs/esm-emr-api": "8.0.1-pre.3762",
|
|
68
|
+
"@openmrs/esm-error-handling": "8.0.1-pre.3762",
|
|
69
|
+
"@openmrs/esm-expression-evaluator": "8.0.1-pre.3762",
|
|
70
|
+
"@openmrs/esm-extensions": "8.0.1-pre.3762",
|
|
71
|
+
"@openmrs/esm-feature-flags": "8.0.1-pre.3762",
|
|
72
|
+
"@openmrs/esm-globals": "8.0.1-pre.3762",
|
|
73
|
+
"@openmrs/esm-navigation": "8.0.1-pre.3762",
|
|
74
|
+
"@openmrs/esm-offline": "8.0.1-pre.3762",
|
|
75
|
+
"@openmrs/esm-react-utils": "8.0.1-pre.3762",
|
|
76
|
+
"@openmrs/esm-routes": "8.0.1-pre.3762",
|
|
77
|
+
"@openmrs/esm-state": "8.0.1-pre.3762",
|
|
78
|
+
"@openmrs/esm-styleguide": "8.0.1-pre.3762",
|
|
79
|
+
"@openmrs/esm-translations": "8.0.1-pre.3762",
|
|
80
|
+
"@openmrs/esm-utils": "8.0.1-pre.3762"
|
|
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.
|
|
93
|
+
"@openmrs/typedoc-plugin-file-categories": "8.0.1-pre.3762",
|
|
94
94
|
"@rspack/cli": "^1.3.11",
|
|
95
95
|
"@rspack/core": "^1.3.11",
|
|
96
96
|
"@vitest/coverage-v8": "^4.0.7",
|