@openmrs/esm-laboratory-app 1.5.2-pre.1672 → 1.5.2-pre.1677
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/cache/315bf6a4a42cbedd-meta.json +1 -0
- package/.turbo/cache/{a026b448d2bb2bd8.tar.zst → 315bf6a4a42cbedd.tar.zst} +0 -0
- package/.turbo/turbo-build.log +1 -1
- package/dist/openmrs-esm-laboratory-app.js.buildmanifest.json +6 -6
- package/dist/routes.json +1 -1
- package/e2e/commands/patient-operations.ts +0 -2
- package/e2e/specs/reject-lab-request.spec.ts +12 -12
- package/e2e/specs/test-orders.spec.ts +12 -12
- package/eslint.config.mjs +35 -0
- package/package.json +4 -7
- package/src/components/orders-table/orders-data-table.test.tsx +2 -0
- package/src/lab-tabs/laboratory-tabs.component.tsx +1 -1
- package/src/lab-tabs/modals/pickup-lab-request-modal.test.tsx +1 -1
- package/src/lab-tabs/modals/reject-lab-request-modal.test.tsx +1 -1
- package/src/lab-tiles/laboratory-summary-tiles.component.tsx +1 -1
- package/tools/update-openmrs-deps.mjs +1 -1
- package/.eslintignore +0 -1
- package/.eslintrc +0 -68
- package/.turbo/cache/a026b448d2bb2bd8-meta.json +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"hash":"315bf6a4a42cbedd","duration":10165}
|
|
Binary file
|
package/.turbo/turbo-build.log
CHANGED
|
@@ -29,10 +29,10 @@
|
|
|
29
29
|
"rendered": true,
|
|
30
30
|
"initial": false,
|
|
31
31
|
"entry": false,
|
|
32
|
-
"size":
|
|
32
|
+
"size": 58020,
|
|
33
33
|
"sizes": {
|
|
34
34
|
"consume-shared": 84,
|
|
35
|
-
"javascript":
|
|
35
|
+
"javascript": 57936
|
|
36
36
|
},
|
|
37
37
|
"names": [],
|
|
38
38
|
"idHints": [],
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"auxiliaryFiles": [
|
|
46
46
|
"1570.js.map"
|
|
47
47
|
],
|
|
48
|
-
"hash": "
|
|
48
|
+
"hash": "4f08338351423afe",
|
|
49
49
|
"childrenByOrder": {}
|
|
50
50
|
},
|
|
51
51
|
{
|
|
@@ -125,10 +125,10 @@
|
|
|
125
125
|
"rendered": true,
|
|
126
126
|
"initial": true,
|
|
127
127
|
"entry": true,
|
|
128
|
-
"size":
|
|
128
|
+
"size": 3190479,
|
|
129
129
|
"sizes": {
|
|
130
130
|
"consume-shared": 252,
|
|
131
|
-
"javascript":
|
|
131
|
+
"javascript": 3190017,
|
|
132
132
|
"runtime": 13247,
|
|
133
133
|
"share-init": 210
|
|
134
134
|
},
|
|
@@ -145,7 +145,7 @@
|
|
|
145
145
|
"auxiliaryFiles": [
|
|
146
146
|
"main.js.map"
|
|
147
147
|
],
|
|
148
|
-
"hash": "
|
|
148
|
+
"hash": "bc37e1c937e185de",
|
|
149
149
|
"childrenByOrder": {}
|
|
150
150
|
},
|
|
151
151
|
{
|
package/dist/routes.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"webservices.rest":">=2.2.0"},"pages":[{"component":"root","route":"laboratory"}],"extensions":[{"name":"laboratory-dashboard","slot":"laboratory-dashboard-slot","component":"root"},{"name":"laboratory-dashboard-link","slot":"homepage-dashboard-slot","component":"laboratoryDashboardLink","meta":{"name":"laboratory","slot":"laboratory-dashboard-slot","title":"Laboratory"}},{"name":"pickup-lab-request-modal","component":"pickupLabRequestModal"},{"name":"approval-lab-results-modal","component":"approvalLabResultsModal"},{"name":"reject-lab-request-modal","component":"rejectLabRequestModal"},{"name":"all-lab-requests-table","slot":"lab-panels-slot","order":0,"component":"allLabRequestsTable","meta":{"name":"testsOrderedPanel","title":"Tests ordered"}},{"name":"inprogress-lab-requests-table","slot":"lab-panels-slot","component":"inprogressLabRequestsTable","order":1,"meta":{"name":"inprogressPanel","title":"In progress"}},{"name":"completed-lab-requests-table","slot":"lab-panels-slot","component":"completedLabRequestsTable","order":3,"meta":{"name":"completedPanel","title":"Completed"}},{"name":"tests-ordered-tile-component","slot":"lab-tiles-slot","component":"testOrderedTile","meta":{"name":"testsOrderedTileSlot","title":"Ordered tests"}},{"name":"pending-review-lab-requests-table","slot":"lab-panels-slot","component":"pendingReviewLabRequestsTable","order":2,"meta":{"name":"pendingReviewPanel","title":"Pending review tests"}},{"name":"worklist-tile-component","slot":"lab-tiles-slot","component":"worklistTile","meta":{"name":"worklistTileSlot","title":"Worklist"}},{"name":"pending-review-list-tile-component","slot":"lab-tiles-slot","component":"pendingReviewListTile","meta":{"name":"pendingReviewTileSlot","title":"Pending review tests"}},{"name":"completed-tile-component","slot":"lab-tiles-slot","component":"completedTile","meta":{"name":"completedTileSlot","title":"Completed"}},{"name":"declined-tile-component","slot":"lab-panels-slot","component":"declinedLabRequestsTable","order":4,"meta":{"name":"declinedPanel","title":"Declined tests"}},{"name":"pick-lab-request-action","component":"pickupLabRequestAction","slot":"tests-ordered-actions-slot"},{"name":"approve-lab-results-tests-ordered-action","component":"approveLabResultsAction","slot":"approved-ordered-actions-slot"},{"name":"amend-lab-results-tests-ordered-action","component":"amendLabResultsAction","slot":"amended-ordered-actions-slot"},{"name":"reject-lab-request-tests-ordered-action","component":"rejectLabRequestAction","slot":"rejected-ordered-actions-slot"},{"name":"reject-lab-request-worklist-action","component":"rejectLabRequestAction","slot":"inprogress-tests-actions-slot"},{"name":"add-lab-request-results-action","component":"addLabRequestResultsAction","slot":"inprogress-tests-actions-slot"}],"workspaces2":[{"name":"lab-app-test-results-form-workspace","component":"@openmrs/esm-patient-orders-app#exportedTestResultsFormWorkspace","window":"labs-app-test-results-window"},{"name":"lab-app-test-results-add-lab-order-workspace","component":"@openmrs/esm-patient-tests-app#exportedAddLabOrderWorkspace","window":"labs-app-test-results-window"},{"name":"add-test-order-patient-search-workspace","component":"@openmrs/esm-patient-search-app#patientSearchWorkspace2","window":"add-test-order-window"},{"name":"add-test-order-start-visit-workspace","component":"@openmrs/esm-patient-chart-app#exportedVisitForm","window":"add-test-order-window"},{"name":"add-test-order-basket-workspace","component":"@openmrs/esm-patient-orders-app#exportedOrderBasketWorkspace","window":"add-test-order-window"},{"name":"add-test-order-basket-add-lab-order-workspace","component":"@openmrs/esm-patient-tests-app#exportedAddLabOrderWorkspace","window":"add-test-order-window"}],"workspaceWindows2":[{"name":"labs-app-test-results-window","group":"labs-app-group"},{"name":"add-test-order-window","group":"add-test-order-group"}],"workspaceGroups2":[{"name":"labs-app-group","scopePattern":"/home/laboratory"},{"name":"add-test-order-group","scopePattern":"/home/laboratory"}],"version":"1.5.2-pre.
|
|
1
|
+
{"$schema":"https://json.openmrs.org/routes.schema.json","backendDependencies":{"webservices.rest":">=2.2.0"},"pages":[{"component":"root","route":"laboratory"}],"extensions":[{"name":"laboratory-dashboard","slot":"laboratory-dashboard-slot","component":"root"},{"name":"laboratory-dashboard-link","slot":"homepage-dashboard-slot","component":"laboratoryDashboardLink","meta":{"name":"laboratory","slot":"laboratory-dashboard-slot","title":"Laboratory"}},{"name":"pickup-lab-request-modal","component":"pickupLabRequestModal"},{"name":"approval-lab-results-modal","component":"approvalLabResultsModal"},{"name":"reject-lab-request-modal","component":"rejectLabRequestModal"},{"name":"all-lab-requests-table","slot":"lab-panels-slot","order":0,"component":"allLabRequestsTable","meta":{"name":"testsOrderedPanel","title":"Tests ordered"}},{"name":"inprogress-lab-requests-table","slot":"lab-panels-slot","component":"inprogressLabRequestsTable","order":1,"meta":{"name":"inprogressPanel","title":"In progress"}},{"name":"completed-lab-requests-table","slot":"lab-panels-slot","component":"completedLabRequestsTable","order":3,"meta":{"name":"completedPanel","title":"Completed"}},{"name":"tests-ordered-tile-component","slot":"lab-tiles-slot","component":"testOrderedTile","meta":{"name":"testsOrderedTileSlot","title":"Ordered tests"}},{"name":"pending-review-lab-requests-table","slot":"lab-panels-slot","component":"pendingReviewLabRequestsTable","order":2,"meta":{"name":"pendingReviewPanel","title":"Pending review tests"}},{"name":"worklist-tile-component","slot":"lab-tiles-slot","component":"worklistTile","meta":{"name":"worklistTileSlot","title":"Worklist"}},{"name":"pending-review-list-tile-component","slot":"lab-tiles-slot","component":"pendingReviewListTile","meta":{"name":"pendingReviewTileSlot","title":"Pending review tests"}},{"name":"completed-tile-component","slot":"lab-tiles-slot","component":"completedTile","meta":{"name":"completedTileSlot","title":"Completed"}},{"name":"declined-tile-component","slot":"lab-panels-slot","component":"declinedLabRequestsTable","order":4,"meta":{"name":"declinedPanel","title":"Declined tests"}},{"name":"pick-lab-request-action","component":"pickupLabRequestAction","slot":"tests-ordered-actions-slot"},{"name":"approve-lab-results-tests-ordered-action","component":"approveLabResultsAction","slot":"approved-ordered-actions-slot"},{"name":"amend-lab-results-tests-ordered-action","component":"amendLabResultsAction","slot":"amended-ordered-actions-slot"},{"name":"reject-lab-request-tests-ordered-action","component":"rejectLabRequestAction","slot":"rejected-ordered-actions-slot"},{"name":"reject-lab-request-worklist-action","component":"rejectLabRequestAction","slot":"inprogress-tests-actions-slot"},{"name":"add-lab-request-results-action","component":"addLabRequestResultsAction","slot":"inprogress-tests-actions-slot"}],"workspaces2":[{"name":"lab-app-test-results-form-workspace","component":"@openmrs/esm-patient-orders-app#exportedTestResultsFormWorkspace","window":"labs-app-test-results-window"},{"name":"lab-app-test-results-add-lab-order-workspace","component":"@openmrs/esm-patient-tests-app#exportedAddLabOrderWorkspace","window":"labs-app-test-results-window"},{"name":"add-test-order-patient-search-workspace","component":"@openmrs/esm-patient-search-app#patientSearchWorkspace2","window":"add-test-order-window"},{"name":"add-test-order-start-visit-workspace","component":"@openmrs/esm-patient-chart-app#exportedVisitForm","window":"add-test-order-window"},{"name":"add-test-order-basket-workspace","component":"@openmrs/esm-patient-orders-app#exportedOrderBasketWorkspace","window":"add-test-order-window"},{"name":"add-test-order-basket-add-lab-order-workspace","component":"@openmrs/esm-patient-tests-app#exportedAddLabOrderWorkspace","window":"add-test-order-window"}],"workspaceWindows2":[{"name":"labs-app-test-results-window","group":"labs-app-group"},{"name":"add-test-order-window","group":"add-test-order-group"}],"workspaceGroups2":[{"name":"labs-app-group","scopePattern":"/home/laboratory"},{"name":"add-test-order-group","scopePattern":"/home/laboratory"}],"version":"1.5.2-pre.1677"}
|
|
@@ -51,7 +51,6 @@ export const generateRandomPatient = async (api: APIRequestContext): Promise<Pat
|
|
|
51
51
|
data: {},
|
|
52
52
|
});
|
|
53
53
|
|
|
54
|
-
// eslint-disable-next-line @typescript-eslint/await-thenable
|
|
55
54
|
await expect(identifierRes.ok()).toBeTruthy();
|
|
56
55
|
const { identifier } = await identifierRes.json();
|
|
57
56
|
|
|
@@ -94,7 +93,6 @@ export const generateRandomPatient = async (api: APIRequestContext): Promise<Pat
|
|
|
94
93
|
},
|
|
95
94
|
});
|
|
96
95
|
|
|
97
|
-
// eslint-disable-next-line @typescript-eslint/await-thenable
|
|
98
96
|
await expect(patientRes.ok()).toBeTruthy();
|
|
99
97
|
return await patientRes.json();
|
|
100
98
|
};
|
|
@@ -27,6 +27,18 @@ test.beforeEach(async ({ api, patient }) => {
|
|
|
27
27
|
fullName = patient.person?.display;
|
|
28
28
|
});
|
|
29
29
|
|
|
30
|
+
test.afterEach(async ({ api }) => {
|
|
31
|
+
if (visit) {
|
|
32
|
+
await endVisit(api, visit);
|
|
33
|
+
}
|
|
34
|
+
if (encounter?.uuid) {
|
|
35
|
+
await deleteEncounter(api, encounter.uuid);
|
|
36
|
+
}
|
|
37
|
+
if (testOrder?.uuid) {
|
|
38
|
+
await deleteTestOrder(api, testOrder.uuid);
|
|
39
|
+
}
|
|
40
|
+
});
|
|
41
|
+
|
|
30
42
|
test('Reject a lab request', async ({ page }) => {
|
|
31
43
|
const laboratoryPage = new LaboratoryPage(page);
|
|
32
44
|
|
|
@@ -74,15 +86,3 @@ test('Reject a lab request', async ({ page }) => {
|
|
|
74
86
|
await expect(page.getByRole('cell', { name: 'Declined' })).toBeVisible();
|
|
75
87
|
});
|
|
76
88
|
});
|
|
77
|
-
|
|
78
|
-
test.afterEach(async ({ api }) => {
|
|
79
|
-
if (visit) {
|
|
80
|
-
await endVisit(api, visit);
|
|
81
|
-
}
|
|
82
|
-
if (encounter?.uuid) {
|
|
83
|
-
await deleteEncounter(api, encounter.uuid);
|
|
84
|
-
}
|
|
85
|
-
if (testOrder?.uuid) {
|
|
86
|
-
await deleteTestOrder(api, testOrder.uuid);
|
|
87
|
-
}
|
|
88
|
-
});
|
|
@@ -29,6 +29,18 @@ test.beforeEach(async ({ api, patient }) => {
|
|
|
29
29
|
fullName = patient.person?.display;
|
|
30
30
|
});
|
|
31
31
|
|
|
32
|
+
test.afterEach(async ({ api }) => {
|
|
33
|
+
if (visit) {
|
|
34
|
+
await endVisit(api, visit);
|
|
35
|
+
}
|
|
36
|
+
if (encounter?.uuid) {
|
|
37
|
+
await deleteEncounter(api, encounter.uuid);
|
|
38
|
+
}
|
|
39
|
+
if (testOrder?.uuid) {
|
|
40
|
+
await deleteTestOrder(api, testOrder.uuid);
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
|
|
32
44
|
test('View test orders', async ({ page }) => {
|
|
33
45
|
const laboratoryPage = new LaboratoryPage(page);
|
|
34
46
|
|
|
@@ -55,15 +67,3 @@ test('View test orders', async ({ page }) => {
|
|
|
55
67
|
await expect(laboratoryPage.getPatientRow(fullName).getByText(/1 Routine/i)).toBeVisible();
|
|
56
68
|
});
|
|
57
69
|
});
|
|
58
|
-
|
|
59
|
-
test.afterEach(async ({ api }) => {
|
|
60
|
-
if (visit) {
|
|
61
|
-
await endVisit(api, visit);
|
|
62
|
-
}
|
|
63
|
-
if (encounter?.uuid) {
|
|
64
|
-
await deleteEncounter(api, encounter.uuid);
|
|
65
|
-
}
|
|
66
|
-
if (testOrder?.uuid) {
|
|
67
|
-
await deleteTestOrder(api, testOrder.uuid);
|
|
68
|
-
}
|
|
69
|
-
});
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import openmrs from '@openmrs/eslint-config';
|
|
2
|
+
|
|
3
|
+
export default [
|
|
4
|
+
{ ignores: ['dist/**', 'coverage/**'] },
|
|
5
|
+
...openmrs,
|
|
6
|
+
{
|
|
7
|
+
rules: {
|
|
8
|
+
// Rules this repo enforces where the shared config turns them off.
|
|
9
|
+
'@typescript-eslint/no-empty-object-type': 'error',
|
|
10
|
+
'@typescript-eslint/no-unsafe-function-type': 'error',
|
|
11
|
+
'@typescript-eslint/no-wrapper-object-types': 'error',
|
|
12
|
+
'@typescript-eslint/triple-slash-reference': 'error',
|
|
13
|
+
'no-extra-boolean-cast': 'error',
|
|
14
|
+
'no-prototype-builtins': 'error',
|
|
15
|
+
'no-unsafe-optional-chaining': 'error',
|
|
16
|
+
'no-useless-escape': 'error',
|
|
17
|
+
'prefer-const': 'error',
|
|
18
|
+
'react-hooks/exhaustive-deps': 'warn',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
// consistent-type-exports needs type information, which the old config
|
|
23
|
+
// supplied through parserOptions.project.
|
|
24
|
+
files: ['**/*.{ts,tsx}'],
|
|
25
|
+
languageOptions: {
|
|
26
|
+
parserOptions: {
|
|
27
|
+
project: true,
|
|
28
|
+
tsconfigRootDir: import.meta.dirname,
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
rules: {
|
|
32
|
+
'@typescript-eslint/consistent-type-exports': 'error',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openmrs/esm-laboratory-app",
|
|
3
|
-
"version": "1.5.2-pre.
|
|
3
|
+
"version": "1.5.2-pre.1677",
|
|
4
4
|
"license": "MPL-2.0",
|
|
5
5
|
"description": "An O3 frontend module for managing laboratory requests and queues",
|
|
6
6
|
"browser": "dist/openmrs-esm-laboratory-app.js",
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"serve": "rspack serve --mode=development",
|
|
12
12
|
"build": "rspack --mode production",
|
|
13
13
|
"analyze": "rspack --mode=production --env analyze=true",
|
|
14
|
-
"lint": "eslint src
|
|
14
|
+
"lint": "eslint src",
|
|
15
15
|
"prettier": "prettier --write \"src/**/*.{css,scss,ts,tsx}\" --list-different",
|
|
16
16
|
"typescript": "tsc",
|
|
17
17
|
"test": "cross-env TZ=UTC vitest run --passWithNoTests",
|
|
@@ -58,6 +58,7 @@
|
|
|
58
58
|
"react-router-dom": "6.x"
|
|
59
59
|
},
|
|
60
60
|
"devDependencies": {
|
|
61
|
+
"@openmrs/eslint-config": "^2.0.0",
|
|
61
62
|
"@openmrs/esm-framework": "next",
|
|
62
63
|
"@playwright/test": "^1.52.0",
|
|
63
64
|
"@swc/cli": "^0.1.62",
|
|
@@ -69,14 +70,10 @@
|
|
|
69
70
|
"@types/dotenv": "^8.2.3",
|
|
70
71
|
"@types/react": "^18.3.21",
|
|
71
72
|
"@types/react-dom": "^18.3.0",
|
|
72
|
-
"@typescript-eslint/eslint-plugin": "^8.45.0",
|
|
73
|
-
"@typescript-eslint/parser": "^8.45.0",
|
|
74
73
|
"@vitest/coverage-v8": "^4.1.2",
|
|
75
74
|
"cross-env": "^10.1.0",
|
|
76
75
|
"dayjs": "^1.11.11",
|
|
77
|
-
"eslint": "^
|
|
78
|
-
"eslint-plugin-import": "^2.31.0",
|
|
79
|
-
"eslint-plugin-react-hooks": "^5.0.0",
|
|
76
|
+
"eslint": "^9.39.0",
|
|
80
77
|
"file-saver": "^2.0.5",
|
|
81
78
|
"husky": "^8.0.0",
|
|
82
79
|
"i18next-parser": "^9.3.0",
|
|
@@ -204,6 +204,7 @@ describe('OrdersDataTable', () => {
|
|
|
204
204
|
|
|
205
205
|
render(<OrdersDataTable />);
|
|
206
206
|
|
|
207
|
+
// eslint-disable-next-line testing-library/no-node-access -- asserting on Carbon's search wrapper, which has no Testing Library query
|
|
207
208
|
const search = screen.getByPlaceholderText('Search this list').closest('.cds--search');
|
|
208
209
|
expect(search).toHaveClass('cds--search--lg');
|
|
209
210
|
expect(search).not.toHaveClass('cds--search--sm');
|
|
@@ -216,6 +217,7 @@ describe('OrdersDataTable', () => {
|
|
|
216
217
|
|
|
217
218
|
render(<OrdersDataTable />);
|
|
218
219
|
|
|
220
|
+
// eslint-disable-next-line testing-library/no-node-access -- asserting on Carbon's search wrapper, which has no Testing Library query
|
|
219
221
|
expect(screen.getByPlaceholderText('Search this list').closest('.cds--search')).toHaveClass('toolbarSearch');
|
|
220
222
|
});
|
|
221
223
|
|
|
@@ -4,7 +4,7 @@ import { Tab, TabList, TabPanel, TabPanels, Tabs } from '@carbon/react';
|
|
|
4
4
|
import { Extension, useAssignedExtensions, useConfig } from '@openmrs/esm-framework';
|
|
5
5
|
// ComponentContext is not part of the public API but is needed here to render extensions
|
|
6
6
|
// inside Carbon Tabs structure (TabList + TabPanels must be separate siblings).
|
|
7
|
-
|
|
7
|
+
|
|
8
8
|
import { ComponentContext } from '@openmrs/esm-framework/src/internal';
|
|
9
9
|
import { type Config } from '../config-schema';
|
|
10
10
|
import styles from './laboratory-tabs.scss';
|
|
@@ -113,7 +113,7 @@ describe('PickupLabRequestModal', () => {
|
|
|
113
113
|
|
|
114
114
|
const user = userEvent.setup();
|
|
115
115
|
const submitButton = screen.getByRole('button', { name: 'Pick up lab request' });
|
|
116
|
-
expect(submitButton).
|
|
116
|
+
expect(submitButton).toBeEnabled();
|
|
117
117
|
|
|
118
118
|
await user.click(submitButton);
|
|
119
119
|
|
|
@@ -121,7 +121,7 @@ describe('RejectLabRequestModal', () => {
|
|
|
121
121
|
|
|
122
122
|
const user = userEvent.setup();
|
|
123
123
|
const submitButton = screen.getByRole('button', { name: /Reject/ });
|
|
124
|
-
expect(submitButton).
|
|
124
|
+
expect(submitButton).toBeEnabled();
|
|
125
125
|
|
|
126
126
|
await user.click(submitButton);
|
|
127
127
|
|
|
@@ -3,7 +3,7 @@ import { useTranslation } from 'react-i18next';
|
|
|
3
3
|
import { type AssignedExtension, useAssignedExtensions, Extension, useConfig } from '@openmrs/esm-framework';
|
|
4
4
|
// ComponentContext is not part of the public API but is needed here to render extensions
|
|
5
5
|
// in a custom layout (CSS grid tiles) without the wrapper div that ExtensionSlot adds.
|
|
6
|
-
|
|
6
|
+
|
|
7
7
|
import { ComponentContext } from '@openmrs/esm-framework/src/internal';
|
|
8
8
|
import styles from './laboratory-summary-tiles.scss';
|
|
9
9
|
import { type Config } from '../config-schema';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { execSync } from 'node:child_process';
|
|
2
2
|
|
|
3
3
|
try {
|
|
4
|
-
execSync(`yarn up --fixed '@openmrs
|
|
4
|
+
execSync(`yarn up --fixed '@openmrs/esm-framework@next' 'openmrs@next'`, {
|
|
5
5
|
stdio: ['ignore', 'inherit', 'inherit'],
|
|
6
6
|
windowsHide: true,
|
|
7
7
|
});
|
package/.eslintignore
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
**/node_modules/**/*
|
package/.eslintrc
DELETED
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"env": {
|
|
3
|
-
"node": true
|
|
4
|
-
},
|
|
5
|
-
"extends": [
|
|
6
|
-
"eslint:recommended",
|
|
7
|
-
"plugin:@typescript-eslint/recommended"
|
|
8
|
-
],
|
|
9
|
-
"parser": "@typescript-eslint/parser",
|
|
10
|
-
"parserOptions": {
|
|
11
|
-
"project": true
|
|
12
|
-
},
|
|
13
|
-
"plugins": ["@typescript-eslint", "import", "react-hooks"],
|
|
14
|
-
"root": true,
|
|
15
|
-
"rules": {
|
|
16
|
-
// The following rules need `noImplicitAny` to be set to `true` in our tsconfig. They are too restrictive for now, but should be reconsidered in future
|
|
17
|
-
"@typescript-eslint/ban-types": "off",
|
|
18
|
-
"@typescript-eslint/ban-ts-comment": "off",
|
|
19
|
-
"@typescript-eslint/no-explicit-any": "off",
|
|
20
|
-
"@typescript-eslint/no-floating-promises": "off",
|
|
21
|
-
"@typescript-eslint/no-unsafe-argument": "off",
|
|
22
|
-
"@typescript-eslint/no-unsafe-assignment": "off",
|
|
23
|
-
"@typescript-eslint/no-unsafe-call": "off",
|
|
24
|
-
"@typescript-eslint/no-unsafe-member-access": "off",
|
|
25
|
-
"@typescript-eslint/no-unsafe-return": "off",
|
|
26
|
-
"@typescript-eslint/no-unused-vars": "off",
|
|
27
|
-
"@typescript-eslint/unbound-method": "off",
|
|
28
|
-
"@typescript-eslint/consistent-type-definitions": "off",
|
|
29
|
-
"@typescript-eslint/consistent-type-exports": "error",
|
|
30
|
-
// Use `import type` instead of `import` for type imports
|
|
31
|
-
"@typescript-eslint/consistent-type-imports": [
|
|
32
|
-
"error",
|
|
33
|
-
{
|
|
34
|
-
"fixStyle": "inline-type-imports"
|
|
35
|
-
}
|
|
36
|
-
],
|
|
37
|
-
"import/no-duplicates": "error",
|
|
38
|
-
"no-console": ["error", { "allow": ["warn", "error"] }],
|
|
39
|
-
"no-restricted-imports": [
|
|
40
|
-
"error",
|
|
41
|
-
{
|
|
42
|
-
"paths": [
|
|
43
|
-
// These two rules ensure that we're importing lodash and lodash-es correctly. Not doing so can bloat our bundle size significantly.
|
|
44
|
-
{
|
|
45
|
-
"name": "lodash",
|
|
46
|
-
"message": "Import specific methods from `lodash`. e.g. `import map from 'lodash/map'`"
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
"name": "lodash-es",
|
|
50
|
-
"importNames": ["default"],
|
|
51
|
-
"message": "Import specific methods from `lodash-es`. e.g. `import { map } from 'lodash-es'`"
|
|
52
|
-
},
|
|
53
|
-
// These two rules ensure that we're importing Carbon components and icons from the correct packages (after v10). May be removed in the future.
|
|
54
|
-
{
|
|
55
|
-
"name": "carbon-components-react",
|
|
56
|
-
"message": "Import from `@carbon/react` directly. e.g. `import { Toggle } from '@carbon/react'`"
|
|
57
|
-
},
|
|
58
|
-
{
|
|
59
|
-
"name": "@carbon/icons-react",
|
|
60
|
-
"message": "Import from `@carbon/react/icons`. e.g. `import { ChevronUp } from '@carbon/react/icons'`"
|
|
61
|
-
}
|
|
62
|
-
]
|
|
63
|
-
}
|
|
64
|
-
],
|
|
65
|
-
"react-hooks/exhaustive-deps": "warn",
|
|
66
|
-
"react-hooks/rules-of-hooks": "error"
|
|
67
|
-
}
|
|
68
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"hash":"a026b448d2bb2bd8","duration":9222}
|