@openmrs/esm-patient-medications-app 11.3.1-pre.9452 → 11.3.1-pre.9458

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.
Files changed (54) hide show
  1. package/.turbo/turbo-build.log +13 -13
  2. package/dist/1022.js +1 -1
  3. package/dist/1022.js.map +1 -1
  4. package/dist/1918.js +1 -0
  5. package/dist/1918.js.map +1 -0
  6. package/dist/2102.js +1 -0
  7. package/dist/2102.js.map +1 -0
  8. package/dist/4138.js +1 -0
  9. package/dist/4138.js.map +1 -0
  10. package/dist/4300.js +1 -1
  11. package/dist/4341.js +1 -0
  12. package/dist/4341.js.map +1 -0
  13. package/dist/4953.js +1 -1
  14. package/dist/4953.js.map +1 -1
  15. package/dist/8437.js +1 -1
  16. package/dist/8437.js.map +1 -1
  17. package/dist/8812.js +1 -1
  18. package/dist/8812.js.map +1 -1
  19. package/dist/main.js +1 -1
  20. package/dist/main.js.map +1 -1
  21. package/dist/openmrs-esm-patient-medications-app.js +1 -1
  22. package/dist/openmrs-esm-patient-medications-app.js.buildmanifest.json +117 -68
  23. package/dist/routes.json +1 -1
  24. package/package.json +2 -2
  25. package/src/active-medications/active-medications.component.tsx +8 -2
  26. package/src/active-medications/active-medications.test.tsx +6 -9
  27. package/src/add-drug-order/add-drug-order.component.tsx +165 -0
  28. package/src/add-drug-order/add-drug-order.test.tsx +23 -15
  29. package/src/add-drug-order/add-drug-order.workspace.tsx +25 -118
  30. package/src/add-drug-order/drug-order-form.component.tsx +389 -387
  31. package/src/add-drug-order/drug-order-form.resource.ts +1 -2
  32. package/src/add-drug-order/drug-search/drug-search-combobox.component.tsx +7 -6
  33. package/src/add-drug-order/drug-search/drug-search-combobox.test.tsx +1 -1
  34. package/src/add-drug-order/drug-search/drug-search.component.tsx +9 -11
  35. package/src/add-drug-order/drug-search/drug-search.resource.tsx +10 -3
  36. package/src/add-drug-order/drug-search/helpers.ts +1 -1
  37. package/src/add-drug-order/drug-search/order-basket-search-results.component.tsx +32 -17
  38. package/src/add-drug-order/exported-add-drug-order.workspace.tsx +28 -0
  39. package/src/add-drug-order/fill-prescription-form.workspace.tsx +4 -5
  40. package/src/api/api.ts +13 -4
  41. package/src/api/order-config.ts +3 -3
  42. package/src/components/medications-details-table.component.tsx +55 -16
  43. package/src/drug-order-basket-panel/drug-order-basket-panel.extension.tsx +16 -42
  44. package/src/drug-order-basket-panel/drug-order-basket-panel.test.tsx +6 -6
  45. package/src/drug-order-basket-panel/order-basket-item-tile.component.tsx +1 -1
  46. package/src/index.ts +5 -1
  47. package/src/medications-summary/medications-summary.component.tsx +2 -2
  48. package/src/routes.json +7 -7
  49. package/translations/en.json +2 -0
  50. package/dist/7151.js +0 -1
  51. package/dist/7151.js.map +0 -1
  52. package/dist/8803.js +0 -1
  53. package/dist/8803.js.map +0 -1
  54. package/src/types.ts +0 -75
package/src/types.ts DELETED
@@ -1,75 +0,0 @@
1
- import type { Drug, OrderBasketItem } from '@openmrs/esm-patient-common-lib';
2
-
3
- export interface DrugOrderBasketItem extends OrderBasketItem {
4
- drug: Drug;
5
- unit: DosingUnit;
6
- commonMedicationName: string;
7
- dosage: number;
8
- frequency: MedicationFrequency;
9
- route: MedicationRoute;
10
- quantityUnits: QuantityUnit;
11
- patientInstructions: string;
12
- asNeeded: boolean;
13
- asNeededCondition: string;
14
- startDate: Date | string;
15
- durationUnit: DurationUnit;
16
- duration: number | null;
17
- pillsDispensed: number | null;
18
- numRefills: number | null;
19
- indication: string;
20
- isFreeTextDosage: boolean;
21
- freeTextDosage: string;
22
- previousOrder?: string;
23
- template?: OrderTemplate;
24
- }
25
-
26
- export interface DrugOrderTemplate {
27
- uuid: string;
28
- name: string;
29
- drug: Drug;
30
- template: OrderTemplate;
31
- }
32
-
33
- export interface OrderTemplate {
34
- type: string;
35
- dosingType: string;
36
- dosingInstructions: DosingInstructions;
37
- }
38
-
39
- export interface DosingInstructions {
40
- dose: Array<MedicationDosage>;
41
- units: Array<DosingUnit>;
42
- route: Array<MedicationRoute>;
43
- frequency: Array<MedicationFrequency>;
44
- instructions?: Array<MedicationInstructions>;
45
- durationUnits?: Array<DurationUnit>;
46
- quantityUnits?: Array<QuantityUnit>;
47
- asNeeded?: boolean;
48
- asNeededCondition?: string;
49
- }
50
-
51
- export interface MedicationDosage extends Omit<CommonMedicationProps, 'value'> {
52
- value: number;
53
- }
54
-
55
- export type MedicationFrequency = CommonMedicationValueCoded;
56
-
57
- export type MedicationRoute = CommonMedicationValueCoded;
58
-
59
- export type MedicationInstructions = CommonMedicationProps;
60
-
61
- export type DosingUnit = CommonMedicationValueCoded;
62
-
63
- export type QuantityUnit = CommonMedicationValueCoded;
64
-
65
- export type DurationUnit = CommonMedicationValueCoded;
66
-
67
- interface CommonMedicationProps {
68
- value: string;
69
- default?: boolean;
70
- }
71
-
72
- export interface CommonMedicationValueCoded extends CommonMedicationProps {
73
- valueCoded: string;
74
- names?: string[];
75
- }