@kenyaemr/esm-patient-clinical-view-app 5.4.2-pre.2475 → 5.4.2-pre.2482
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 +10 -10
- package/dist/508.js +1 -0
- package/dist/508.js.map +1 -0
- package/dist/76.js +1 -1
- package/dist/76.js.map +1 -1
- package/dist/kenyaemr-esm-patient-clinical-view-app.js +1 -1
- package/dist/kenyaemr-esm-patient-clinical-view-app.js.buildmanifest.json +28 -28
- package/dist/main.js +1 -1
- package/dist/main.js.map +1 -1
- package/dist/routes.json +1 -1
- package/package.json +1 -1
- package/src/dashboard/dashboard.meta.tsx +7 -0
- package/src/dispensing/pharmacy.component.tsx +13 -0
- package/src/index.ts +5 -0
- package/src/left-panel-link.component.tsx +13 -5
- package/src/leftt-panel-link.scss +13 -0
- package/src/routes.json +19 -0
- package/dist/246.js +0 -1
- package/dist/246.js.map +0 -1
package/dist/routes.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"kenyaemr":"^19.0.0"},"pages":[],"extensions":[{"name":"hiv-care-and-treatment-dashboard-link","slot":"patient-chart-dashboard-slot","component":"hivCareAndTreatmentLink","meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-hiv-care-and-treatment-dashboard-slot","path":"hiv-care-and-treatment-dashboard","layoutMode":"anchored"}},{"name":"hiv-care-and-treatment-dashboard","slot":"patient-chart-hiv-care-and-treatment-dashboard-slot","component":"hivCareAndTreatment","order":0,"online":true,"offline":false},{"name":"relationship-dashboard-link","slot":"patient-chart-dashboard-slot","component":"relationshipsLink","order":24,"online":true,"offline":false,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-relationship-slot","path":"relationships","layoutMode":"anchored"}},{"name":"relationship-dashboard","slot":"patient-chart-relationship-slot","component":"relationships","order":0,"online":true,"offline":false},{"name":"clinical-encounter-dashboard-link","component":"clinicalEncounterLink","slot":"patient-chart-dashboard-slot","order":25,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-clinical-encounter-slot","path":"clinical-encounter","layoutMode":"anchored"}},{"name":"clinical-encounter-dashboard","slot":"patient-chart-clinical-encounter-slot","component":"clinicalEncounter","order":0,"online":true,"offline":false},{"name":"maternal-and-child-health-dashboard-link","component":"maternalAndChildHealthDashboardLink","slot":"patient-chart-dashboard-slot","order":26,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-maternal-and-child-health-slot","path":"maternal-and-child-health","layoutMode":"anchored"}},{"name":"maternal-and-child-health-dashboard","slot":"patient-chart-maternal-and-child-health-slot","component":"maternalAndChildHealthDashboard","order":0,"online":true,"offline":false},{"name":"contact-list-dashboard-link","component":"contactListLink","slot":"patient-chart-dashboard-slot","order":27,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-contact-list-slot","path":"contact-list","layoutMode":"anchored"}},{"name":"contact-list-dashboard","slot":"patient-chart-contact-list-slot","component":"contactList","order":0,"online":true,"offline":false},{"component":"caseManagementDashboardLink","name":"case-management-dashboard-link","meta":{"name":"case-management","title":"Case Management","slot":"case-management-dashboard-slot","path":"/case-management"}},{"name":"in-patient-dashboard-link","component":"inPatientChartLink","slot":"patient-chart-dashboard-slot","order":7,"meta":{"slot":"patient-chart-in-patient-dashboard-slot","path":"in-patient","layoutMode":"anchored","columns":1,"columnSpan":1}},{"name":"in-patient-dashboard","slot":"patient-chart-in-patient-dashboard-slot","component":"inPatientChartDashboard","meta":{"fullWidth":false}},{"name":"wrap-component-view","slot":"case-management-dashboard-slot","component":"wrapComponent","order":2,"online":true,"offline":false},{"name":"case-encounter-link","component":"caseEncounterDashboardLink","slot":"patient-chart-dashboard-slot","order":14,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-case-encounter-slot","path":"case-management-encounters","layoutMode":"anchored"}},{"name":"case-encounter-table","slot":"patient-chart-case-encounter-slot","component":"caseEncounterTable","order":0,"online":true,"offline":false},{"component":"peerCalendarDashboardLink","name":"peer-calendar-dashboard-link","meta":{"name":"peer-calendar","title":"Peer Calendar","slot":"peer-calendar-dashboard-slot","path":"peer-management"}},{"name":"peer-calendar","slot":"peer-calendar-dashboard-slot","component":"peerCalendar","order":0,"online":true,"offline":false},{"name":"special-clinics-dashboard-link","component":"specialClinicsDashboardLink","slot":"patient-chart-dashboard-slot","order":15,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-special-clinics-slot","path":"special-clinics","layoutMode":"anchored"}},{"name":"special-clinics-dashboard","slot":"patient-chart-special-clinics-slot","component":"specialClinicsDashboard","order":0,"online":true,"offline":false}],"modals":[{"name":"birth-date-calculator","component":"birthDateCalculator"},{"name":"relationship-delete-confirm-dialog","component":"relationshipDeleteConfirmialog"},{"name":"end-relationship-dialog","component":"endRelationshipModal"}],"workspaces":[{"name":"contact-list-form","component":"contactListForm","title":"Contact List Form","type":"form"},{"name":"case-management-form","component":"caseManagementForm","title":"Case Management Form","type":"form"},{"name":"family-relationship-form","component":"familyRelationshipForm","title":"Family Relationship Form","type":"form"},{"name":"peers-form","component":"peersForm","title":"Add New Peer","type":"form"},{"name":"kenyaemr-cusom-form-entry-workspace","component":"peerCalendarFormEntry","title":"KVP Peer Educator Outreach Calendar","type":"form","width":"extra-wide","canMaximize":true,"canHide":true},{"name":"contact-list-update-form","component":"contactListUpdateForm","title":"Contact List Update Form","type":"form"},{"name":"other-relationship-form","component":"otherRelationshipsForm","title":"Other Relationships Form","type":"form"},{"name":"end-relationship-form","component":"endRelationshipWorkspace","title":"Discontinue relationship form","type":"form"}],"version":"5.4.2-pre.
|
|
1
|
+
{"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"kenyaemr":"^19.0.0"},"pages":[],"extensions":[{"name":"hiv-care-and-treatment-dashboard-link","slot":"patient-chart-dashboard-slot","component":"hivCareAndTreatmentLink","meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-hiv-care-and-treatment-dashboard-slot","path":"hiv-care-and-treatment-dashboard","layoutMode":"anchored"}},{"name":"hiv-care-and-treatment-dashboard","slot":"patient-chart-hiv-care-and-treatment-dashboard-slot","component":"hivCareAndTreatment","order":0,"online":true,"offline":false},{"name":"relationship-dashboard-link","slot":"patient-chart-dashboard-slot","component":"relationshipsLink","order":24,"online":true,"offline":false,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-relationship-slot","path":"relationships","layoutMode":"anchored"}},{"name":"relationship-dashboard","slot":"patient-chart-relationship-slot","component":"relationships","order":0,"online":true,"offline":false},{"name":"clinical-encounter-dashboard-link","component":"clinicalEncounterLink","slot":"patient-chart-dashboard-slot","order":25,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-clinical-encounter-slot","path":"clinical-encounter","layoutMode":"anchored"}},{"name":"clinical-encounter-dashboard","slot":"patient-chart-clinical-encounter-slot","component":"clinicalEncounter","order":0,"online":true,"offline":false},{"name":"maternal-and-child-health-dashboard-link","component":"maternalAndChildHealthDashboardLink","slot":"patient-chart-dashboard-slot","order":26,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-maternal-and-child-health-slot","path":"maternal-and-child-health","layoutMode":"anchored"}},{"name":"maternal-and-child-health-dashboard","slot":"patient-chart-maternal-and-child-health-slot","component":"maternalAndChildHealthDashboard","order":0,"online":true,"offline":false},{"name":"contact-list-dashboard-link","component":"contactListLink","slot":"patient-chart-dashboard-slot","order":27,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-contact-list-slot","path":"contact-list","layoutMode":"anchored"}},{"name":"contact-list-dashboard","slot":"patient-chart-contact-list-slot","component":"contactList","order":0,"online":true,"offline":false},{"component":"caseManagementDashboardLink","name":"case-management-dashboard-link","meta":{"name":"case-management","title":"Case Management","slot":"case-management-dashboard-slot","path":"/case-management"}},{"name":"in-patient-dashboard-link","component":"inPatientChartLink","slot":"patient-chart-dashboard-slot","order":7,"meta":{"slot":"patient-chart-in-patient-dashboard-slot","path":"in-patient","layoutMode":"anchored","columns":1,"columnSpan":1}},{"name":"in-patient-dashboard","slot":"patient-chart-in-patient-dashboard-slot","component":"inPatientChartDashboard","meta":{"fullWidth":false}},{"name":"wrap-component-view","slot":"case-management-dashboard-slot","component":"wrapComponent","order":2,"online":true,"offline":false},{"name":"case-encounter-link","component":"caseEncounterDashboardLink","slot":"patient-chart-dashboard-slot","order":14,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-case-encounter-slot","path":"case-management-encounters","layoutMode":"anchored"}},{"name":"case-encounter-table","slot":"patient-chart-case-encounter-slot","component":"caseEncounterTable","order":0,"online":true,"offline":false},{"component":"peerCalendarDashboardLink","name":"peer-calendar-dashboard-link","meta":{"name":"peer-calendar","title":"Peer Calendar","slot":"peer-calendar-dashboard-slot","path":"peer-management"}},{"name":"peer-calendar","slot":"peer-calendar-dashboard-slot","component":"peerCalendar","order":0,"online":true,"offline":false},{"name":"special-clinics-dashboard-link","component":"specialClinicsDashboardLink","slot":"patient-chart-dashboard-slot","order":15,"meta":{"columns":1,"columnSpan":1,"slot":"patient-chart-special-clinics-slot","path":"special-clinics","layoutMode":"anchored"}},{"name":"special-clinics-dashboard","slot":"patient-chart-special-clinics-slot","component":"specialClinicsDashboard","order":0,"online":true,"offline":false},{"name":"dispensing-homepage-dashboard-link","component":"pharmacyLink","slot":"homepage-dashboard-slot","meta":{"name":"dispensing","title":"Dispensing","path":"dispensing","slot":"dispensing-homepage-dashboard-slot"}},{"name":"home-page-dispensing-dashboard","component":"pharmacy","slot":"dispensing-homepage-dashboard-slot","order":0,"online":true,"offline":false}],"modals":[{"name":"birth-date-calculator","component":"birthDateCalculator"},{"name":"relationship-delete-confirm-dialog","component":"relationshipDeleteConfirmialog"},{"name":"end-relationship-dialog","component":"endRelationshipModal"}],"workspaces":[{"name":"contact-list-form","component":"contactListForm","title":"Contact List Form","type":"form"},{"name":"case-management-form","component":"caseManagementForm","title":"Case Management Form","type":"form"},{"name":"family-relationship-form","component":"familyRelationshipForm","title":"Family Relationship Form","type":"form"},{"name":"peers-form","component":"peersForm","title":"Add New Peer","type":"form"},{"name":"kenyaemr-cusom-form-entry-workspace","component":"peerCalendarFormEntry","title":"KVP Peer Educator Outreach Calendar","type":"form","width":"extra-wide","canMaximize":true,"canHide":true},{"name":"contact-list-update-form","component":"contactListUpdateForm","title":"Contact List Update Form","type":"form"},{"name":"other-relationship-form","component":"otherRelationshipsForm","title":"Other Relationships Form","type":"form"},{"name":"end-relationship-form","component":"endRelationshipWorkspace","title":"Discontinue relationship form","type":"form"}],"version":"5.4.2-pre.2482"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kenyaemr/esm-patient-clinical-view-app",
|
|
3
|
-
"version": "5.4.2-pre.
|
|
3
|
+
"version": "5.4.2-pre.2482",
|
|
4
4
|
"description": "Patient clinical view microfrontend for the OpenMRS SPA",
|
|
5
5
|
"browser": "dist/kenyaemr-esm-patient-clinical-view-app.js",
|
|
6
6
|
"main": "src/index.ts",
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ExtensionSlot, WorkspaceContainer } from '@openmrs/esm-framework';
|
|
3
|
+
|
|
4
|
+
const Pharmacy = () => {
|
|
5
|
+
return (
|
|
6
|
+
<div>
|
|
7
|
+
<ExtensionSlot name="dispensing-dashboard-slot" />
|
|
8
|
+
<WorkspaceContainer key="dispensing" contextKey="dispensing" />
|
|
9
|
+
</div>
|
|
10
|
+
);
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
export default Pharmacy;
|
package/src/index.ts
CHANGED
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
caseEncounterDashboardMeta,
|
|
7
7
|
caseManagementDashboardMeta,
|
|
8
8
|
contactListDashboardMeta,
|
|
9
|
+
dispensingDashboardMeta,
|
|
9
10
|
peerCalendarDashboardMeta,
|
|
10
11
|
relationshipsDashboardMeta,
|
|
11
12
|
specialClinicsDashboardMeta,
|
|
@@ -47,6 +48,7 @@ import { configSchema } from './config-schema';
|
|
|
47
48
|
import SpecialClinicDashboard from './special-clinics/special-clinic.component';
|
|
48
49
|
import { createDashboardLink as createDashboardLink2 } from './dashboard/createDashboardLink';
|
|
49
50
|
import { createLeftPanelLink } from './left-panel-link.component';
|
|
51
|
+
import Pharmacy from './dispensing/pharmacy.component';
|
|
50
52
|
|
|
51
53
|
const moduleName = '@kenyaemr/esm-patient-clinical-view-app';
|
|
52
54
|
|
|
@@ -108,6 +110,9 @@ export const inPatientChartDashboard = getSyncLifecycle(InPatient, options);
|
|
|
108
110
|
export const specialClinicsDashboardLink = getSyncLifecycle(createDashboardLink(specialClinicsDashboardMeta), options);
|
|
109
111
|
export const specialClinicsDashboard = getSyncLifecycle(SpecialClinicDashboard, options);
|
|
110
112
|
|
|
113
|
+
export const pharmacyLink = getSyncLifecycle(createLeftPanelLink(dispensingDashboardMeta), options);
|
|
114
|
+
export const pharmacy = getSyncLifecycle(Pharmacy, options);
|
|
115
|
+
|
|
111
116
|
export function startupApp() {
|
|
112
117
|
defineConfigSchema(moduleName, configSchema);
|
|
113
118
|
}
|
|
@@ -1,15 +1,20 @@
|
|
|
1
1
|
import React, { useMemo } from 'react';
|
|
2
2
|
import last from 'lodash-es/last';
|
|
3
3
|
import { BrowserRouter, useLocation } from 'react-router-dom';
|
|
4
|
-
import { ConfigurableLink } from '@openmrs/esm-framework';
|
|
4
|
+
import { ConfigurableLink, MaybeIcon } from '@openmrs/esm-framework';
|
|
5
|
+
import { useTranslation } from 'react-i18next';
|
|
6
|
+
|
|
7
|
+
import styles from './leftt-panel-link.scss';
|
|
5
8
|
|
|
6
9
|
export interface LinkConfig {
|
|
7
10
|
name: string;
|
|
8
11
|
title: string;
|
|
12
|
+
icon?: string;
|
|
9
13
|
}
|
|
10
14
|
|
|
11
15
|
export function LinkExtension({ config }: { config: LinkConfig }) {
|
|
12
|
-
const { name, title } = config;
|
|
16
|
+
const { name, title, icon } = config;
|
|
17
|
+
const { t } = useTranslation();
|
|
13
18
|
const location = useLocation();
|
|
14
19
|
const spaBasePath = window.getOpenmrsSpaBase() + 'home';
|
|
15
20
|
|
|
@@ -26,9 +31,12 @@ export function LinkExtension({ config }: { config: LinkConfig }) {
|
|
|
26
31
|
|
|
27
32
|
return (
|
|
28
33
|
<ConfigurableLink
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
{
|
|
34
|
+
className={`cds--side-nav__link ${name === urlSegment && 'active-left-nav-link'}`}
|
|
35
|
+
to={spaBasePath + '/' + name}>
|
|
36
|
+
<span className={styles.menu}>
|
|
37
|
+
<MaybeIcon icon={icon} className={styles.icon} size={16} />
|
|
38
|
+
<span>{t(title)}</span>
|
|
39
|
+
</span>
|
|
32
40
|
</ConfigurableLink>
|
|
33
41
|
);
|
|
34
42
|
}
|
package/src/routes.json
CHANGED
|
@@ -209,6 +209,25 @@
|
|
|
209
209
|
"order": 0,
|
|
210
210
|
"online": true,
|
|
211
211
|
"offline": false
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"name": "dispensing-homepage-dashboard-link",
|
|
215
|
+
"component": "pharmacyLink",
|
|
216
|
+
"slot": "homepage-dashboard-slot",
|
|
217
|
+
"meta": {
|
|
218
|
+
"name": "dispensing",
|
|
219
|
+
"title": "Dispensing",
|
|
220
|
+
"path": "dispensing",
|
|
221
|
+
"slot": "dispensing-homepage-dashboard-slot"
|
|
222
|
+
}
|
|
223
|
+
},
|
|
224
|
+
{
|
|
225
|
+
"name": "home-page-dispensing-dashboard",
|
|
226
|
+
"component": "pharmacy",
|
|
227
|
+
"slot": "dispensing-homepage-dashboard-slot",
|
|
228
|
+
"order": 0,
|
|
229
|
+
"online": true,
|
|
230
|
+
"offline": false
|
|
212
231
|
}
|
|
213
232
|
],
|
|
214
233
|
"modals": [
|